Skip to contentSkip to conversation

arm: mvebu: Power up 2nd SATA port for Thecus N2350

PATCH RESEND In review Tony Dinh 2 participants 3 messages Feb 7, 2023 – Feb 13, 2023

lore
Share & tools
lore

Tony Dinh

author
#0 lore raw

PATCH RESEND v2 1/1 arm: mvebu: Power up 2nd SATA port for Thecus N2350

Currently, only the 1st SATA port is powered up (by GPIO1 12). Add GPIO1 13 in board initialization to power up the 2nd SATA port.

Note that this patch depends on the initial add-support patch:
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/

---

Changes in v2:
- Use BIT macros to make it easier to see which GPIOs are used.
- Resent to correct missing BIT(0) in N2350_GPP_OUT_VAL_MID

 board/thecus/n2350/n2350.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
board/thecus/n2350/n2350.c +2 -2
index 4cfdfba662..fd8f95f944 100644
@@ -24,8 +24,8 @@ DECLARE_GLOBAL_DATA_PTR;
 
 #define N2350_GPP_OUT_ENA_LOW	(~(BIT(20) | BIT(21) | BIT(24)))
 #define N2350_GPP_OUT_ENA_MID	(~(BIT(12) | BIT(13) | BIT(16) | BIT(19) | BIT(22)))
-#define N2350_GPP_OUT_VAL_LOW	0x1200000
-#define N2350_GPP_OUT_VAL_MID	0x1001
+#define N2350_GPP_OUT_VAL_LOW	(BIT(21) | BIT(24))
+#define N2350_GPP_OUT_VAL_MID	(BIT(0) | BIT(12) | BIT(13))
 #define N2350_GPP_POL_LOW	0x0
 #define N2350_GPP_POL_MID	0x0
 
Signature · 1 line
2.30.2
Reviewed-by on v2 1/1
#1 lore raw
Quoted 7 lines · Tony Dinh

Currently, only the 1st SATA port is powered up (by GPIO1 12). Add GPIO1 13 in board initialization to power up the 2nd SATA port.

Note that this patch depends on the initial add-support patch:
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/

Thanks,
Stefan

Quoted 14 lines

---

Changes in v2:
- Use BIT macros to make it easier to see which GPIOs are used.
- Resent to correct missing BIT(0) in N2350_GPP_OUT_VAL_MID

  board/thecus/n2350/n2350.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
board/thecus/n2350/n2350.c +0 -0
index 4cfdfba662..fd8f95f944 100644

board/thecus/n2350/n2350.c DECLARE_GLOBAL_DATA_PTR; · line 31

Quoted 10 lines
board/thecus/n2350/n2350.c +2 -2
@@ -24,8 +24,8 @@ DECLARE_GLOBAL_DATA_PTR;
 
  #define N2350_GPP_OUT_ENA_LOW	(~(BIT(20) | BIT(21) | BIT(24)))
  #define N2350_GPP_OUT_ENA_MID	(~(BIT(12) | BIT(13) | BIT(16) | BIT(19) | BIT(22)))
-#define N2350_GPP_OUT_VAL_LOW	0x1200000
-#define N2350_GPP_OUT_VAL_MID	0x1001
+#define N2350_GPP_OUT_VAL_LOW	(BIT(21) | BIT(24))
+#define N2350_GPP_OUT_VAL_MID	(BIT(0) | BIT(12) | BIT(13))
  #define N2350_GPP_POL_LOW	0x0
  #define N2350_GPP_POL_MID	0x0
 

Viele Grüße,
Stefan Roese

Signature · 3 lines
DENX Software Engineering GmbH,      Managing Director: Erika Unter
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: [email protected]
#2 lore raw
In reply to Tony Dinh
Quoted 7 lines · Tony Dinh

Currently, only the 1st SATA port is powered up (by GPIO1 12). Add GPIO1 13 in board initialization to power up the 2nd SATA port.

Note that this patch depends on the initial add-support patch:
https://patchwork.ozlabs.org/project/uboot/patch/[email protected]/

Applied to u-boot-marvell/master

Thanks,
Stefan

Quoted 14 lines

---

Changes in v2:
- Use BIT macros to make it easier to see which GPIOs are used.
- Resent to correct missing BIT(0) in N2350_GPP_OUT_VAL_MID

  board/thecus/n2350/n2350.c | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)
board/thecus/n2350/n2350.c +0 -0
index 4cfdfba662..fd8f95f944 100644

board/thecus/n2350/n2350.c DECLARE_GLOBAL_DATA_PTR; · line 31

Quoted 10 lines
board/thecus/n2350/n2350.c +2 -2
@@ -24,8 +24,8 @@ DECLARE_GLOBAL_DATA_PTR;
 
  #define N2350_GPP_OUT_ENA_LOW	(~(BIT(20) | BIT(21) | BIT(24)))
  #define N2350_GPP_OUT_ENA_MID	(~(BIT(12) | BIT(13) | BIT(16) | BIT(19) | BIT(22)))
-#define N2350_GPP_OUT_VAL_LOW	0x1200000
-#define N2350_GPP_OUT_VAL_MID	0x1001
+#define N2350_GPP_OUT_VAL_LOW	(BIT(21) | BIT(24))
+#define N2350_GPP_OUT_VAL_MID	(BIT(0) | BIT(12) | BIT(13))
  #define N2350_GPP_POL_LOW	0x0
  #define N2350_GPP_POL_MID	0x0
 

Viele Grüße,
Stefan Roese

Signature · 3 lines
DENX Software Engineering GmbH,      Managing Director: Erika Unter
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: [email protected]