]> git.baikalelectronics.ru Git - kernel.git/commit
MIPS: Refactor dumping of TLB registers for r3k/r4k
authorJames Hogan <james.hogan@imgtec.com>
Wed, 15 Jul 2015 15:17:43 +0000 (16:17 +0100)
committerRalf Baechle <ralf@linux-mips.org>
Thu, 3 Sep 2015 10:07:45 +0000 (12:07 +0200)
commit735eb5538f0bf28723390b1e9c1db072814e3ff7
treea56689e5e3b8aa1296f81c1640fd71a02d471964
parent8e1402903e3708cd2de065b15a175c9503bea9fc
MIPS: Refactor dumping of TLB registers for r3k/r4k

The TLB registers are dumped in a couble of places:
 - sysrq_tlbdump_single() - when dumping TLB state.
 - do_mcheck() - in response to a machine check error.

The main TLB registers also differ between r3k and r4k, but r4k appears
to be assumed.

Refactor this code into a dump_tlb_regs() function, implemented for both
r3k and r4k, and used by both of the above functions.

Fixes: cbf4567f88e5 ("MIPS: Add SysRq operation to dump TLBs on all CPUs")
Suggested-by: Maciej W. Rozycki <macro@linux-mips.org>
Signed-off-by: James Hogan <james.hogan@imgtec.com>
Cc: Maciej W. Rozycki <macro@linux-mips.org>
Cc: linux-mips@linux-mips.org
Patchwork: https://patchwork.linux-mips.org/patch/10721/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/include/asm/tlbdebug.h
arch/mips/kernel/sysrq.c
arch/mips/kernel/traps.c
arch/mips/lib/dump_tlb.c
arch/mips/lib/r3k_dump_tlb.c
arch/mips/mm/tlb-r3k.c