Index: linux-2.6.18-mm3/arch/ia64/kernel/ivt.S =================================================================== --- linux-2.6.18-mm3.orig/arch/ia64/kernel/ivt.S 2006-10-09 11:33:23.217383415 -0700 +++ linux-2.6.18-mm3/arch/ia64/kernel/ivt.S 2006-10-09 13:08:27.339269403 -0700 @@ -429,24 +429,21 @@ ENTRY(nested_dtlb_miss) mov r19=IA64_KR(PT_BASE) // get the page table base address shl r21=r16,3 // shift bit 60 into sign bit mov r18=cr.itir - shr.u r17=r16,61 // get the region number into r17 ;; - cmp.eq p6,p7=5,r17 // kernel region? - cmp.eq p9,p0=4,r17 // select other pgd for vmmap huge region? + shr.u r17=r16,61 // get the region number into r17 extr.u r18=r18,2,6 // get the faulting page size ;; -(p7) cmp.eq p6,p7=4,r17 // huge region switches processing - add r22=-PAGE_SHIFT,r18 // page order - add r18=PGDIR_SHIFT-PAGE_SHIFT+3,r18 // Calculate shift to get to nr of pgd + cmp.eq p6,p7=5,r17 // is faulting address in region 5? + add r22=-PAGE_SHIFT,r18 // adjustment for hugetlb address + add r18=PGDIR_SHIFT-PAGE_SHIFT,r18 ;; shr.u r22=r16,r22 - shr.u r18=r21,r18 + shr.u r18=r16,r18 (p7) dep r17=r17,r19,(PAGE_SHIFT-3),3 // put region number bits in place srlz.d LOAD_PHYSICAL(p6, r19, swapper_pg_dir) // region 5 is rooted at swapper_pg_dir - ;; - LOAD_PHYSICAL(p9, r19, memmap_pg_dir) // region 4 may also be rooted at memmap_pg_dir + .pred.rel "mutex", p6, p7 (p6) shr.u r21=r21,PGDIR_SHIFT+PAGE_SHIFT (p7) shr.u r21=r21,PGDIR_SHIFT+PAGE_SHIFT-3