diff options
author | Dave Airlie <airlied@redhat.com> | 2015-10-16 03:10:32 +0300 |
---|---|---|
committer | Dave Airlie <airlied@redhat.com> | 2015-10-16 03:25:28 +0300 |
commit | 48f87dd146a480c723774962eca675873a8aa1da (patch) | |
tree | 71461989ebe8a20258ca4b0be341b755594a2b0b /include/linux/mm.h | |
parent | 6b62b3e134676687d5d666e6edc3b45f1507b2b7 (diff) | |
parent | 06d1ee32a4d25356a710b49d5e95dbdd68bdf505 (diff) | |
download | linux-48f87dd146a480c723774962eca675873a8aa1da.tar.xz |
Merge commit '06d1ee32a4d25356a710b49d5e95dbdd68bdf505' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux into drm-next
Backmerge the drm-fixes pull from Linus's tree into drm-next.
This is to fix some conflicts and make future pulls cleaner
Diffstat (limited to 'include/linux/mm.h')
-rw-r--r-- | include/linux/mm.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/include/linux/mm.h b/include/linux/mm.h index 91c08f6f0dc9..80001de019ba 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -905,6 +905,27 @@ static inline void set_page_links(struct page *page, enum zone_type zone, #endif } +#ifdef CONFIG_MEMCG +static inline struct mem_cgroup *page_memcg(struct page *page) +{ + return page->mem_cgroup; +} + +static inline void set_page_memcg(struct page *page, struct mem_cgroup *memcg) +{ + page->mem_cgroup = memcg; +} +#else +static inline struct mem_cgroup *page_memcg(struct page *page) +{ + return NULL; +} + +static inline void set_page_memcg(struct page *page, struct mem_cgroup *memcg) +{ +} +#endif + /* * Some inline functions in vmstat.h depend on page_zone() */ |