Message ID | 20241202-sysfs-const-bin_attr-pdx86-v1-0-9ab204c2a814@weissschuh.net (mailing list archive) |
---|---|
Headers | show |
Series | platform/x86: Constify 'struct bin_attribute' | expand |
On Mon, 02 Dec 2024 20:38:31 +0100, Thomas Weißschuh wrote: > 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. > > The usage of read_new/write_new/bin_attrs_new is a transition mechanism > and will be removed after the tree-wide transition to > const struct bin_attribute. > > [...] Thank you for your contribution, it has been applied to my local review-ilpo-next branch. Note it will show up in the public platform-drivers-x86/review-ilpo-next branch only once I've pushed my local branch there, which might take a while. The list of commits applied: [1/5] platform/x86: dell: dcdbas: Constify 'struct bin_attribute' commit: f05a99b0d5f16bb82d91f602ade9a2f199c5abde [2/5] platform/x86: dell_rbu: Constify 'struct bin_attribute' commit: e7bcc60c87369c22dfd5e3f13c0aac58a7a3e1d9 [3/5] platform/x86/intel/sdsi: Constify 'struct bin_attribute' commit: b5a3e35615948ab5faf773d4e5a0206020403538 [4/5] platform/x86/intel/pmt: Constify 'struct bin_attribute' commit: 75e76075f2df25ed4e726b722aeb3ed1afd4b12a [5/5] platform/x86/amd/hsmp: Constify 'struct bin_attribute' commit: 2c62a6ed6fe5e084d3ef47d07087088c2e718290 -- i.
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. The usage of read_new/write_new/bin_attrs_new is a transition mechanism and will be removed after the tree-wide transition to const struct bin_attribute. Signed-off-by: Thomas Weißschuh <linux@weissschuh.net> --- Thomas Weißschuh (5): platform/x86: dell: dcdbas: Constify 'struct bin_attribute' platform/x86: dell_rbu: Constify 'struct bin_attribute' platform/x86/intel/sdsi: Constify 'struct bin_attribute' platform/x86/intel/pmt: Constify 'struct bin_attribute' platform/x86/amd/hsmp: Constify 'struct bin_attribute' drivers/platform/x86/amd/hsmp/acpi.c | 12 ++++++------ drivers/platform/x86/amd/hsmp/plat.c | 12 ++++++------ drivers/platform/x86/dell/dcdbas.c | 10 +++++----- drivers/platform/x86/dell/dcdbas.h | 8 -------- drivers/platform/x86/dell/dell_rbu.c | 20 ++++++++++---------- drivers/platform/x86/intel/pmt/class.c | 4 ++-- drivers/platform/x86/intel/sdsi.c | 34 +++++++++++++++++----------------- 7 files changed, 46 insertions(+), 54 deletions(-) --- base-commit: e70140ba0d2b1a30467d4af6bcfe761327b9ec95 change-id: 20241202-sysfs-const-bin_attr-pdx86-c16ca5d376ca Best regards,