[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAMRc=MfaEfaZ7yYrFtc+XChzPX1C1AV1xAZPRZyJKA+z7D6-vw@mail.gmail.com>
Date: Thu, 20 Jul 2023 17:12:36 +0200
From: Bartosz Golaszewski <brgl@...ev.pl>
To: nick.hawkins@....com
Cc: verdun@....com, linus.walleij@...aro.org, robh+dt@...nel.org,
krzysztof.kozlowski+dt@...aro.org, jdelvare@...e.com,
linux@...ck-us.net, andy.shevchenko@...il.com,
linux-gpio@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-hwmon@...r.kernel.org
Subject: Re: [PATCH v5 2/5] gpio: gxp: Add HPE GXP GPIO PL
On Wed, Jul 5, 2023 at 9:49 PM <nick.hawkins@....com> wrote:
>
> From: Nick Hawkins <nick.hawkins@....com>
>
> The GXP SoC supports GPIO on multiple interfaces. The interfaces are
> CPLD and Host. The gpio-gxp-pl driver covers the CPLD which takes
> physical I/O from the board and shares it with GXP via a proprietary
> interface that maps the I/O onto a specific register area of the GXP.
> This driver supports interrupts from the CPLD.
>
> Signed-off-by: Nick Hawkins <nick.hawkins@....com>
>
[snip]
> +
> +/*
> + * When an interrupt fires for a PSU config change
> + * there is a need to know the previous PSU configuration
> + * so that the appropriate gpio line is interrupted for
> + * the correct PSU. In order to keep this variable up to
> + * date it is global so that it can be set at init and
> + * each time the interrupt fires.
> + */
> +u8 psu_presence;
I'm not buying it. There's no user of this variable outside of this
compilation unit, is there? If there was - the name should have some
prefix but even then, I don't see a need for this to be global. Why
don't you put it in struct gxp_gpio_drvdata?
Bart
[snip]
Powered by blists - more mailing lists