File tree Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Expand file tree Collapse file tree 1 file changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -2176,8 +2176,12 @@ void btrfs_destroy_inode(struct inode *inode)
2176
2176
kmem_cache_free (btrfs_inode_cachep , BTRFS_I (inode ));
2177
2177
}
2178
2178
2179
+ #if LINUX_VERSION_CODE > KERNEL_VERSION (2 ,6 ,23 )
2180
+ static void init_once (struct kmem_cache * cachep , void * foo )
2181
+ #else
2179
2182
static void init_once (void * foo , struct kmem_cache * cachep ,
2180
2183
unsigned long flags )
2184
+ #endif
2181
2185
{
2182
2186
struct btrfs_inode * ei = (struct btrfs_inode * ) foo ;
2183
2187
@@ -2200,8 +2204,13 @@ void btrfs_destroy_cachep(void)
2200
2204
2201
2205
struct kmem_cache * btrfs_cache_create (const char * name , size_t size ,
2202
2206
unsigned long extra_flags ,
2207
+ #if LINUX_VERSION_CODE > KERNEL_VERSION (2 ,6 ,23 )
2208
+ void (* ctor )(struct kmem_cache * , void * )
2209
+ #else
2203
2210
void (* ctor )(void * , struct kmem_cache * ,
2204
- unsigned long ))
2211
+ unsigned long )
2212
+ #endif
2213
+ )
2205
2214
{
2206
2215
return kmem_cache_create (name , size , 0 , (SLAB_RECLAIM_ACCOUNT |
2207
2216
SLAB_MEM_SPREAD | extra_flags ), ctor
You can’t perform that action at this time.
0 commit comments