diff options
author | Nathan Lynch <[email protected]> | 2023-03-06 15:33:40 -0600 |
---|---|---|
committer | Michael Ellerman <[email protected]> | 2023-03-30 23:36:34 +1100 |
commit | f40b0f6c5c27de167fdd10e541e0a4b5f2bc772b (patch) | |
tree | 09aed2ec1ed30fd3813d44c17dcfa2db38e4bf6b /tools/perf/scripts/python/syscall-counts.py | |
parent | 05dce4ba125336875cd3eed3c1503fa81cd2f691 (diff) |
powerpc/rtas: ensure 8-byte alignment for struct rtas_args
CHRP and PAPR agree: "In order to make an RTAS call, the operating
system must construct an argument call buffer aligned on an eight byte
boundary in physically contiguous real memory [...]." (7.2.7 Calling
Mechanism and Conventions).
struct rtas_args is the type used for this argument call buffer. The
unarchitected 'rets' member happens to produce 8-byte alignment for
the struct on 64-bit targets in practice. But without an alignment
directive the structure will have only 4-byte alignment on 32-bit
targets:
$ nm b/{before,after}/chrp32/vmlinux | grep rtas_args
c096881c b rtas_args
c0968820 b rtas_args
Add an alignment directive to the struct rtas_args declaration so all
instances have the alignment required by the specs. rtas-types.h no
longer refers to any spinlock types, so drop the spinlock_types.h
inclusion while we're here.
Signed-off-by: Nathan Lynch <[email protected]>
Reviewed-by: Andrew Donnellan <[email protected]>
Signed-off-by: Michael Ellerman <[email protected]>
Link: https://msgid.link/[email protected]
Diffstat (limited to 'tools/perf/scripts/python/syscall-counts.py')
0 files changed, 0 insertions, 0 deletions