pinctrl: add includes and ifdefs for non-DT builds
authorLinus Walleij <linus.walleij@linaro.org>
Thu, 15 Aug 2013 19:38:49 +0000 (21:38 +0200)
committerDan Willemsen <dwillemsen@nvidia.com>
Sat, 14 Sep 2013 20:44:27 +0000 (13:44 -0700)
commit62759b1905ff16f79b9e13fbf70e49ffd8445197
tree8dc68cf0f63302a6b1330010e70219191b54a43a
parent018b0aec4501f8ba4683529e09645d130e023fdc
pinctrl: add includes and ifdefs for non-DT builds

Commit e81c8f18afc4fdd6e34d8c83814b8b5134dbb30f
"pinctrl: pinconf-generic: add generic APIs for mapping pinctrl node"
Added function prototypes with implicit dependencies
on other header files causing build warnings like this:

In file included from
arch/arm/mach-ux500/board-mop500-pins.c:12:0:
include/linux/pinctrl/pinconf-generic.h:142:3:
warning: 'struct device_node' declared inside parameter list [enabled
by default]
   unsigned *reserved_maps, unsigned *num_maps);
   ^
include/linux/pinctrl/pinconf-generic.h:142:3:
warning: its scope is only this definition or declaration, which is
probably not what you want [enabled by default]
include/linux/pinctrl/pinconf-generic.h:142:3:
warning: 'struct pinctrl_dev' declared inside parameter list [enabled
by default]
include/linux/pinctrl/pinconf-generic.h:145:3:
warning: 'struct device_node' declared inside parameter list [enabled
by default]
   unsigned *num_maps);
   ^
Let's just add ifdefs for non-DT systems (the actual code is
already ifdefed) and #include <linux/device.h> to get the
most important structs and forward-declare the pinctrl
core structs.

Reported-by: Olof Johansson <olof@lixom.net>
Cc: Laxman Dewangan <ldewangan@nvidia.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
(cherry picked from commit 0d74d4a161c9f9870039af414b712552c0ed6dfb)
Change-Id: I8f0b93068af033d4255c3f34b497a7d6974d4793
Reviewed-on: http://git-master/r/267843
GVS: Gerrit_Virtual_Submit
Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
Tested-by: Laxman Dewangan <ldewangan@nvidia.com>
include/linux/pinctrl/pinconf-generic.h