Skip to content

Commit

Permalink
pinctrl: rockchip: use dedicated pinctrl type for RK3328
Browse files Browse the repository at this point in the history
[ Upstream commit 01b4b1d ]

rk3328_pin_ctrl uses type of RK3288 which has a hack in
rockchip_pinctrl_suspend and rockchip_pinctrl_resume to restore GPIO6-C6
at assume, the hack is not applicable to RK3328 as GPIO6 is not even
exist in it. So use a dedicated pinctrl type to skip this hack.

Fixes: 3818e4a ("pinctrl: rockchip: Add rk3328 pinctrl support")
Reviewed-by: Heiko Stuebner <heiko@sntech.de>
Signed-off-by: Huang-Huang Bao <i@eh5.me>
Link: https://lore.kernel.org/r/20240606125755.53778-4-i@eh5.me
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
EHfive authored and gregkh committed Jul 5, 2024
1 parent 926cb58 commit 6531f8c
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
5 changes: 4 additions & 1 deletion drivers/pinctrl/pinctrl-rockchip.c
Original file line number Diff line number Diff line change
Expand Up @@ -1864,6 +1864,7 @@ static int rockchip_get_pull(struct rockchip_pin_bank *bank, int pin_num)
case RK3188:
case RK3288:
case RK3308:
case RK3328:
case RK3368:
case RK3399:
case RK3568:
Expand Down Expand Up @@ -1918,6 +1919,7 @@ static int rockchip_set_pull(struct rockchip_pin_bank *bank,
case RK3188:
case RK3288:
case RK3308:
case RK3328:
case RK3368:
case RK3399:
case RK3568:
Expand Down Expand Up @@ -2239,6 +2241,7 @@ static bool rockchip_pinconf_pull_valid(struct rockchip_pin_ctrl *ctrl,
case RK3188:
case RK3288:
case RK3308:
case RK3328:
case RK3368:
case RK3399:
case RK3568:
Expand Down Expand Up @@ -3717,7 +3720,7 @@ static struct rockchip_pin_ctrl rk3328_pin_ctrl = {
.pin_banks = rk3328_pin_banks,
.nr_banks = ARRAY_SIZE(rk3328_pin_banks),
.label = "RK3328-GPIO",
.type = RK3288,
.type = RK3328,
.grf_mux_offset = 0x0,
.iomux_recalced = rk3328_mux_recalced_data,
.niomux_recalced = ARRAY_SIZE(rk3328_mux_recalced_data),
Expand Down
1 change: 1 addition & 0 deletions drivers/pinctrl/pinctrl-rockchip.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ enum rockchip_pinctrl_type {
RK3188,
RK3288,
RK3308,
RK3328,
RK3368,
RK3399,
RK3568,
Expand Down

0 comments on commit 6531f8c

Please sign in to comment.