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:34:30 +0000 (15:34 +0100)
commit33e1ad60beb1fc35bda053725d625c104d844f54
tree74975a1685fac87c9f2aad89fdfd2bb3b6457c43
parentdb9bab54b5ab16bc36516e9f7c5ec3a4fee863ed
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