patch-2.3.45 linux/include/asm-mips/pgtable.h
Next file: linux/include/asm-ppc/elf.h
Previous file: linux/include/asm-m68k/softirq.h
Back to the patch index
Back to the overall index
- Lines: 14
- Date:
Sun Feb 13 10:31:07 2000
- Orig file:
v2.3.44/linux/include/asm-mips/pgtable.h
- Orig date:
Thu Feb 10 17:11:20 2000
diff -u --recursive --new-file v2.3.44/linux/include/asm-mips/pgtable.h linux/include/asm-mips/pgtable.h
@@ -371,10 +371,12 @@
/* to find an entry in a kernel page-table-directory */
#define pgd_offset_k(address) pgd_offset(&init_mm, address)
+#define pgd_index(address) ((address) >> PGDIR_SHIFT)
+
/* to find an entry in a page-table-directory */
extern inline pgd_t *pgd_offset(struct mm_struct *mm, unsigned long address)
{
- return mm->pgd + (address >> PGDIR_SHIFT);
+ return mm->pgd + pgd_index(address);
}
/* Find an entry in the second-level page table.. */
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)