scripts/gdb: De-reference per-CPU MCE interrupts
PATCH 1/1 scripts/gdb: De-reference per-CPU MCE interrupts
The per-CPU MCE interrupts are looked up by reference and need to be de-referenced before printing.
--- scripts/gdb/linux/interrupts.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/gdb/linux/interrupts.py +1 -1
@@ -110,7 +110,7 @@ def x86_show_mce(prec, var, pfx, desc): pvar = gdb.parse_and_eval(var) text = "%*s: " % (prec, pfx) for cpu in cpus.each_online_cpu(): - text += "%10u " % (cpus.per_cpu(pvar, cpu)) + text += "%10u " % (cpus.per_cpu(pvar, cpu).dereference()) text += " %s\n" % (desc) return text
Signature · 1 line
2.43.0
Quoted 2 lines · On Mon, 23 Jun 2025 20:00:19 -0700 Florian Fainelli…
The per-CPU MCE interrupts are looked up by reference and need to be de-referenced before printing.
Again, please fully describe the problem which is being addressed.
(OK, I can see it's "prints wrong stuff", but something like example before-and-after output would be very helpful)
Quoted 9 lines · Andrew Morton
Quoted 2 lines · On Mon, 23 Jun 2025 20:00:19 -0700 Florian Fainelli…
The per-CPU MCE interrupts are looked up by reference and need to be de-referenced before printing.
Again, please fully describe the problem which is being addressed.
(OK, I can see it's "prints wrong stuff", but something like example before-and-after output would be very helpful)
Sure, I thought it was clear enough we were printing the variable address rather than its content, but I will make that clear in a v2.
Thanks!
Signature · 1 line
Florian