Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Macros | Enumerations | Functions
page-flags.h File Reference
#include <linux/types.h>
#include <linux/bug.h>
#include <linux/mmdebug.h>
#include <linux/mm_types.h>
#include <generated/bounds.h>

Go to the source code of this file.

Macros

#define TESTPAGEFLAG(uname, lname)
 
#define SETPAGEFLAG(uname, lname)
 
#define CLEARPAGEFLAG(uname, lname)
 
#define __SETPAGEFLAG(uname, lname)
 
#define __CLEARPAGEFLAG(uname, lname)
 
#define TESTSETFLAG(uname, lname)
 
#define TESTCLEARFLAG(uname, lname)
 
#define __TESTCLEARFLAG(uname, lname)
 
#define PAGEFLAG(uname, lname)
 
#define __PAGEFLAG(uname, lname)
 
#define PAGEFLAG_FALSE(uname)
 
#define TESTSCFLAG(uname, lname)   TESTSETFLAG(uname, lname) TESTCLEARFLAG(uname, lname)
 
#define SETPAGEFLAG_NOOP(uname)   static inline void SetPage##uname(struct page *page) { }
 
#define CLEARPAGEFLAG_NOOP(uname)   static inline void ClearPage##uname(struct page *page) { }
 
#define __CLEARPAGEFLAG_NOOP(uname)   static inline void __ClearPage##uname(struct page *page) { }
 
#define TESTCLEARFLAG_FALSE(uname)   static inline int TestClearPage##uname(struct page *page) { return 0; }
 
#define __TESTCLEARFLAG_FALSE(uname)   static inline int __TestClearPage##uname(struct page *page) { return 0; }
 
#define __PG_HWPOISON   0
 
#define PG_head_tail_mask   ((1L << PG_compound) | (1L << PG_reclaim))
 
#define __PG_MLOCKED   0
 
#define __PG_COMPOUND_LOCK   0
 
#define PAGE_FLAGS_CHECK_AT_FREE
 
#define PAGE_FLAGS_CHECK_AT_PREP   ((1 << NR_PAGEFLAGS) - 1)
 
#define PAGE_FLAGS_PRIVATE   (1 << PG_private | 1 << PG_private_2)
 

Enumerations

enum  pageflags {
  PG_locked, PG_error, PG_referenced, PG_uptodate,
  PG_dirty, PG_lru, PG_active, PG_slab,
  PG_owner_priv_1, PG_arch_1, PG_reserved, PG_private,
  PG_private_2, PG_writeback, PG_compound, PG_swapcache,
  PG_mappedtodisk, PG_reclaim, PG_swapbacked, PG_unevictable,
  __NR_PAGEFLAGS, PG_checked = PG_owner_priv_1, PG_fscache = PG_private_2, PG_pinned = PG_owner_priv_1,
  PG_savepinned = PG_dirty, PG_slob_free = PG_private
}
 

