diff options
Diffstat (limited to 'include/linux/page-flags.h')
-rw-r--r-- | include/linux/page-flags.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/include/linux/page-flags.h b/include/linux/page-flags.h index dede8d412dca..d52999c43336 100644 --- a/include/linux/page-flags.h +++ b/include/linux/page-flags.h | |||
@@ -79,13 +79,23 @@ | |||
79 | /* | 79 | /* |
80 | * Global page accounting. One instance per CPU. Only unsigned longs are | 80 | * Global page accounting. One instance per CPU. Only unsigned longs are |
81 | * allowed. | 81 | * allowed. |
82 | * | ||
83 | * - Fields can be modified with xxx_page_state and xxx_page_state_zone at | ||
84 | * any time safely (which protects the instance from modification by | ||
85 | * interrupt. | ||
86 | * - The __xxx_page_state variants can be used safely when interrupts are | ||
87 | * disabled. | ||
88 | * - The __xxx_page_state variants can be used if the field is only | ||
89 | * modified from process context, or only modified from interrupt context. | ||
90 | * In this case, the field should be commented here. | ||
82 | */ | 91 | */ |
83 | struct page_state { | 92 | struct page_state { |
84 | unsigned long nr_dirty; /* Dirty writeable pages */ | 93 | unsigned long nr_dirty; /* Dirty writeable pages */ |
85 | unsigned long nr_writeback; /* Pages under writeback */ | 94 | unsigned long nr_writeback; /* Pages under writeback */ |
86 | unsigned long nr_unstable; /* NFS unstable pages */ | 95 | unsigned long nr_unstable; /* NFS unstable pages */ |
87 | unsigned long nr_page_table_pages;/* Pages used for pagetables */ | 96 | unsigned long nr_page_table_pages;/* Pages used for pagetables */ |
88 | unsigned long nr_mapped; /* mapped into pagetables */ | 97 | unsigned long nr_mapped; /* mapped into pagetables. |
98 | * only modified from process context */ | ||
89 | unsigned long nr_slab; /* In slab */ | 99 | unsigned long nr_slab; /* In slab */ |
90 | #define GET_PAGE_STATE_LAST nr_slab | 100 | #define GET_PAGE_STATE_LAST nr_slab |
91 | 101 | ||