Re: [PATCH/RFC v2 1/2] gpio: rcar: Optimize GPIO pin state read on R-Car Gen3

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 30, 2020 at 09:15:21AM +0100, Geert Uytterhoeven wrote:
> Currently, the R-Car GPIO driver treats R-Car Gen2 and R-Car Gen3 GPIO
> controllers the same.  However, there exist small differences, like the
> behavior of the General Input Register (INDT):
>   - On R-Car Gen1, R-Car Gen2, and RZ/G1, INDT only reflects the state
>     of an input pin if the GPIO is configured for input,
>   - On R-Car Gen3 and RZ/G2, INDT always reflects the state of the input
>     pins.
> Hence to accommodate all variants, the driver does not use the INDT
> register to read the status of a GPIO line when configured for output,
> at the expense of doing 2 or 3 register reads instead of 1.
> 
> Given register accesses are slow, change the .get() and .get_multiple()
> callbacks to always use INDT to read pin state on SoCs where this is
> supported.
> 
> Signed-off-by: Geert Uytterhoeven <geert+renesas@xxxxxxxxx>
> Reviewed-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@xxxxxxxxxxx>

Tested-by: Wolfram Sang <wsa+renesas@xxxxxxxxxxxxxxxxxxxx>

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Samsung SOC]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux