aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/linux-2.6/kmem.h
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/linux-2.6/kmem.h')
-rw-r--r--fs/xfs/linux-2.6/kmem.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/fs/xfs/linux-2.6/kmem.h b/fs/xfs/linux-2.6/kmem.h
index ee7010f085bc..f4bb78c268c0 100644
--- a/fs/xfs/linux-2.6/kmem.h
+++ b/fs/xfs/linux-2.6/kmem.h
@@ -81,9 +81,9 @@ typedef unsigned long xfs_pflags_t;
81 *(NSTATEP) = *(OSTATEP); \ 81 *(NSTATEP) = *(OSTATEP); \
82} while (0) 82} while (0)
83 83
84static __inline unsigned int kmem_flags_convert(gfp_t flags) 84static __inline gfp_t kmem_flags_convert(unsigned int __nocast flags)
85{ 85{
86 unsigned int lflags = __GFP_NOWARN; /* we'll report problems, if need be */ 86 gfp_t lflags = __GFP_NOWARN; /* we'll report problems, if need be */
87 87
88#ifdef DEBUG 88#ifdef DEBUG
89 if (unlikely(flags & ~(KM_SLEEP|KM_NOSLEEP|KM_NOFS|KM_MAYFAIL))) { 89 if (unlikely(flags & ~(KM_SLEEP|KM_NOSLEEP|KM_NOFS|KM_MAYFAIL))) {
@@ -125,16 +125,16 @@ kmem_zone_destroy(kmem_zone_t *zone)
125 BUG(); 125 BUG();
126} 126}
127 127
128extern void *kmem_zone_zalloc(kmem_zone_t *, gfp_t); 128extern void *kmem_zone_zalloc(kmem_zone_t *, unsigned int __nocast);
129extern void *kmem_zone_alloc(kmem_zone_t *, gfp_t); 129extern void *kmem_zone_alloc(kmem_zone_t *, unsigned int __nocast);
130 130
131extern void *kmem_alloc(size_t, gfp_t); 131extern void *kmem_alloc(size_t, unsigned int __nocast);
132extern void *kmem_realloc(void *, size_t, size_t, gfp_t); 132extern void *kmem_realloc(void *, size_t, size_t, unsigned int __nocast);
133extern void *kmem_zalloc(size_t, gfp_t); 133extern void *kmem_zalloc(size_t, unsigned int __nocast);
134extern void kmem_free(void *, size_t); 134extern void kmem_free(void *, size_t);
135 135
136typedef struct shrinker *kmem_shaker_t; 136typedef struct shrinker *kmem_shaker_t;
137typedef int (*kmem_shake_func_t)(int, unsigned int); 137typedef int (*kmem_shake_func_t)(int, gfp_t);
138 138
139static __inline kmem_shaker_t 139static __inline kmem_shaker_t
140kmem_shake_register(kmem_shake_func_t sfunc) 140kmem_shake_register(kmem_shake_func_t sfunc)
@@ -149,7 +149,7 @@ kmem_shake_deregister(kmem_shaker_t shrinker)
149} 149}
150 150
151static __inline int 151static __inline int
152kmem_shake_allow(unsigned int gfp_mask) 152kmem_shake_allow(gfp_t gfp_mask)
153{ 153{
154 return (gfp_mask & __GFP_WAIT); 154 return (gfp_mask & __GFP_WAIT);
155} 155}