diff options
author | Kirill A. Shutemov <kirill.shutemov@linux.intel.com> | 2015-02-10 17:11:04 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2015-02-10 17:30:33 -0500 |
commit | 6e76d4b20bf6b514408ab5bd07f4a76723259b64 (patch) | |
tree | e4d2547209ca28630cae7fbb7ac5870799e7c3a5 /arch/s390 | |
parent | 8d55da810f1fabcf1d4c0bbc46205e5f2c0fa84b (diff) |
s390: drop pte_file()-related helpers
We've replaced remap_file_pages(2) implementation with emulation. Nobody
creates non-linear mapping anymore.
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
Acked-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/s390')
-rw-r--r-- | arch/s390/include/asm/pgtable.h | 29 |
1 files changed, 4 insertions, 25 deletions
diff --git a/arch/s390/include/asm/pgtable.h b/arch/s390/include/asm/pgtable.h index 5e102422c9ab..ffb1d8ce97ae 100644 --- a/arch/s390/include/asm/pgtable.h +++ b/arch/s390/include/asm/pgtable.h | |||
@@ -249,10 +249,10 @@ static inline int is_module_addr(void *addr) | |||
249 | _PAGE_YOUNG) | 249 | _PAGE_YOUNG) |
250 | 250 | ||
251 | /* | 251 | /* |
252 | * handle_pte_fault uses pte_present, pte_none and pte_file to find out the | 252 | * handle_pte_fault uses pte_present and pte_none to find out the pte type |
253 | * pte type WITHOUT holding the page table lock. The _PAGE_PRESENT bit | 253 | * WITHOUT holding the page table lock. The _PAGE_PRESENT bit is used to |
254 | * is used to distinguish present from not-present ptes. It is changed only | 254 | * distinguish present from not-present ptes. It is changed only with the page |
255 | * with the page table lock held. | 255 | * table lock held. |
256 | * | 256 | * |
257 | * The following table gives the different possible bit combinations for | 257 | * The following table gives the different possible bit combinations for |
258 | * the pte hardware and software bits in the last 12 bits of a pte: | 258 | * the pte hardware and software bits in the last 12 bits of a pte: |
@@ -279,7 +279,6 @@ static inline int is_module_addr(void *addr) | |||
279 | * | 279 | * |
280 | * pte_present is true for the bit pattern .xx...xxxxx1, (pte & 0x001) == 0x001 | 280 | * pte_present is true for the bit pattern .xx...xxxxx1, (pte & 0x001) == 0x001 |
281 | * pte_none is true for the bit pattern .10...xxxx00, (pte & 0x603) == 0x400 | 281 | * pte_none is true for the bit pattern .10...xxxx00, (pte & 0x603) == 0x400 |
282 | * pte_file is true for the bit pattern .11...xxxxx0, (pte & 0x601) == 0x600 | ||
283 | * pte_swap is true for the bit pattern .10...xxxx10, (pte & 0x603) == 0x402 | 282 | * pte_swap is true for the bit pattern .10...xxxx10, (pte & 0x603) == 0x402 |
284 | */ | 283 | */ |
285 | 284 | ||
@@ -671,13 +670,6 @@ static inline int pte_swap(pte_t pte) | |||
671 | == (_PAGE_INVALID | _PAGE_TYPE); | 670 | == (_PAGE_INVALID | _PAGE_TYPE); |
672 | } | 671 | } |
673 | 672 | ||
674 | static inline int pte_file(pte_t pte) | ||
675 | { | ||
676 | /* Bit pattern: (pte & 0x601) == 0x600 */ | ||
677 | return (pte_val(pte) & (_PAGE_INVALID | _PAGE_PROTECT | _PAGE_PRESENT)) | ||
678 | == (_PAGE_INVALID | _PAGE_PROTECT); | ||
679 | } | ||
680 | |||
681 | static inline int pte_special(pte_t pte) | 673 | static inline int pte_special(pte_t pte) |
682 | { | 674 | { |
683 | return (pte_val(pte) & _PAGE_SPECIAL); | 675 | return (pte_val(pte) & _PAGE_SPECIAL); |
@@ -1756,19 +1748,6 @@ static inline pte_t mk_swap_pte(unsigned long type, unsigned long offset) | |||
1756 | #define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) }) | 1748 | #define __pte_to_swp_entry(pte) ((swp_entry_t) { pte_val(pte) }) |
1757 | #define __swp_entry_to_pte(x) ((pte_t) { (x).val }) | 1749 | #define __swp_entry_to_pte(x) ((pte_t) { (x).val }) |
1758 | 1750 | ||
1759 | #ifndef CONFIG_64BIT | ||
1760 | # define PTE_FILE_MAX_BITS 26 | ||
1761 | #else /* CONFIG_64BIT */ | ||
1762 | # define PTE_FILE_MAX_BITS 59 | ||
1763 | #endif /* CONFIG_64BIT */ | ||
1764 | |||
1765 | #define pte_to_pgoff(__pte) \ | ||
1766 | ((((__pte).pte >> 12) << 7) + (((__pte).pte >> 1) & 0x7f)) | ||
1767 | |||
1768 | #define pgoff_to_pte(__off) \ | ||
1769 | ((pte_t) { ((((__off) & 0x7f) << 1) + (((__off) >> 7) << 12)) \ | ||
1770 | | _PAGE_INVALID | _PAGE_PROTECT }) | ||
1771 | |||
1772 | #endif /* !__ASSEMBLY__ */ | 1751 | #endif /* !__ASSEMBLY__ */ |
1773 | 1752 | ||
1774 | #define kern_addr_valid(addr) (1) | 1753 | #define kern_addr_valid(addr) (1) |