[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180209165858.ebm7ed7f4b5uakju@latitude>
Date: Fri, 9 Feb 2018 17:58:58 +0100
From: Jonathan Neuschäfer <j.neuschaefer@....net>
To: Andy Shevchenko <andy.shevchenko@...il.com>
Cc: Jonathan Neuschäfer <j.neuschaefer@....net>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
Joel Stanley <joel@....id.au>,
"open list:LINUX FOR POWERPC PA SEMI PWRFICIENT"
<linuxppc-dev@...ts.ozlabs.org>,
"open list:GPIO SUBSYSTEM" <linux-gpio@...r.kernel.org>,
devicetree <devicetree@...r.kernel.org>,
Albert Herranz <albert_herranz@...oo.es>,
Segher Boessenkool <segher@...nel.crashing.org>,
Linus Walleij <linus.walleij@...aro.org>
Subject: Re: [PATCH v3 2/4] gpio: Add GPIO driver for Nintendo Wii
On Fri, Feb 09, 2018 at 05:30:55PM +0200, Andy Shevchenko wrote:
> On Fri, Feb 9, 2018 at 2:07 PM, Jonathan Neuschäfer
> <j.neuschaefer@....net> wrote:
> > The Nintendo Wii's chipset (called "Hollywood") has a GPIO controller
> > that supports a configurable number of pins (up to 32), interrupts, and
> > some special mechanisms to share the controller between the system's
> > security processor (an ARM926) and the PowerPC CPU. Pin multiplexing is
> > not supported.
> >
> > This patch adds a basic driver for this GPIO controller. Interrupt
> > support will come in a later patch.
> >
> > This patch is based on code developed by Albert Herranz and the GameCube
> > Linux Team, file arch/powerpc/platforms/embedded6xx/hlwd-gpio.c,
> > available at https://github.com/DeltaResero/GC-Wii-Linux-Kernels, but
> > has grown quite dissimilar.
> >
>
> Fine to me, though one comment below.
> In any case,
>
> Reviewed-by: Andy Shevchenko <andy.shevchenko@...il.com>
Thank you.
[...]
> > diff --git a/drivers/gpio/Kconfig b/drivers/gpio/Kconfig
> > index d6a8e851ad13..47606dfe06cc 100644
> > --- a/drivers/gpio/Kconfig
> > +++ b/drivers/gpio/Kconfig
> > @@ -229,6 +229,15 @@ config GPIO_GRGPIO
> > Select this to support Aeroflex Gaisler GRGPIO cores from the GRLIB
> > VHDL IP core library.
> >
> > +config GPIO_HLWD
> > + tristate "Nintendo Wii (Hollywood) GPIO"
>
> > + depends on OF_GPIO
>
> You may get rid of it if...
[ Even if this driver isn't switched to the unified device property API,
I think "depends on OF" would be enough here, because it doesn't use
the code that's guarded by CONFIG_OF_GPIO (gpiolib-of.c), but this
applies to other drivers (e.g. gpio-aspeed, gpio-bcm-kona) as well, so
this would ideally be a bigger cleanup patch. ]
> > + res = of_property_read_u32(pdev->dev.of_node, "ngpios", &ngpios);
>
> ...if you switch to unified device property API.
I don't think this change is worth making, unless/until the of_property
API is deprecated. I'm rather sure this GPIO controller won't appear in
an ACPI-based system.
Thanks,
Jonathan Neuschäfer
Download attachment "signature.asc" of type "application/pgp-signature" (820 bytes)
Powered by blists - more mailing lists