After change 3ff35cbcfa
"gpio-pch: Fix Kconfig dependencies"
which enabled COMPILE_TEST as an alternative for the PCH
driver, we get build failures like this:

drivers/gpio/gpio-pch.c: In function 'pch_gpio_probe':
drivers/gpio/gpio-pch.c:359:2: error: implicit declaration
of function 'kzalloc' [-Werror=implicit-function-declaration]
drivers/gpio/gpio-pch.c:359:7: warning: assignment makes
pointer from integer without a cast [enabled by default]
drivers/gpio/gpio-pch.c:442:2: error: implicit declaration
of function 'kfree' [-Werror=implicit-function-declaration]

Fix this by including <linux/slab.h> explicitly.

Cc: Jean Delvare <jdelvare@suse.de>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
This commit is contained in:
Linus Walleij 2014-05-27 15:15:21 +02:00
Родитель 51caa05a82
Коммит 349b6c5355
1 изменённых файлов: 1 добавлений и 0 удалений

Просмотреть файл

@ -20,6 +20,7 @@
#include <linux/gpio.h>
#include <linux/interrupt.h>
#include <linux/irq.h>
#include <linux/slab.h>
#define PCH_EDGE_FALLING 0
#define PCH_EDGE_RISING BIT(0)