Browse Source

reset:starfive:jh7110: Delete redundant logic

In the hardware design, the IPs RESET signal of jh7110 is divided into
two groups,one group is active high, and the other group is active low.

However, the software does not need to distinguish whether the RESET
signal is active high or active low,Write 1 to be assert, and write 0 to deassert.

Therefore, the software does not need to add additional logic to
distinguish these two sets of signals.

Signed-off-by: yanhong.wang <yanhong.wang@starfivetech.com>
yanhong.wang 1 year ago
parent
commit
b8c8323ddd
1 changed files with 1 additions and 28 deletions
  1. 1 28
      drivers/reset/reset-jh7110.c

+ 1 - 28
drivers/reset/reset-jh7110.c

@@ -58,31 +58,6 @@ struct jh7110_reset_priv {
 	void __iomem *voutcrg;
 };
 
-static const u32 jh7110_reset_asserted[8] = {
-	/* SYSCRG_STATUS0 */
-	BIT(RSTN_U0_U7MC_RST_BUS % 32) |
-	BIT(RSTN_U0_U7MC_CORE0 % 32) |
-	BIT(RSTN_U0_U7MC_CORE1 % 32) |
-	BIT(RSTN_U0_U7MC_CORE2 % 32) |
-	BIT(RSTN_U0_U7MC_CORE3 % 32) |
-	BIT(RSTN_U0_U7MC_CORE4 % 32),
-	/* SYSCRG_STATUS1 */
-	0,
-	/* SYSCRG_STATUS2 */
-	0,
-	/* SYSCRG_STATUS3 */
-	0,
-	/* STGCRG */
-	BIT(RSTN_U0_HIFI4_CORE % 32) |
-	BIT(RSTN_U0_E24_CORE % 32),
-	/* AONCRG */
-	0,
-	/* ISPCRG */
-	0,
-	/*VOUTCRG*/
-	0,
-};
-
 static int jh7110_get_reset(struct jh7110_reset_priv *priv,
 			struct reset_assert_t *reset,
 			unsigned long group)
@@ -133,7 +108,7 @@ static int jh7110_reset_trigger(struct jh7110_reset_priv *priv,
 {
 	struct reset_assert_t reset;
 	unsigned long group;
-	u32 mask, value, done;
+	u32 mask, value, done = 0;
 	int ret;
 	u32 loop;
 
@@ -145,8 +120,6 @@ static int jh7110_reset_trigger(struct jh7110_reset_priv *priv,
 		return ret;
 	}
 
-	done = jh7110_reset_asserted[group] & mask;
-
 	if (!assert)
 		done ^= mask;