linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] clk: samsung: exynos990: Fix USB clock support
@ 2025-08-31 12:13 Denzeel Oliva
  2025-08-31 12:13 ` [PATCH v2 1/3] dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block Denzeel Oliva
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Denzeel Oliva @ 2025-08-31 12:13 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
	Alim Akhtar, Michael Turquette, Stephen Boyd, Rob Herring,
	Conor Dooley
  Cc: linux-samsung-soc, linux-clk, devicetree, linux-arm-kernel,
	linux-kernel, Denzeel Oliva

Hi,

Small fixes for Exynos990 HSI0 USB clocks:

Add missing LHS_ACEL clock ID and implementation, plus two missing
USB clock registers. Without these, USB connections fail with errors
like device descriptor read timeouts and address response issues.

These changes ensure proper USB operation by adding critical missing
clock definitions.

Denzeel Oliva

Changes in v2:
- Removed fixes tags and stable Cc

Signed-off-by: Denzeel Oliva <wachiturroxd150@gmail.com>
---
Denzeel Oliva (3):
      dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block
      clk: samsung: exynos990: Add LHS_ACEL gate clock for HSI0 and update CLK_NR_TOP
      clk: samsung: exynos990: Add missing USB clock registers to HSI0

 drivers/clk/samsung/clk-exynos990.c           | 8 +++++++-
 include/dt-bindings/clock/samsung,exynos990.h | 1 +
 2 files changed, 8 insertions(+), 1 deletion(-)
---
base-commit: e0edfc39b62e35dfb6d669b1189fa268147345ef
change-id: 20250830-usb-c8d352f5de9f

Best regards,
-- 
Denzeel Oliva <wachiturroxd150@gmail.com>


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH v2 1/3] dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block
  2025-08-31 12:13 [PATCH v2 0/3] clk: samsung: exynos990: Fix USB clock support Denzeel Oliva
@ 2025-08-31 12:13 ` Denzeel Oliva
  2025-09-01 21:33   ` Rob Herring (Arm)
  2025-08-31 12:13 ` [PATCH v2 2/3] clk: samsung: exynos990: Add LHS_ACEL gate clock for HSI0 and update CLK_NR_TOP Denzeel Oliva
  2025-08-31 12:13 ` [PATCH v2 3/3] clk: samsung: exynos990: Add missing USB clock registers to HSI0 Denzeel Oliva
  2 siblings, 1 reply; 5+ messages in thread
From: Denzeel Oliva @ 2025-08-31 12:13 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
	Alim Akhtar, Michael Turquette, Stephen Boyd, Rob Herring,
	Conor Dooley
  Cc: linux-samsung-soc, linux-clk, devicetree, linux-arm-kernel,
	linux-kernel, Denzeel Oliva

Add the missing LHS_ACEL clock ID for the HSI0 block. This clock is
required for proper USB operation, as without it, USB connections fail
with errors like device descriptor read timeouts and address response
issues.

Signed-off-by: Denzeel Oliva <wachiturroxd150@gmail.com>
---
 include/dt-bindings/clock/samsung,exynos990.h | 1 +
 1 file changed, 1 insertion(+)

diff --git a/include/dt-bindings/clock/samsung,exynos990.h b/include/dt-bindings/clock/samsung,exynos990.h
index c5c79e078f2f60fdb2c0f61ba6e7f3c6f2fbe9f2..c60f15503d5b18b11ca9bdce86466512dc933901 100644
--- a/include/dt-bindings/clock/samsung,exynos990.h
+++ b/include/dt-bindings/clock/samsung,exynos990.h
@@ -236,6 +236,7 @@
 #define CLK_GOUT_HSI0_VGEN_LITE_HSI0_CLK		20
 #define CLK_GOUT_HSI0_CMU_HSI0_PCLK			21
 #define CLK_GOUT_HSI0_XIU_D_HSI0_ACLK			22
+#define CLK_GOUT_HSI0_LHS_ACEL_D_HSI0_CLK		23
 
 /* CMU_PERIS */
 #define CLK_MOUT_PERIS_BUS_USER			1

-- 
2.50.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH v2 2/3] clk: samsung: exynos990: Add LHS_ACEL gate clock for HSI0 and update CLK_NR_TOP
  2025-08-31 12:13 [PATCH v2 0/3] clk: samsung: exynos990: Fix USB clock support Denzeel Oliva
  2025-08-31 12:13 ` [PATCH v2 1/3] dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block Denzeel Oliva
@ 2025-08-31 12:13 ` Denzeel Oliva
  2025-08-31 12:13 ` [PATCH v2 3/3] clk: samsung: exynos990: Add missing USB clock registers to HSI0 Denzeel Oliva
  2 siblings, 0 replies; 5+ messages in thread
From: Denzeel Oliva @ 2025-08-31 12:13 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
	Alim Akhtar, Michael Turquette, Stephen Boyd, Rob Herring,
	Conor Dooley
  Cc: linux-samsung-soc, linux-clk, devicetree, linux-arm-kernel,
	linux-kernel, Denzeel Oliva

Add the LHS_ACEL gate clock to the HSI0 clock controller. This clock is
critical for USB functionality and mark it as critical to keep it enabled.

Update CLK_NR_TOP to include the new clock.

Signed-off-by: Denzeel Oliva <wachiturroxd150@gmail.com>
---
 drivers/clk/samsung/clk-exynos990.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/clk/samsung/clk-exynos990.c b/drivers/clk/samsung/clk-exynos990.c
index 91736b15c4b4a0759419517f7b04dd0a8f38a289..7884354d612c54039289fa9b80ad08f34b9b7029 100644
--- a/drivers/clk/samsung/clk-exynos990.c
+++ b/drivers/clk/samsung/clk-exynos990.c
@@ -18,7 +18,7 @@
 
 /* NOTE: Must be equal to the last clock ID increased by one */
 #define CLKS_NR_TOP (CLK_DOUT_CMU_CLK_CMUREF + 1)
-#define CLKS_NR_HSI0 (CLK_GOUT_HSI0_XIU_D_HSI0_ACLK + 1)
+#define CLKS_NR_HSI0 (CLK_GOUT_HSI0_LHS_ACEL_D_HSI0_CLK + 1)
 #define CLKS_NR_PERIS (CLK_GOUT_PERIS_OTP_CON_TOP_OSCCLK + 1)
 
 /* ---- CMU_TOP ------------------------------------------------------------- */
@@ -1332,6 +1332,10 @@ static const struct samsung_gate_clock hsi0_gate_clks[] __initconst = {
 	     "gout_hsi0_xiu_d_hsi0_aclk", "mout_hsi0_bus_user",
 	     CLK_CON_GAT_GOUT_BLK_HSI0_UID_XIU_D_HSI0_IPCLKPORT_ACLK,
 	     21, CLK_IGNORE_UNUSED, 0),
+	GATE(CLK_GOUT_HSI0_LHS_ACEL_D_HSI0_CLK,
+	     "gout_hsi0_lhs_acel_d_hsi0_clk", "mout_hsi0_bus_user",
+	     CLK_CON_GAT_GOUT_BLK_HSI0_UID_LHS_ACEL_D_HSI0_IPCLKPORT_I_CLK,
+	     21, CLK_IS_CRITICAL, 0),
 };
 
 static const struct samsung_cmu_info hsi0_cmu_info __initconst = {

-- 
2.50.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH v2 3/3] clk: samsung: exynos990: Add missing USB clock registers to HSI0
  2025-08-31 12:13 [PATCH v2 0/3] clk: samsung: exynos990: Fix USB clock support Denzeel Oliva
  2025-08-31 12:13 ` [PATCH v2 1/3] dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block Denzeel Oliva
  2025-08-31 12:13 ` [PATCH v2 2/3] clk: samsung: exynos990: Add LHS_ACEL gate clock for HSI0 and update CLK_NR_TOP Denzeel Oliva
