diff options
author | 2024-08-26 23:09:57 +0800 | |
---|---|---|
committer | 2024-09-05 22:25:36 +1000 | |
commit | 6f2683274d0d0b51a986f73c2afb9058156f1641 (patch) | |
tree | 6b548980d9d6dc3d02c5cb7566af1d95f8310a91 /arch/powerpc/kernel/stacktrace.c | |
parent | powerpc: powernv: Constify struct kobj_type (diff) | |
download | wireguard-linux-6f2683274d0d0b51a986f73c2afb9058156f1641.tar.xz wireguard-linux-6f2683274d0d0b51a986f73c2afb9058156f1641.zip |
powerpc: pseries: Constify struct kobj_type
'struct kobj_type' is not modified. It is only used in kobject_init()
which takes a 'const struct kobj_type *ktype' parameter.
Constifying this structure moves some data to a read-only section,
so increase over all security.
On a x86_64, compiled with ppc64 defconfig:
Before:
======
text data bss dec hex filename
1885 368 16 2269 8dd arch/powerpc/platforms/pseries/vas-sysfs.o
After:
======
text data bss dec hex filename
1981 272 16 2269 8dd arch/powerpc/platforms/pseries/vas-sysfs.o
Signed-off-by: Huang Xiaojia <huangxiaojia2@huawei.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://msgid.link/20240826150957.3500237-3-huangxiaojia2@huawei.com
Diffstat (limited to 'arch/powerpc/kernel/stacktrace.c')
0 files changed, 0 insertions, 0 deletions