aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/lib-32
diff options
context:
space:
mode:
authorAtsushi Nemoto <anemo@mba.ocn.ne.jp>2006-02-01 11:29:14 -0500
committerRalf Baechle <ralf@linux-mips.org>2006-02-07 08:30:26 -0500
commitd1e30a6347630ca7eeee2f46f826f05bbe80bb25 (patch)
treefff9475b0b70d96989c5a3143f2448f995f24ac4 /arch/mips/lib-32
parent5665a0ac59a656b94cbf3c4642b32024a6c1cf75 (diff)
[MIPS] Fix dump_tlb.c warning and cleanup.
Signed-off-by: Atsushi Nemoto <anemo@mba.ocn.ne.jp> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/lib-32')
-rw-r--r--arch/mips/lib-32/dump_tlb.c33
1 files changed, 15 insertions, 18 deletions
diff --git a/arch/mips/lib-32/dump_tlb.c b/arch/mips/lib-32/dump_tlb.c
index 46519f4331eb..c49a925d0169 100644
--- a/arch/mips/lib-32/dump_tlb.c
+++ b/arch/mips/lib-32/dump_tlb.c
@@ -158,29 +158,26 @@ void dump_list_process(struct task_struct *t, void *address)
158 printk("task->mm == %8p\n", t->mm); 158 printk("task->mm == %8p\n", t->mm);
159 //printk("tasks->mm.pgd == %08x\n", (unsigned int) t->mm->pgd); 159 //printk("tasks->mm.pgd == %08x\n", (unsigned int) t->mm->pgd);
160 160
161 if (addr > KSEG0) 161 if (addr > KSEG0) {
162 page_dir = pgd_offset_k(0); 162 page_dir = pgd_offset_k(0);
163 else if (t->mm) {
164 page_dir = pgd_offset(t->mm, 0);
165 printk("page_dir == %08x\n", (unsigned int) page_dir);
166 } else
167 printk("Current thread has no mm\n");
168
169 if (addr > KSEG0)
170 pgd = pgd_offset_k(addr); 163 pgd = pgd_offset_k(addr);
171 else if (t->mm) { 164 } else if (t->mm) {
165 page_dir = pgd_offset(t->mm, 0);
172 pgd = pgd_offset(t->mm, addr); 166 pgd = pgd_offset(t->mm, addr);
173 printk("pgd == %08x, ", (unsigned int) pgd); 167 } else {
174 pud = pud_offset(pgd, addr); 168 printk("Current thread has no mm\n");
175 printk("pud == %08x, ", (unsigned int) pud); 169 return;
170 }
171 printk("page_dir == %08x\n", (unsigned int) page_dir);
172 printk("pgd == %08x, ", (unsigned int) pgd);
173 pud = pud_offset(pgd, addr);
174 printk("pud == %08x, ", (unsigned int) pud);
176 175
177 pmd = pmd_offset(pud, addr); 176 pmd = pmd_offset(pud, addr);
178 printk("pmd == %08x, ", (unsigned int) pmd); 177 printk("pmd == %08x, ", (unsigned int) pmd);
179 178
180 pte = pte_offset(pmd, addr); 179 pte = pte_offset(pmd, addr);
181 printk("pte == %08x, ", (unsigned int) pte); 180 printk("pte == %08x, ", (unsigned int) pte);
182 } else
183 printk("Current thread has no mm\n");
184 181
185 page = *pte; 182 page = *pte;
186#ifdef CONFIG_64BIT_PHYS_ADDR 183#ifdef CONFIG_64BIT_PHYS_ADDR