]> git.baikalelectronics.ru Git - kernel.git/commit
pinctrl: meson: fix G12A ao pull registers base address
authorXingyu Chen <xingyu.chen@amlogic.com>
Thu, 17 Jan 2019 10:23:14 +0000 (11:23 +0100)
committerLinus Walleij <linus.walleij@linaro.org>
Mon, 21 Jan 2019 13:49:57 +0000 (14:49 +0100)
commit7900cf7c8ce8795962fdcfcbd991b36af81a0949
tree5c98d836f9bca33454e8b3f3f1dd5a17bf3af291
parenta0713c0a5172515d65020f3195e0678132664664
pinctrl: meson: fix G12A ao pull registers base address

Since Meson G12A SoC, Introduce new ao registers AO_RTI_PULL_UP_EN_REG
and AO_GPIO_O.

These bits of controlling output level are remapped to the new register
AO_GPIO_O, and the AO_GPIO_O_EN_N support only controlling output enable.

These bits of controlling pull enable are remapped to the new register
AO_RTI_PULL_UP_EN_REG, and the AO_RTI_PULL_UP_REG support only controlling
pull type(up/down).

The new layout of ao gpio/pull registers is as follows:
- AO_GPIO_O_EN_N        [offset: 0x9 << 2]
- AO_GPIO_I             [offset: 0xa << 2]
- AO_RTI_PULL_UP_REG    [offset: 0xb << 2]
- AO_RTI_PULL_UP_EN_REG [offset: 0xc << 2]
- AO_GPIO_O             [offset: 0xd << 2]

From above, we can see ao GPIO registers region has been separated by the
ao pull registers. In order to ensure the continuity of the region on
software, the ao GPIO and ao pull registers use the same base address, but
can be identified by the offset.

Fixes: 29584e8b80fc ("pinctrl: meson-g12a: add pinctrl driver support")
Signed-off-by: Xingyu Chen <xingyu.chen@amlogic.com>
Signed-off-by: Jianxin Pan <jianxin.pan@amlogic.com>
Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/meson/pinctrl-meson.c