Skip to content

Commit c0401dc

Browse files
committed
Merge tag 'v6.19-rockchip-drivers1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip into soc/drivers
Some additional sane defaults for the oldish rk3368 soc. * tag 'v6.19-rockchip-drivers1' of git://git.kernel.org/pub/scm/linux/kernel/git/mmind/linux-rockchip: soc: rockchip: grf: Add select correct PWM implementation on RK3368 soc: rockchip: grf: Set pwm2/xin32k pad default to xin32k for rk3368 Signed-off-by: Arnd Bergmann <arnd@arndb.de>
2 parents 3d497bf + 048213a commit c0401dc

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

  • drivers/soc/rockchip

drivers/soc/rockchip/grf.c

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -91,13 +91,25 @@ static const struct rockchip_grf_info rk3328_grf __initconst = {
9191

9292
static const struct rockchip_grf_value rk3368_defaults[] __initconst = {
9393
{ "jtag switching", RK3368_GRF_SOC_CON15, FIELD_PREP_WM16_CONST(BIT(13), 0) },
94+
{ "pwm select", RK3368_GRF_SOC_CON15, FIELD_PREP_WM16_CONST(BIT(12), 1) },
9495
};
9596

9697
static const struct rockchip_grf_info rk3368_grf __initconst = {
9798
.values = rk3368_defaults,
9899
.num_values = ARRAY_SIZE(rk3368_defaults),
99100
};
100101

102+
#define RK3368_PMUGRF_SOC_CON0 0x100
103+
104+
static const struct rockchip_grf_value rk3368_pmugrf_defaults[] __initconst = {
105+
{ "pwm2 select", RK3368_PMUGRF_SOC_CON0, FIELD_PREP_WM16_CONST(BIT(7), 0) },
106+
};
107+
108+
static const struct rockchip_grf_info rk3368_pmugrf __initconst = {
109+
.values = rk3368_pmugrf_defaults,
110+
.num_values = ARRAY_SIZE(rk3368_pmugrf_defaults),
111+
};
112+
101113
#define RK3399_GRF_SOC_CON7 0xe21c
102114

103115
static const struct rockchip_grf_value rk3399_defaults[] __initconst = {
@@ -175,6 +187,9 @@ static const struct of_device_id rockchip_grf_dt_match[] __initconst = {
175187
}, {
176188
.compatible = "rockchip,rk3368-grf",
177189
.data = (void *)&rk3368_grf,
190+
}, {
191+
.compatible = "rockchip,rk3368-pmugrf",
192+
.data = (void *)&rk3368_pmugrf,
178193
}, {
179194
.compatible = "rockchip,rk3399-grf",
180195
.data = (void *)&rk3399_grf,

0 commit comments

Comments
 (0)