Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros
pgtable-2level.h File Reference

Go to the source code of this file.

Macros

#define pte_ERROR(e)   pr_err("%s:%d: bad pte %08lx\n", __FILE__, __LINE__, (e).pte_low)
 
#define pgd_ERROR(e)   pr_err("%s:%d: bad pgd %08lx\n", __FILE__, __LINE__, pgd_val(e))
 
#define native_ptep_get_and_clear(xp)   native_local_ptep_get_and_clear(xp)
 
#define native_pmdp_get_and_clear(xp)   native_local_pmdp_get_and_clear(xp)
 
#define PTE_FILE_MAX_BITS   29
 
#define PTE_FILE_SHIFT1   (_PAGE_BIT_PRESENT + 1)
 
#define PTE_FILE_SHIFT2   (_PAGE_BIT_PROTNONE + 1)
 
#define PTE_FILE_SHIFT3   (_PAGE_BIT_FILE + 1)
 
#define PTE_FILE_BITS1   (PTE_FILE_SHIFT2 - PTE_FILE_SHIFT1 - 1)
 
#define PTE_FILE_BITS2   (PTE_FILE_SHIFT3 - PTE_FILE_SHIFT2 - 1)
 
#define pte_to_pgoff(pte)
 
#define pgoff_to_pte(off)
 
#define SWP_TYPE_BITS   (_PAGE_BIT_PROTNONE - _PAGE_BIT_PRESENT - 1)
 
#define SWP_OFFSET_SHIFT   (_PAGE_BIT_FILE + 1)
 
#define MAX_SWAPFILES_CHECK()   BUILD_BUG_ON(MAX_SWAPFILES_SHIFT > SWP_TYPE_BITS)
 
#define __swp_type(x)
 
#define __swp_offset(x)   ((x).val >> SWP_OFFSET_SHIFT)
 
#define __swp_entry(type, offset)
 
#define __pte_to_swp_entry(pte)   ((swp_entry_t) { (pte).pte_low })
 
#define __swp_entry_to_pte(x)   ((pte_t) { .pte = (x).val })
 

Macro Definition Documentation

#define __pte_to_swp_entry (   pte)    ((swp_entry_t) { (pte).pte_low })

Definition at line 108 of file pgtable-2level.h.

#define __swp_entry (   type,
  offset 
)
Value:
((type) << (_PAGE_BIT_PRESENT + 1)) \

Definition at line 105 of file pgtable-2level.h.

#define __swp_entry_to_pte (   x)    ((pte_t) { .pte = (x).val })

Definition at line 109 of file pgtable-2level.h.

#define __swp_offset (   x)    ((x).val >> SWP_OFFSET_SHIFT)

Definition at line 104 of file pgtable-2level.h.

#define __swp_type (   x)
Value:
(((x).val >> (_PAGE_BIT_PRESENT + 1)) \
& ((1U << SWP_TYPE_BITS) - 1))

Definition at line 102 of file pgtable-2level.h.

#define MAX_SWAPFILES_CHECK ( )    BUILD_BUG_ON(MAX_SWAPFILES_SHIFT > SWP_TYPE_BITS)

Definition at line 100 of file pgtable-2level.h.

#define native_pmdp_get_and_clear (   xp)    native_local_pmdp_get_and_clear(xp)

Definition at line 55 of file pgtable-2level.h.

#define native_ptep_get_and_clear (   xp)    native_local_ptep_get_and_clear(xp)

Definition at line 46 of file pgtable-2level.h.

#define pgd_ERROR (   e)    pr_err("%s:%d: bad pgd %08lx\n", __FILE__, __LINE__, pgd_val(e))

Definition at line 6 of file pgtable-2level.h.

#define pgoff_to_pte (   off)
Value:
((pte_t) { .pte_low = \
(((off) & ((1U << PTE_FILE_BITS1) - 1)) << PTE_FILE_SHIFT1) \
+ ((((off) >> PTE_FILE_BITS1) & ((1U << PTE_FILE_BITS2) - 1)) \
+ (((off) >> (PTE_FILE_BITS1 + PTE_FILE_BITS2)) \

Definition at line 82 of file pgtable-2level.h.

#define pte_ERROR (   e)    pr_err("%s:%d: bad pte %08lx\n", __FILE__, __LINE__, (e).pte_low)

Definition at line 4 of file pgtable-2level.h.

#define PTE_FILE_BITS1   (PTE_FILE_SHIFT2 - PTE_FILE_SHIFT1 - 1)

Definition at line 71 of file pgtable-2level.h.

#define PTE_FILE_BITS2   (PTE_FILE_SHIFT3 - PTE_FILE_SHIFT2 - 1)

Definition at line 72 of file pgtable-2level.h.

#define PTE_FILE_MAX_BITS   29

Definition at line 62 of file pgtable-2level.h.

#define PTE_FILE_SHIFT1   (_PAGE_BIT_PRESENT + 1)

Definition at line 63 of file pgtable-2level.h.

#define PTE_FILE_SHIFT2   (_PAGE_BIT_PROTNONE + 1)

Definition at line 68 of file pgtable-2level.h.

#define PTE_FILE_SHIFT3   (_PAGE_BIT_FILE + 1)

Definition at line 69 of file pgtable-2level.h.

#define pte_to_pgoff (   pte)
Value:
((((pte).pte_low >> PTE_FILE_SHIFT1) \
& ((1U << PTE_FILE_BITS1) - 1)) \
+ ((((pte).pte_low >> PTE_FILE_SHIFT2) \
& ((1U << PTE_FILE_BITS2) - 1)) << PTE_FILE_BITS1) \
+ (((pte).pte_low >> PTE_FILE_SHIFT3) \

Definition at line 74 of file pgtable-2level.h.

#define SWP_OFFSET_SHIFT   (_PAGE_BIT_FILE + 1)

Definition at line 97 of file pgtable-2level.h.

#define SWP_TYPE_BITS   (_PAGE_BIT_PROTNONE - _PAGE_BIT_PRESENT - 1)

Definition at line 96 of file pgtable-2level.h.