diff options
author | Benjamin Herrenschmidt <benh@au1.ibm.com> | 2018-05-17 11:12:02 +0300 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2018-05-23 14:59:06 +0300 |
commit | ed5cab43f99d1629af0e34ff565aa14efe0a8ac9 (patch) | |
tree | 5b38657238a6b4209fa7eeefe60404f325807e15 /drivers/gpio/Kconfig | |
parent | af7949284910a1f0b7814625051b8acf99af74d2 (diff) | |
download | linux-ed5cab43f99d1629af0e34ff565aa14efe0a8ac9.tar.xz |
gpio: aspeed: Use a cache of output data registers
The current driver does a read/modify/write of the output
registers when changing a bit in __aspeed_gpio_set().
This is sub-optimal for a couple of reasons:
- If any of the neighbouring GPIOs (sharing the shared
register) isn't (yet) configured as an output, it will
read the current input value, and then apply it to the
output latch, which may not be what the user expects. There
should be no bug in practice as aspeed_gpio_dir_out() will
establish a new value but it's not great either.
- The GPIO block in the aspeed chip is clocked rather
slowly (typically 25Mhz). That extra MMIO read halves the maximum
speed at which we can toggle the GPIO.
This provides a significant performance improvement to the GPIO
based FSI master.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Reviewed-by: Christopher Bostic <cbostic@linux.vnet.ibm.com>
Reviewed-by: Andrew Jeffery <andrew@aj.id.au>
Tested-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/gpio/Kconfig')
0 files changed, 0 insertions, 0 deletions