diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2005-10-21 02:55:38 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-10-28 11:16:46 -0400 |
commit | af4ca457eaf2d6682059c18463eb106e2ce58198 (patch) | |
tree | 399ca5ab3b15d723a6aefd04c764a2a06089ed06 /mm/page_alloc.c | |
parent | 434f1d10c1adb6c2e333d501ce1e42be610e0723 (diff) |
[PATCH] gfp_t: infrastructure
Beginning of gfp_t annotations:
- -Wbitwise added to CHECKFLAGS
- old __bitwise renamed to __bitwise__
- __bitwise defined to either __bitwise__ or nothing, depending on
__CHECK_ENDIAN__ being defined
- gfp_t switched from __nocast to __bitwise__
- force cast to gfp_t added to __GFP_... constants
- new helper - gfp_zone(); extracts zone bits out of gfp_t value and casts
the result to int
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'mm/page_alloc.c')
-rw-r--r-- | mm/page_alloc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/mm/page_alloc.c b/mm/page_alloc.c index e1d3d77f4aee..aa43ae3ab8c9 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c | |||
@@ -1089,7 +1089,7 @@ static unsigned int nr_free_zone_pages(int offset) | |||
1089 | */ | 1089 | */ |
1090 | unsigned int nr_free_buffer_pages(void) | 1090 | unsigned int nr_free_buffer_pages(void) |
1091 | { | 1091 | { |
1092 | return nr_free_zone_pages(GFP_USER & GFP_ZONEMASK); | 1092 | return nr_free_zone_pages(gfp_zone(GFP_USER)); |
1093 | } | 1093 | } |
1094 | 1094 | ||
1095 | /* | 1095 | /* |
@@ -1097,7 +1097,7 @@ unsigned int nr_free_buffer_pages(void) | |||
1097 | */ | 1097 | */ |
1098 | unsigned int nr_free_pagecache_pages(void) | 1098 | unsigned int nr_free_pagecache_pages(void) |
1099 | { | 1099 | { |
1100 | return nr_free_zone_pages(GFP_HIGHUSER & GFP_ZONEMASK); | 1100 | return nr_free_zone_pages(gfp_zone(GFP_HIGHUSER)); |
1101 | } | 1101 | } |
1102 | 1102 | ||
1103 | #ifdef CONFIG_HIGHMEM | 1103 | #ifdef CONFIG_HIGHMEM |