Skip to content

Commit

Permalink
regulator: using kfree() requires including slab.h
Browse files Browse the repository at this point in the history
Fixes this build error:

drivers/regulator/twl-regulator.c: In function 'twlreg_probe':
drivers/regulator/twl-regulator.c:1229:3: error: implicit declaration of function 'kfree' [-Werror=implicit-function-declaration]

Also added string.h for kmemdup().

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
  • Loading branch information
Stephen Rothwell authored and Mark Brown committed Aug 28, 2012
1 parent ffee190 commit 8f52a58
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/regulator/twl-regulator.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
*/

#include <linux/module.h>
#include <linux/string.h>
#include <linux/slab.h>
#include <linux/init.h>
#include <linux/err.h>
#include <linux/platform_device.h>
Expand Down

0 comments on commit 8f52a58

Please sign in to comment.