File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change 40
40
#define RK3588_BIFURCATION_LANE_0_1 BIT(0)
41
41
#define RK3588_BIFURCATION_LANE_2_3 BIT(1)
42
42
#define RK3588_LANE_AGGREGATION BIT(2)
43
+ #define RK3588_PCIE1LN_SEL_EN (GENMASK(1, 0) << 16)
44
+ #define RK3588_PCIE30_PHY_MODE_EN (GENMASK(2, 0) << 16)
43
45
44
46
struct rockchip_p3phy_ops ;
45
47
@@ -149,14 +151,15 @@ static int rockchip_p3phy_rk3588_init(struct rockchip_p3phy_priv *priv)
149
151
}
150
152
151
153
reg = mode ;
152
- regmap_write (priv -> phy_grf , RK3588_PCIE3PHY_GRF_CMN_CON0 , (0x7 <<16 ) | reg );
154
+ regmap_write (priv -> phy_grf , RK3588_PCIE3PHY_GRF_CMN_CON0 ,
155
+ RK3588_PCIE30_PHY_MODE_EN | reg );
153
156
154
157
/* Set pcie1ln_sel in PHP_GRF_PCIESEL_CON */
155
158
if (!IS_ERR (priv -> pipe_grf )) {
156
- reg = mode & 3 ;
159
+ reg = mode & ( RK3588_BIFURCATION_LANE_0_1 | RK3588_BIFURCATION_LANE_2_3 ) ;
157
160
if (reg )
158
161
regmap_write (priv -> pipe_grf , PHP_GRF_PCIESEL_CON ,
159
- ( reg << 16 ) | reg );
162
+ RK3588_PCIE1LN_SEL_EN | reg );
160
163
}
161
164
162
165
reset_control_deassert (priv -> p30phy );
You can’t perform that action at this time.
0 commit comments