aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWufei <fei.wu@windriver.com>2010-04-28 17:42:32 -0400
committerJason Wessel <jason.wessel@windriver.com>2010-04-29 22:41:44 -0400
commit56151e753468e34aeb322af4b0309ab727c97d2e (patch)
treedd2b28d468e3c5fda711df1c0a3a6a3356772be9
parent79dba2eaa771c3173957eccfd288e0e0d12e4d3f (diff)
kgdb: don't needlessly skip PAGE_USER test for Fsl booke
The bypassing of this test is a leftover from 2.4 vintage kernels, and is no longer appropriate, or even used by KGDB. Currently KGDB uses probe_kernel_write() for all access to memory via the KGDB core, so it can simply be deleted. This fixes CVE-2010-1446. CC: Benjamin Herrenschmidt <benh@kernel.crashing.org> CC: Paul Mackerras <paulus@samba.org> CC: Kumar Gala <galak@kernel.crashing.org> Signed-off-by: Wufei <fei.wu@windriver.com> Signed-off-by: Jason Wessel <jason.wessel@windriver.com>
-rw-r--r--arch/powerpc/mm/fsl_booke_mmu.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/arch/powerpc/mm/fsl_booke_mmu.c b/arch/powerpc/mm/fsl_booke_mmu.c
index c5394728bf2e..1ce9dd51a2f6 100644
--- a/arch/powerpc/mm/fsl_booke_mmu.c
+++ b/arch/powerpc/mm/fsl_booke_mmu.c
@@ -155,15 +155,10 @@ static void settlbcam(int index, unsigned long virt, phys_addr_t phys,
155 if (cur_cpu_spec->cpu_features & MMU_FTR_BIG_PHYS) 155 if (cur_cpu_spec->cpu_features & MMU_FTR_BIG_PHYS)
156 TLBCAM[index].MAS7 = (u64)phys >> 32; 156 TLBCAM[index].MAS7 = (u64)phys >> 32;
157 157
158#ifndef CONFIG_KGDB /* want user access for breakpoints */
159 if (flags & _PAGE_USER) { 158 if (flags & _PAGE_USER) {
160 TLBCAM[index].MAS3 |= MAS3_UX | MAS3_UR; 159 TLBCAM[index].MAS3 |= MAS3_UX | MAS3_UR;
161 TLBCAM[index].MAS3 |= ((flags & _PAGE_RW) ? MAS3_UW : 0); 160 TLBCAM[index].MAS3 |= ((flags & _PAGE_RW) ? MAS3_UW : 0);
162 } 161 }
163#else
164 TLBCAM[index].MAS3 |= MAS3_UX | MAS3_UR;
165 TLBCAM[index].MAS3 |= ((flags & _PAGE_RW) ? MAS3_UW : 0);
166#endif
167 162
168 tlbcam_addrs[index].start = virt; 163 tlbcam_addrs[index].start = virt;
169 tlbcam_addrs[index].limit = virt + size - 1; 164 tlbcam_addrs[index].limit = virt + size - 1;