pinctrl: xway: fix gpio-hog related boot issues
authorMartin Schiller <ms@dev.tdt.de>
Fri, 14 Dec 2018 07:48:25 +0000 (08:48 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Dec 2019 14:37:27 +0000 (15:37 +0100)
commitdb94533f587d7770f1fc6f8659795fbff50fa28a
tree2cbf44dcccc156230bff6ba7af93cfa1effccd78
parenta509ddd2fb1b2bdcbe4596651c68a6eac594ea04
pinctrl: xway: fix gpio-hog related boot issues

[ Upstream commit 9b4924da4711674e62d97d4f5360446cc78337af ]

This patch is based on commit a86caa9ba5d7 ("pinctrl: msm: fix gpio-hog
related boot issues").

It fixes the issue that the gpio ranges needs to be defined before
gpiochip_add().

Therefore, we also have to swap the order of registering the pinctrl
driver and registering the gpio chip.

You also have to add the "gpio-ranges" property to the pinctrl device
node to get it finally working.

Signed-off-by: Martin Schiller <ms@dev.tdt.de>
Acked-by: John Crispin <john@phrozen.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/pinctrl/pinctrl-xway.c