mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-06-01 19:54:10 +03:00
Add missing cred.h functions
Resolve compiler warning with kmem_free (unused len) Add stub for byteorder.h Add zlib shim for compress2 and uncompress functions git-svn-id: https://outreach.scidac.gov/svn/spl/trunk@29 7e1ea52c-4ff2-0310-8f11-9dd32ca42a1c
This commit is contained in:
+6
-2
@@ -58,7 +58,7 @@ extern unsigned int kmem_alloc_max;
|
||||
|
||||
#define kmem_free(ptr, size) \
|
||||
({ \
|
||||
BUG_ON(!ptr); \
|
||||
BUG_ON(!ptr || size < 0); \
|
||||
atomic_sub((size), &kmem_alloc_used); \
|
||||
memset(ptr, 0x5a, (size)); /* Poison */ \
|
||||
kfree(ptr); \
|
||||
@@ -70,7 +70,11 @@ extern unsigned int kmem_alloc_max;
|
||||
|
||||
#define kmem_alloc(size, flags) kmalloc(size, flags)
|
||||
#define kmem_zalloc(size, flags) kzalloc(size, flags)
|
||||
#define kmem_free(ptr, size) kfree(ptr)
|
||||
#define kmem_free(ptr, size) \
|
||||
({ \
|
||||
BUG_ON(!ptr || size < 0); \
|
||||
kfree(ptr); \
|
||||
})
|
||||
|
||||
#endif /* DEBUG_KMEM */
|
||||
|
||||
|
||||
Reference in New Issue
Block a user