]> www.infradead.org Git - users/jedix/linux-maple.git/commit
firmware_loader: Constify 'struct bin_attribute'
authorThomas Weißschuh <linux@weissschuh.net>
Sun, 22 Dec 2024 20:20:50 +0000 (21:20 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Jan 2025 09:15:11 +0000 (10:15 +0100)
commitc1ecb860a48d0bf56b0fc8391c5d59b0c3b42516
tree8d79f60f1961de9400e3b0c0436fa9d8f59a57f0
parent2a8d6abdf5cfdc7df934968f2e8292d050f20b20
firmware_loader: Constify 'struct bin_attribute'

The sysfs core now allows instances of 'struct bin_attribute' 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>
Reviewed-by: Russ Weight <russ.weight@linux.dev>
Link: https://lore.kernel.org/r/20241222-sysfs-const-bin_attr-firmware-v1-1-c35e56bfb4eb@weissschuh.net
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/firmware_loader/sysfs.c