mirror of
https://github.com/torvalds/linux.git
synced 2026-03-08 03:04:51 +01:00
block, bfq: constify sysfs attributes
The elevator core now allows instances of 'struct elv_fs_entry' to be moved into read-only memory. Make use of that to protect them against accidental or malicious modifications. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> Link: https://lore.kernel.org/r/20250102-sysfs-const-attr-elevator-v1-3-9837d2058c60@weissschuh.net Signed-off-by: Jens Axboe <axboe@kernel.dk>
This commit is contained in:
parent
8686e1deda
commit
c40f9f6ac5
1 changed files with 1 additions and 1 deletions
|
|
@ -7614,7 +7614,7 @@ static ssize_t bfq_low_latency_store(struct elevator_queue *e,
|
|||
#define BFQ_ATTR(name) \
|
||||
__ATTR(name, 0644, bfq_##name##_show, bfq_##name##_store)
|
||||
|
||||
static struct elv_fs_entry bfq_attrs[] = {
|
||||
static const struct elv_fs_entry bfq_attrs[] = {
|
||||
BFQ_ATTR(fifo_expire_sync),
|
||||
BFQ_ATTR(fifo_expire_async),
|
||||
BFQ_ATTR(back_seek_max),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue