diff options
author | Helge Deller <deller@gmx.de> | 2023-11-22 23:18:12 +0100 |
---|---|---|
committer | Luis Chamberlain <mcgrof@kernel.org> | 2024-10-19 13:35:24 -0700 |
commit | 335de24e5e774aa94ff9551b3194fe15f52ea1d9 (patch) | |
tree | a40658c6712b0b9c4557ed5f50793d4ab7e2e7f1 /tools/perf/scripts/python/export-to-postgresql.py | |
parent | 8e929cb546ee42c9a61d24fae60605e9e3192354 (diff) |
modules: Ensure 64-bit alignment on __ksymtab_* sections
On 64-bit architectures without CONFIG_HAVE_ARCH_PREL32_RELOCATIONS
(e.g. ppc64, ppc64le, parisc, s390x,...) the __KSYM_REF() macro stores
64-bit pointers into the __ksymtab* sections.
Make sure that those sections will be correctly aligned at module link time,
otherwise unaligned memory accesses may happen at runtime.
As per unaligned-memory-access [0] "unaligned memory accesses [...]
will not work correctly on certain platforms and will cause performance
problems on others", so fix this.
The __kcrctab* sections store 32-bit entities, so use ALIGN(4) for those.
Signed-off-by: Helge Deller <deller@gmx.de>
[mcgrof: added unaligned-memory-access justification]
Link: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/core-api/unaligned-memory-access.rst # [0]
Signed-off-by: Luis Chamberlain <mcgrof@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions