Skip to contentSkip to conversation

arm64: mm: decode xFSC in mem_abort_decode()

PATCH Applied Mark Rutland 2 participants 3 messages Jun 8, 2021 arm64

lore
Share & tools
lore

Mark Rutland

author reviewer
#0 lore raw

PATCH 1/1 arm64: mm: decode xFSC in mem_abort_decode()

It would be helpful if mem_abort_decode() could decode the DFSC/IFSC, as this can make it easier to identify common bugs (e.g. accesses which trigger alignment faults) without having to manually decode the xFSC value.

Decode the xFSC in mem_abort_decode().

Cc Catalin Marinas <[email protected]>
Cc Robin Murphy <[email protected]>
Cc Will Deacon <[email protected]>
---
 arch/arm64/mm/fault.c | 2 ++
 1 file changed, 2 insertions(+)
arch/arm64/mm/fault.c +2 -0
index c10bf749c233..2fba5da62104 100644
@@ -99,6 +99,8 @@ static void mem_abort_decode(unsigned int esr)
 	pr_alert("  EA = %lu, S1PTW = %lu\n",
 		 (esr & ESR_ELx_EA) >> ESR_ELx_EA_SHIFT,
 		 (esr & ESR_ELx_S1PTW) >> ESR_ELx_S1PTW_SHIFT);
+	pr_alert("  FSC = 0x%02x: %s\n", (esr & ESR_ELx_FSC),
+		 esr_to_fault_info(esr)->name);
 
 	if (esr_is_data_abort(esr))
 		data_abort_decode(esr);
Signature · 7 lines
2.11.0


_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
maintainer Applied
#1 lore raw
Quoted 6 lines · Mark Rutland

It would be helpful if mem_abort_decode() could decode the DFSC/IFSC, as this can make it easier to identify common bugs (e.g. accesses which trigger alignment faults) without having to manually decode the xFSC value.

Decode the xFSC in mem_abort_decode().

Applied to arm64 (for-next/mm), thanks!

[1/1] arm64: mm: decode xFSC in mem_abort_decode()

      https://git.kernel.org/arm64/c/392eec313f29

Cheers,

Signature · 10 lines
Will

https://fixes.arm64.dev
https://next.arm64.dev
https://will.arm64.dev

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
author reviewer
#2 lore raw
Quoted 6 lines · Will Deacon
Quoted 5 lines · Mark Rutland

It would be helpful if mem_abort_decode() could decode the DFSC/IFSC, as this can make it easier to identify common bugs (e.g. accesses which trigger alignment faults) without having to manually decode the xFSC value.

Quoted 6 lines
Quoted 1 line

Decode the xFSC in mem_abort_decode().

Applied to arm64 (for-next/mm), thanks!

[1/1] arm64: mm: decode xFSC in mem_abort_decode()

      https://git.kernel.org/arm64/c/392eec313f29

Thanks!

Somehow I typo'd Robin's email address in the Cc list. If it's possible to fix that up in the patch, that'd be great. If that's a pain, no worries.

I'll go find a keyboard I can actually handle...

Mark.

_______________________________________________
linux-arm-kernel mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel