aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/lib/dump_tlb.c
diff options
context:
space:
mode:
authorJames Hogan <james.hogan@imgtec.com>2015-07-15 11:17:47 -0400
committerRalf Baechle <ralf@linux-mips.org>2015-09-03 06:07:48 -0400
commitbae637a2148c97882a1bbfdac08d7a5f4441cdb3 (patch)
tree7040afaefa29dff7006b3574051fd2f755fa31ee /arch/mips/lib/dump_tlb.c
parent9bd860cae3c46a83371ce899ae0d665b6e253687 (diff)
MIPS: Rearrange ENTRYLO field definitions
The generic field definitions (i.e. present before MIPS32/MIPS64) in mipsregs.h are conventionally not prefixed with MIPS_, so rename the recently added MIPS_ENTRYLO_* definitions for the G, V, D, and C fields to ENTRYLO_*. Also rearrange to put the EntryLo and EntryHi definitions in the right place in the file. Fixes: 8ab6abcb6aa4 ("MIPS: mipsregs.h: Add EntryLo bit definitions") Reported-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/10725/ Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/lib/dump_tlb.c')
-rw-r--r--arch/mips/lib/dump_tlb.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/arch/mips/lib/dump_tlb.c b/arch/mips/lib/dump_tlb.c
index 64f90f626681..92a37319efbe 100644
--- a/arch/mips/lib/dump_tlb.c
+++ b/arch/mips/lib/dump_tlb.c
@@ -114,7 +114,7 @@ static void dump_tlb(int first, int last)
114 * leave only a single G bit set after a machine check exception 114 * leave only a single G bit set after a machine check exception
115 * due to duplicate TLB entry. 115 * due to duplicate TLB entry.
116 */ 116 */
117 if (!((entrylo0 | entrylo1) & MIPS_ENTRYLO_G) && 117 if (!((entrylo0 | entrylo1) & ENTRYLO_G) &&
118 (entryhi & 0xff) != asid) 118 (entryhi & 0xff) != asid)
119 continue; 119 continue;
120 120
@@ -123,8 +123,8 @@ static void dump_tlb(int first, int last)
123 */ 123 */
124 printk("Index: %2d pgmask=%s ", i, msk2str(pagemask)); 124 printk("Index: %2d pgmask=%s ", i, msk2str(pagemask));
125 125
126 c0 = (entrylo0 & MIPS_ENTRYLO_C) >> MIPS_ENTRYLO_C_SHIFT; 126 c0 = (entrylo0 & ENTRYLO_C) >> ENTRYLO_C_SHIFT;
127 c1 = (entrylo1 & MIPS_ENTRYLO_C) >> MIPS_ENTRYLO_C_SHIFT; 127 c1 = (entrylo1 & ENTRYLO_C) >> ENTRYLO_C_SHIFT;
128 128
129 printk("va=%0*lx asid=%02lx\n", 129 printk("va=%0*lx asid=%02lx\n",
130 vwidth, (entryhi & ~0x1fffUL), 130 vwidth, (entryhi & ~0x1fffUL),
@@ -141,9 +141,9 @@ static void dump_tlb(int first, int last)
141 (entrylo0 & MIPS_ENTRYLO_XI) ? 1 : 0); 141 (entrylo0 & MIPS_ENTRYLO_XI) ? 1 : 0);
142 printk("pa=%0*llx c=%d d=%d v=%d g=%d] [", 142 printk("pa=%0*llx c=%d d=%d v=%d g=%d] [",
143 pwidth, pa, c0, 143 pwidth, pa, c0,
144 (entrylo0 & MIPS_ENTRYLO_D) ? 1 : 0, 144 (entrylo0 & ENTRYLO_D) ? 1 : 0,
145 (entrylo0 & MIPS_ENTRYLO_V) ? 1 : 0, 145 (entrylo0 & ENTRYLO_V) ? 1 : 0,
146 (entrylo0 & MIPS_ENTRYLO_G) ? 1 : 0); 146 (entrylo0 & ENTRYLO_G) ? 1 : 0);
147 /* RI/XI are in awkward places, so mask them off separately */ 147 /* RI/XI are in awkward places, so mask them off separately */
148 pa = entrylo1 & ~(MIPS_ENTRYLO_RI | MIPS_ENTRYLO_XI); 148 pa = entrylo1 & ~(MIPS_ENTRYLO_RI | MIPS_ENTRYLO_XI);
149 if (xpa) 149 if (xpa)
@@ -155,9 +155,9 @@ static void dump_tlb(int first, int last)
155 (entrylo1 & MIPS_ENTRYLO_XI) ? 1 : 0); 155 (entrylo1 & MIPS_ENTRYLO_XI) ? 1 : 0);
156 printk("pa=%0*llx c=%d d=%d v=%d g=%d]\n", 156 printk("pa=%0*llx c=%d d=%d v=%d g=%d]\n",
157 pwidth, pa, c1, 157 pwidth, pa, c1,
158 (entrylo1 & MIPS_ENTRYLO_D) ? 1 : 0, 158 (entrylo1 & ENTRYLO_D) ? 1 : 0,
159 (entrylo1 & MIPS_ENTRYLO_V) ? 1 : 0, 159 (entrylo1 & ENTRYLO_V) ? 1 : 0,
160 (entrylo1 & MIPS_ENTRYLO_G) ? 1 : 0); 160 (entrylo1 & ENTRYLO_G) ? 1 : 0);
161 } 161 }
162 printk("\n"); 162 printk("\n");
163 163