X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs2.git;a=blobdiff_plain;f=patches%2Fyaffs_linux_allocator.c;h=395f4eac548953198785806e66c7dd8bf2045d5f;hp=82ae3dfdbe355cbe1253a4f70c3f9aabb1c7efb5;hb=2870702e0b0f4342857222a36ffcb21886c7f4bf;hpb=976dbeae825b18e6759f3903073a6784248cc244 diff --git a/patches/yaffs_linux_allocator.c b/patches/yaffs_linux_allocator.c index 82ae3df..395f4ea 100644 --- a/patches/yaffs_linux_allocator.c +++ b/patches/yaffs_linux_allocator.c @@ -67,7 +67,7 @@ void yaffs_deinit_raw_tnodes_and_objs(struct yaffs_dev *dev) YBUG(); } - YFREE(allocator); + kfree(allocator); } else { T(YAFFS_TRACE_ALWAYS, @@ -114,7 +114,7 @@ void yaffs_init_raw_tnodes_and_objs(struct yaffs_dev *dev) else if(mount_id >= 10){ T(YAFFS_TRACE_ALWAYS,(TSTR("Bad mount_id %u\n"),mount_id)); } else { - allocator = YMALLOC(sizeof(yaffs_Allocator)); + allocator = kmalloc(sizeof(yaffs_Allocator)); memset(allocator,0,sizeof(yaffs_Allocator)); dev->allocator = allocator; @@ -165,7 +165,7 @@ void yaffs_init_raw_tnodes_and_objs(struct yaffs_dev *dev) } -yaffs_tnode_t *yaffs_alloc_raw_tnode(struct yaffs_dev *dev) +struct yaffs_tnode *yaffs_alloc_raw_tnode(struct yaffs_dev *dev) { yaffs_Allocator *allocator = dev->allocator; if(!allocator || !allocator->tnode_cache){ @@ -175,7 +175,7 @@ yaffs_tnode_t *yaffs_alloc_raw_tnode(struct yaffs_dev *dev) return kmem_cache_alloc(allocator->tnode_cache, GFP_NOFS); } -void yaffs_free_raw_tnode(struct yaffs_dev *dev, yaffs_tnode_t *tn) +void yaffs_free_raw_tnode(struct yaffs_dev *dev, struct yaffs_tnode *tn) { yaffs_Allocator *allocator = dev->allocator; kmem_cache_free(allocator->tnode_cache,tn);