Decompressors: Include <linux/slab.h> in <linux/decompress/mm.h>
PATCH 1/1 Decompressors: Include <linux/slab.h> in <linux/decompress/mm.h>
From: Lasse Collin <[email protected]>
Currently users of mm.h need to include <linux/slab.h> to use the macros malloc() and free() provided by mm.h. This fixes it.
Signed-off-by Lasse Collin <[email protected]>
---
include/linux/decompress/mm.h | 1 + lib/decompress_bunzip2.c | 1 - lib/decompress_inflate.c | 1 - lib/decompress_unlzma.c | 1 - lib/decompress_unlzo.c | 1 - 5 files changed, 1 insertion(+), 4 deletions(-)
include/linux/decompress/mm.h +1 -0
@@ -72,6 +72,7 @@ static void free(void *where)#include <linux/kernel.h> #include <linux/fs.h> #include <linux/string.h> +#include <linux/slab.h> #include <linux/vmalloc.h> /* Use defines rather than static inline in order to avoid spurious
lib/decompress_bunzip2.c +0 -1
@@ -49,7 +49,6 @@#define PREBOOT #else #include <linux/decompress/bunzip2.h> -#include <linux/slab.h> #endif /* STATIC */ #include <linux/decompress/mm.h>
lib/decompress_inflate.c +0 -1
@@ -19,7 +19,6 @@#include "zlib_inflate/inflate.h" #include "zlib_inflate/infutil.h" -#include <linux/slab.h> #endif /* STATIC */
lib/decompress_unlzma.c +0 -1
@@ -33,7 +33,6 @@#define PREBOOT #else #include <linux/decompress/unlzma.h> -#include <linux/slab.h> #endif /* STATIC */ #include <linux/decompress/mm.h>
lib/decompress_unlzo.c +0 -1
@@ -33,7 +33,6 @@#ifdef STATIC #include "lzo/lzo1x_decompress.c" #else -#include <linux/slab.h> #include <linux/decompress/unlzo.h> #endif