diff options
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/vmstat.h | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/include/linux/vmstat.h b/include/linux/vmstat.h index d673b7b..1ab806c 100644 --- a/include/linux/vmstat.h +++ b/include/linux/vmstat.h @@ -186,11 +186,16 @@ static inline void __mod_zone_page_state(struct zone *zone, zone_page_state_add(delta, zone, item); } +static inline void __inc_zone_state(struct zone *zone, enum zone_stat_item item) +{ + atomic_long_inc(&zone->vm_stat[item]); + atomic_long_inc(&vm_stat[item]); +} + static inline void __inc_zone_page_state(struct page *page, enum zone_stat_item item) { - atomic_long_inc(&page_zone(page)->vm_stat[item]); - atomic_long_inc(&vm_stat[item]); + __inc_zone_state(page_zone(page), item); } static inline void __dec_zone_page_state(struct page *page, |