@ 2025-08-31 12:13 ` Denzeel Oliva
  2 siblings, 0 replies; 5+ messages in thread
From: Denzeel Oliva @ 2025-08-31 12:13 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Sylwester Nawrocki, Chanwoo Choi,
	Alim Akhtar, Michael Turquette, Stephen Boyd, Rob Herring,
	Conor Dooley
  Cc: linux-samsung-soc, linux-clk, devicetree, linux-arm-kernel,
	linux-kernel, Denzeel Oliva

These registers are required for proper USB operation and were omitted
in the initial clock controller setup.

Signed-off-by: Denzeel Oliva <wachiturroxd150@gmail.com>
---
 drivers/clk/samsung/clk-exynos990.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/clk/samsung/clk-exynos990.c b/drivers/clk/samsung/clk-exynos990.c
index 7884354d612c54039289fa9b80ad08f34b9b7029..47a1e0850c3020ab66931ae0c5ac4920f41496d0 100644
--- a/drivers/clk/samsung/clk-exynos990.c
+++ b/drivers/clk/samsung/clk-exynos990.c
@@ -1224,6 +1224,8 @@ static const unsigned long hsi0_clk_regs[] __initconst = {
 	CLK_CON_GAT_GOUT_BLK_HSI0_UID_SYSMMU_USB_IPCLKPORT_CLK_S2,
 	CLK_CON_GAT_GOUT_BLK_HSI0_UID_SYSREG_HSI0_IPCLKPORT_PCLK,
 	CLK_CON_GAT_GOUT_BLK_HSI0_UID_USB31DRD_IPCLKPORT_ACLK_PHYCTRL,
+	CLK_CON_GAT_GOUT_BLK_HSI0_UID_USB31DRD_IPCLKPORT_I_USB31DRD_REF_CLK_40,
+	CLK_CON_GAT_GOUT_BLK_HSI0_UID_USB31DRD_IPCLKPORT_I_USBDPPHY_REF_SOC_PLL,
 	CLK_CON_GAT_GOUT_BLK_HSI0_UID_USB31DRD_IPCLKPORT_I_USBDPPHY_SCL_APB_PCLK,
 	CLK_CON_GAT_GOUT_BLK_HSI0_UID_USB31DRD_IPCLKPORT_I_USBPCS_APB_CLK,
 	CLK_CON_GAT_GOUT_BLK_HSI0_UID_USB31DRD_IPCLKPORT_BUS_CLK_EARLY,

-- 
2.50.1


^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v2 1/3] dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block
  2025-08-31 12:13 ` [PATCH v2 1/3] dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block Denzeel Oliva
@ 2025-09-01 21:33   ` Rob Herring (Arm)
  0 siblings, 0 replies; 5+ messages in thread
From: Rob Herring (Arm) @ 2025-09-01 21:33 UTC (permalink / raw)
  To: Denzeel Oliva
  Cc: Michael Turquette, linux-kernel, Sylwester Nawrocki, Stephen Boyd,
	devicetree, Krzysztof Kozlowski, linux-samsung-soc, linux-clk,
	Alim Akhtar, linux-arm-kernel, Conor Dooley, Chanwoo Choi


On Sun, 31 Aug 2025 12:13:14 +0000, Denzeel Oliva wrote:
> Add the missing LHS_ACEL clock ID for the HSI0 block. This clock is
> required for proper USB operation, as without it, USB connections fail
> with errors like device descriptor read timeouts and address response
> issues.
> 
> Signed-off-by: Denzeel Oliva <wachiturroxd150@gmail.com>
> ---
>  include/dt-bindings/clock/samsung,exynos990.h | 1 +
>  1 file changed, 1 insertion(+)
> 

Acked-by: Rob Herring (Arm) <robh@kernel.org>


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2025-09-01 21:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-08-31 12:13 [PATCH v2 0/3] clk: samsung: exynos990: Fix USB clock support Denzeel Oliva
2025-08-31 12:13 ` [PATCH v2 1/3] dt-bindings: clock: exynos990: Add LHS_ACEL clock ID for HSI0 block Denzeel Oliva
2025-09-01 21:33   ` Rob Herring (Arm)
2025-08-31 12:13 ` [PATCH v2 2/3] clk: samsung: exynos990: Add LHS_ACEL gate clock for HSI0 and update CLK_NR_TOP Denzeel Oliva
2025-08-31 12:13 ` [PATCH v2 3/3] clk: samsung: exynos990: Add missing USB clock registers to HSI0 Denzeel Oliva

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).