From: "Heiko Stübner" <heiko@sntech.de>
To: linus.walleij@linaro.org, Jianqun Xu <jay.xu@rock-chips.com>
Cc: linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-rockchip@lists.infradead.org,
Jianqun Xu <jay.xu@rock-chips.com>
Subject: Re: [PATCH 1/6] pinctrl: rockchip: make driver be tristate module
Date: Sun, 06 Sep 2020 00:23:09 +0200 [thread overview]
Message-ID: <2623687.OKfBHSCOjT@diego> (raw)
In-Reply-To: <2671833.MsR7uBhjTv@diego>
Am Sonntag, 6. September 2020, 00:01:55 CEST schrieb Heiko Stübner:
> Am Montag, 31. August 2020, 10:47:48 CEST schrieb Jianqun Xu:
> > Make pinctrl-rockchip driver to be tristate module, support to build as
> > a module, this is useful for GKI.
> >
> > Signed-off-by: Jianqun Xu <jay.xu@rock-chips.com>
>
> Reviewed-by: Heiko Stuebner <heiko@sntech.de>
I take this back.
What happens when you actually unload the module now?
I checked and all the pinctrl stuff itself is using devm-functions
so should be safe, but you're missing the
platform_driver_unregister part that should happen as well.
Heiko
> > ---
> > drivers/pinctrl/Kconfig | 2 +-
> > drivers/pinctrl/pinctrl-rockchip.c | 7 +++++++
> > 2 files changed, 8 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/pinctrl/Kconfig b/drivers/pinctrl/Kconfig
> > index 8828613c4e0e..dd4874e2ac67 100644
> > --- a/drivers/pinctrl/Kconfig
> > +++ b/drivers/pinctrl/Kconfig
> > @@ -207,7 +207,7 @@ config PINCTRL_OXNAS
> > select MFD_SYSCON
> >
> > config PINCTRL_ROCKCHIP
> > - bool
> > + tristate "Rockchip gpio and pinctrl driver"
> > select PINMUX
> > select GENERIC_PINCONF
> > select GENERIC_IRQ_CHIP
> > diff --git a/drivers/pinctrl/pinctrl-rockchip.c b/drivers/pinctrl/pinctrl-rockchip.c
> > index c07324d1f265..24dfc814dee1 100644
> > --- a/drivers/pinctrl/pinctrl-rockchip.c
> > +++ b/drivers/pinctrl/pinctrl-rockchip.c
> > @@ -16,10 +16,12 @@
> > */
> >
> > #include <linux/init.h>
> > +#include <linux/module.h>
> > #include <linux/platform_device.h>
> > #include <linux/io.h>
> > #include <linux/bitops.h>
> > #include <linux/gpio/driver.h>
> > +#include <linux/of_device.h>
> > #include <linux/of_address.h>
> > #include <linux/of_irq.h>
> > #include <linux/pinctrl/machine.h>
> > @@ -4256,3 +4258,8 @@ static int __init rockchip_pinctrl_drv_register(void)
> > return platform_driver_register(&rockchip_pinctrl_driver);
> > }
> > postcore_initcall(rockchip_pinctrl_drv_register);
> > +
> > +MODULE_DESCRIPTION("ROCKCHIP Pin Controller Driver");
> > +MODULE_LICENSE("GPL");
> > +MODULE_ALIAS("platform:pinctrl-rockchip");
> > +MODULE_DEVICE_TABLE(of, rockchip_pinctrl_dt_match);
> >
>
>
next prev parent reply other threads:[~2020-09-05 22:23 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-31 8:47 [PATCH 0/6] rockchip-pinctrl fixes for GKI Jianqun Xu
2020-08-31 8:47 ` [PATCH 1/6] pinctrl: rockchip: make driver be tristate module Jianqun Xu
2020-09-01 10:13 ` kernel test robot
2020-09-05 21:51 ` Heiko Stübner
2020-09-05 22:01 ` Heiko Stübner
2020-09-05 22:23 ` Heiko Stübner [this message]
2020-08-31 8:47 ` [PATCH 2/6] pinctrl: rockchip: enable gpio pclk for rockchip_gpio_to_irq Jianqun Xu
2020-09-05 21:54 ` Heiko Stübner
2020-08-31 8:47 ` [PATCH 3/6] pinctrl: rockchip: create irq mapping in gpio_to_irq Jianqun Xu
2020-09-05 22:03 ` Heiko Stübner
2020-08-31 8:47 ` [PATCH 4/6] pinctrl: rockchip: do not set gpio if bank invalid Jianqun Xu
2020-09-05 22:09 ` Heiko Stübner
2020-08-31 8:50 ` [PATCH 5/6] pinctrl: rockchip: fix crash caused by invalid gpio bank Jianqun Xu
2020-09-05 22:14 ` Heiko Stübner
2020-08-31 8:50 ` [PATCH 6/6] pinctrl: rockchip: populate platform device for rockchip gpio Jianqun Xu
2020-09-06 10:20 ` Heiko Stübner
2020-09-07 2:59 ` [PATCH v2 0/5] rockchip-pinctrl fixes for GKI Jianqun Xu
2020-09-07 2:59 ` [PATCH 1/5] pinctrl: rockchip: depend on OF Jianqun Xu
2020-09-07 2:59 ` [PATCH 2/5] pinctrl: rockchip: make driver be tristate module Jianqun Xu
2020-09-07 11:35 ` kernel test robot
2020-09-12 11:41 ` Heiko Stübner
2020-09-14 0:38 ` [PATCH 2/2] " Jianqun Xu
2020-09-20 22:14 ` Heiko Stübner
2020-09-20 22:18 ` Heiko Stübner
2020-09-29 13:21 ` Linus Walleij
2020-10-13 6:40 ` jay.xu
2020-09-07 2:59 ` [PATCH 3/5] pinctrl: rockchip: enable gpio pclk for rockchip_gpio_to_irq Jianqun Xu
2020-09-07 2:59 ` [PATCH 4/5] pinctrl: rockchip: create irq mapping in gpio_to_irq Jianqun Xu
2020-09-07 3:38 ` [PATCH 5/5] pinctrl: rockchip: populate platform device for rockchip gpio Jianqun Xu
2020-09-08 2:19 ` [PATCH] " Jianqun Xu
2020-09-20 22:16 ` Heiko Stübner
2020-09-12 11:35 ` [PATCH v2 0/5] rockchip-pinctrl fixes for GKI Linus Walleij
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2623687.OKfBHSCOjT@diego \
--to=heiko@sntech.de \
--cc=jay.xu@rock-chips.com \
--cc=linus.walleij@linaro.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).