diff options
| author | Christophe JAILLET <christophe.jaillet@wanadoo.fr> | 2026-08-09 23:32:25 +0200 |
|---|---|---|
| committer | Borislav Petkov (AMD) <bp@alien8.de> | 2026-09-27 15:50:03 -0700 |
| commit | c7243accb48a7987b2e80751f712c3f4fe2b3714 (patch) | |
| tree | caf178f85443f97f2badb03eb0d22bc9a933b7cf /tools/perf/scripts/python/exported-sql-viewer.py | |
| parent | 975809caf4b0e07330110b56ca2d8a3fa7e16ff5 (diff) | |
x86/cpu: Constify struct x86_cpu_id
'struct x86_cpu_id' is not modified in this compilation unit.
Constifying this structure moves some data to a read-only section, so
increases overall security.
It is only used in cpu_has_old_microcode() which is an __init function. So,
using __initconst is safe and will save about 6 kB of memory at runtime.
On a x86_64, with allmodconfig:
text data bss dec hex filename
55725 28774 512 85011 14c13 arch/x86/kernel/cpu/common.o.before
61464 22918 512 84894 14b9e arch/x86/kernel/cpu/common.o.after
[ bp: Massage commit message. ]
Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Link: https://patch.msgid.link/f08d3a0e7aefe3bad66251927cbd03b8cbf9df73.1786311119.git.christophe.jaillet@wanadoo.fr
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions
