powerpc: Add esr as a synonym for pt_regs.dsisr
Create an anonymous union for dsisr and esr regsiters, we can reference esr to get the exception detail when CONFIG_4xx=y or CONFIG_BOOKE=y. Otherwise, reference dsisr. This makes code more clear. Signed-off-by: Xiongwei Song <sxwjean@gmail.com> [mpe: Reword commit title] Signed-off-by: Michael Ellerman <mpe@ellerman.id.au> Link: https://lore.kernel.org/r/20210807010239.416055-2-sxwjean@me.com
This commit is contained in:
committed by
Michael Ellerman
parent
e42edf9b9d
commit
4f8e78c075
@@ -375,6 +375,8 @@ void __init pt_regs_check(void)
|
||||
offsetof(struct user_pt_regs, dar));
|
||||
BUILD_BUG_ON(offsetof(struct pt_regs, dsisr) !=
|
||||
offsetof(struct user_pt_regs, dsisr));
|
||||
BUILD_BUG_ON(offsetof(struct pt_regs, esr) !=
|
||||
offsetof(struct user_pt_regs, dsisr));
|
||||
BUILD_BUG_ON(offsetof(struct pt_regs, result) !=
|
||||
offsetof(struct user_pt_regs, result));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user