[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACRpkdZ4T-8pW56KqxBwukviJ4Pn6PFtquwOOTUKAGbsJ9jsKw@mail.gmail.com>
Date: Tue, 8 Nov 2016 09:43:46 +0100
From: Linus Walleij <linus.walleij@...aro.org>
To: Andrey Smirnov <andrew.smirnov@...il.com>
Cc: "linux-gpio@...r.kernel.org" <linux-gpio@...r.kernel.org>,
Neil Armstrong <narmstrong@...libre.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Chris Healy <cphealy@...il.com>
Subject: Re: [PATCH v2 09/15] pinctrl-sx150x: Replace sx150x_*_cfg by means of
regmap API
On Mon, Nov 7, 2016 at 5:53 PM, Andrey Smirnov <andrew.smirnov@...il.com> wrote:
> The difference between 8 and 16 pin GPIO expanders can be accomodated by
> the means of regmap API without resorting to usaing driver-specific
> read/write accessors. This change, IMHO, brings the following benefits:
>
> - Replaces driver's idiosyncratic way of dealing with
> mult-register fields with regmap API, which, hopefuly,
> makes the code a bit easier for a new reader to understand
>
> - Removes various multi-read for-loop register read logic
> from various places in the code and puts it in a signle
> place
>
> - Removes ad-hoc IRQ register caching code in
> sx150x_irq_bus_sync_unlock, since that functionality is
> provided by regmap
>
> Besided aforementioned benefits this change also implements necessary
> RegSense byte swap necessary for SX1503 and SX1506 variants of the chip.
>
> Tested-by: Neil Armstrong <narmstrong@...libre.com>
> Acked-by: Neil Armstrong <narmstrong@...libre.com>
> Signed-off-by: Andrey Smirnov <andrew.smirnov@...il.com>
Patch applied!
Yours,
Linus Walleij
Powered by blists - more mailing lists