Functions

 PAGEFLAG (Error, error) TESTCLEARFLAG(Error
 
error PAGEFLAG (Referenced, referenced) TESTCLEARFLAG(Referenced
 
error referenced PAGEFLAG (Dirty, dirty) TESTSCFLAG(Dirty
 
error referenced dirty __CLEARPAGEFLAG (Dirty, dirty) PAGEFLAG(LRU
 
error referenced dirty lru __CLEARPAGEFLAG (LRU, lru) PAGEFLAG(Active
 
error referenced dirty lru active __CLEARPAGEFLAG (Active, active) PAGEFLAG(Checked
 
error referenced dirty lru
active checked 
PAGEFLAG (Pinned, pinned) TESTSCFLAG(Pinned
 
error referenced dirty lru
active checked pinned 
PAGEFLAG (SavePinned, savepinned)
 
 PAGEFLAG (Reserved, reserved) __CLEARPAGEFLAG(Reserved
 
reserved PAGEFLAG (SwapBacked, swapbacked) __CLEARPAGEFLAG(SwapBacked
 
reserved swapbacked PAGEFLAG (Private, private) __SETPAGEFLAG(Private
 
reserved swapbacked private PAGEFLAG (Private2, private_2) TESTSCFLAG(Private2
 
reserved swapbacked private
private_2 
PAGEFLAG (OwnerPriv1, owner_priv_1) TESTCLEARFLAG(OwnerPriv1
 
reserved swapbacked private
private_2 owner_priv_1 
TESTPAGEFLAG (Writeback, writeback) TESTSCFLAG(Writeback
 
reserved swapbacked private
private_2 owner_priv_1
writeback 
PAGEFLAG (Reclaim, reclaim) TESTCLEARFLAG(Reclaim
 
reserved swapbacked private
private_2 owner_priv_1
writeback reclaim 
PAGEFLAG (Readahead, reclaim) SETPAGEFLAG_NOOP(SwapCache) CLEARPAGEFLAG_NOOP(SwapCache) PAGEFLAG(Unevictable
 
reserved swapbacked private
private_2 owner_priv_1
writeback reclaim unevictable 
__CLEARPAGEFLAG (Unevictable, unevictable) PAGEFLAG_FALSE(Mlocked) SETPAGEFLAG_NOOP(Mlocked) TESTCLEARFLAG_FALSE(Mlocked) __TESTCLEARFLAG_FALSE(Mlocked) u64 stable_page_flags(struct page *page)
 
void cancel_dirty_page (struct page *page, unsigned int account_size)
 
int test_clear_page_writeback (struct page *page)
 
int test_set_page_writeback (struct page *page)
 

Macro Definition Documentation

#define __CLEARPAGEFLAG (   uname,
  lname 
)
Value:
static inline void __ClearPage##uname(struct page *page) \
{ __clear_bit(PG_##lname, &page->flags); }

Definition at line 152 of file page-flags.h.

#define __CLEARPAGEFLAG_NOOP (   uname)    static inline void __ClearPage##uname(struct page *page) { }

Definition at line 187 of file page-flags.h.

#define __PAGEFLAG (   uname,
  lname 
)
Value:
TESTPAGEFLAG(uname, lname) \
__SETPAGEFLAG(uname, lname) __CLEARPAGEFLAG(uname, lname)

Definition at line 171 of file page-flags.h.

#define __PG_COMPOUND_LOCK   0

Definition at line 494 of file page-flags.h.

#define __PG_HWPOISON   0
#define __PG_MLOCKED   0

Definition at line 488 of file page-flags.h.

#define __SETPAGEFLAG (   uname,
  lname 
)
Value:
static inline void __SetPage##uname(struct page *page) \
{ __set_bit(PG_##lname, &page->flags); }

Definition at line 148 of file page-flags.h.

#define __TESTCLEARFLAG (   uname,
  lname 
)
Value:
static inline int __TestClearPage##uname(struct page *page) \
{ return __test_and_clear_bit(PG_##lname, &page->flags); }

Definition at line 164 of file page-flags.h.

#define __TESTCLEARFLAG_FALSE (   uname)    static inline int __TestClearPage##uname(struct page *page) { return 0; }

Definition at line 193 of file page-flags.h.

#define CLEARPAGEFLAG (   uname,
  lname 
)
Value:
static inline void ClearPage##uname(struct page *page) \
{ clear_bit(PG_##lname, &page->flags); }

Definition at line 144 of file page-flags.h.

#define CLEARPAGEFLAG_NOOP (   uname)    static inline void ClearPage##uname(struct page *page) { }

Definition at line 184 of file page-flags.h.

#define PAGE_FLAGS_CHECK_AT_FREE
Value:
(1 << PG_lru | 1 << PG_locked | \
1 << PG_private | 1 << PG_private_2 | \
1 << PG_writeback | 1 << PG_reserved | \
1 << PG_slab | 1 << PG_swapcache | 1 << PG_active | \
__PG_COMPOUND_LOCK)

Definition at line 501 of file page-flags.h.

#define PAGE_FLAGS_CHECK_AT_PREP   ((1 << NR_PAGEFLAGS) - 1)

Definition at line 514 of file page-flags.h.

#define PAGE_FLAGS_PRIVATE   (1 << PG_private | 1 << PG_private_2)

Definition at line 516 of file page-flags.h.

#define PAGEFLAG (   uname,
  lname 
)
Value:
TESTPAGEFLAG(uname, lname) \
SETPAGEFLAG(uname, lname) CLEARPAGEFLAG(uname, lname)

Definition at line 168 of file page-flags.h.

#define PAGEFLAG_FALSE (   uname)
Value:
static inline int Page##uname(const struct page *page) \
{ return 0; }

Definition at line 174 of file page-flags.h.

#define PG_head_tail_mask   ((1L << PG_compound) | (1L << PG_reclaim))

Definition at line 377 of file page-flags.h.

#define SETPAGEFLAG (   uname,
  lname 
)
Value:
static inline void SetPage##uname(struct page *page) \
{ set_bit(PG_##lname, &page->flags); }

Definition at line 140 of file page-flags.h.

#define SETPAGEFLAG_NOOP (   uname)    static inline void SetPage##uname(struct page *page) { }

Definition at line 181 of file page-flags.h.

#define TESTCLEARFLAG (   uname,
  lname 
)
Value:
static inline int TestClearPage##uname(struct page *page) \
{ return test_and_clear_bit(PG_##lname, &page->flags); }

Definition at line 160 of file page-flags.h.

#define TESTCLEARFLAG_FALSE (   uname)    static inline int TestClearPage##uname(struct page *page) { return 0; }

Definition at line 190 of file page-flags.h.

#define TESTPAGEFLAG (   uname,
  lname 
)
Value:
static inline int Page##uname(const struct page *page) \
{ return test_bit(PG_##lname, &page->flags); }

Definition at line 136 of file page-flags.h.

#define TESTSCFLAG (   uname,
  lname 
)    TESTSETFLAG(uname, lname) TESTCLEARFLAG(uname, lname)

Definition at line 178 of file page-flags.h.

#define TESTSETFLAG (   uname,
  lname 
)
Value:
static inline int TestSetPage##uname(struct page *page) \
{ return test_and_set_bit(PG_##lname, &page->flags); }

Definition at line 156 of file page-flags.h.

Enumeration Type Documentation

enum pageflags
Enumerator:
PG_locked 
PG_error 
PG_referenced 
PG_uptodate 
PG_dirty 
PG_lru 
PG_active 
PG_slab 
PG_owner_priv_1 
PG_arch_1 
PG_reserved 
PG_private 
PG_private_2 
PG_writeback 
PG_compound 
PG_swapcache 
PG_mappedtodisk 
PG_reclaim 
PG_swapbacked 
PG_unevictable 
__NR_PAGEFLAGS 
PG_checked 
PG_fscache 
PG_pinned 
PG_savepinned 
PG_slob_free 

Definition at line 74 of file page-flags.h.

Function Documentation

error referenced dirty __CLEARPAGEFLAG ( Dirty  ,
dirty   
)
error referenced dirty lru __CLEARPAGEFLAG ( LRU  ,
lru   
)
error referenced dirty lru active __CLEARPAGEFLAG ( Active  ,
active   
)
reserved swapbacked private private_2 owner_priv_1 writeback reclaim unevictable __CLEARPAGEFLAG ( Unevictable  ,
unevictable   
)
void cancel_dirty_page ( struct page page,
unsigned int  account_size 
)

Definition at line 74 of file truncate.c.

PAGEFLAG ( Error  ,
error   
)
error PAGEFLAG ( Referenced  ,
referenced   
)
error referenced PAGEFLAG ( Dirty  ,
dirty   
)
error referenced dirty lru active checked PAGEFLAG ( Pinned  ,
pinned   
)
error referenced dirty lru active checked pinned PAGEFLAG ( SavePinned  ,
savepinned   
)
PAGEFLAG ( Reserved  ,
reserved   
)
reserved PAGEFLAG ( SwapBacked  ,
swapbacked   
)
reserved swapbacked PAGEFLAG ( Private  ,
private   
)
reserved swapbacked private PAGEFLAG ( Private2  ,
private_2   
)
reserved swapbacked private private_2 PAGEFLAG ( OwnerPriv1  ,
owner_priv_1   
)
reserved swapbacked private private_2 owner_priv_1 writeback PAGEFLAG ( Reclaim  ,
reclaim   
)
reserved swapbacked private private_2 owner_priv_1 writeback reclaim PAGEFLAG ( Readahead  ,
reclaim   
)
int test_clear_page_writeback ( struct page page)

Definition at line 2202 of file page-writeback.c.

int test_set_page_writeback ( struct page page)

Definition at line 2233 of file page-writeback.c.

reserved swapbacked private private_2 owner_priv_1 TESTPAGEFLAG ( Writeback  ,
writeback   
)