diff options
author | Xiongwei Song <sxwjean@gmail.com> | 2021-08-07 04:02:36 +0300 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2021-08-26 14:21:06 +0300 |
commit | 4f8e78c0757e3c5a65d9d8ac76e2434c71a78f5a (patch) | |
tree | 2993bcc95e5bbccf0a2101a7c6acd861f505bfec /arch/powerpc/platforms/4xx | |
parent | e42edf9b9d126bb1c743f2e7984877ba27f09fe7 (diff) | |
download | linux-4f8e78c0757e3c5a65d9d8ac76e2434c71a78f5a.tar.xz |
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
Diffstat (limited to 'arch/powerpc/platforms/4xx')
-rw-r--r-- | arch/powerpc/platforms/4xx/machine_check.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/4xx/machine_check.c b/arch/powerpc/platforms/4xx/machine_check.c index a71c29892a91..a905da1d6f41 100644 --- a/arch/powerpc/platforms/4xx/machine_check.c +++ b/arch/powerpc/platforms/4xx/machine_check.c @@ -10,7 +10,7 @@ int machine_check_4xx(struct pt_regs *regs) { - unsigned long reason = regs->dsisr; + unsigned long reason = regs->esr; if (reason & ESR_IMCP) { printk("Instruction"); |