Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 35
b: refs/heads/master
c: b464fce
h: refs/heads/master
i:
  33: c313424
  31: decb105
v: v3
  • Loading branch information
Kumar Gala authored and Linus Torvalds committed Apr 16, 2005
1 parent 217ce17 commit 9effb9b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a85f6d4aca822acdb49d27c44519cd6514b06a1d
refs/heads/master: b464fce5edc08a825907e9d48a2d2f1af0393fef
9 changes: 7 additions & 2 deletions trunk/include/asm-ppc/pgtable.h
Original file line number Diff line number Diff line change
Expand Up @@ -431,10 +431,15 @@ extern unsigned long bad_call_to_PMD_PAGE_SIZE(void);
* Conversions between PTE values and page frame numbers.
*/

#define pte_pfn(x) (pte_val(x) >> PAGE_SHIFT)
/* in some case we want to additionaly adjust where the pfn is in the pte to
* allow room for more flags */
#define PFN_SHIFT_OFFSET (PAGE_SHIFT)

#define pte_pfn(x) (pte_val(x) >> PFN_SHIFT_OFFSET)
#define pte_page(x) pfn_to_page(pte_pfn(x))

#define pfn_pte(pfn, prot) __pte(((pte_t)(pfn) << PAGE_SHIFT) | pgprot_val(prot))
#define pfn_pte(pfn, prot) __pte(((pte_basic_t)(pfn) << PFN_SHIFT_OFFSET) |\
pgprot_val(prot))
#define mk_pte(page, prot) pfn_pte(page_to_pfn(page), prot)

/*
Expand Down

0 comments on commit 9effb9b

Please sign in to comment.