LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes
@ 2015-03-16 10:40 Peter Ujfalusi
  2015-03-16 10:40 ` [PATCH 1/2] clk: ti: clk-3xxx: Correct McBSP related DT clock definitions Peter Ujfalusi
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Peter Ujfalusi @ 2015-03-16 10:40 UTC (permalink / raw)
  To: t-kristo, mturquette, sboyd; +Cc: tony, linux-omap, linux-kernel

Hi,

This series will fix the following error during boot (both DT and legacy boot):
[    0.307739] omap_hwmod: mcbsp2: _wait_target_ready failed: -16
[    0.307769] omap_hwmod: mcbsp2: cannot be enabled for reset (3)

The clock definitions/aliases for McBSP ports were not correct.

In case of DT boot we still have the following warning printed from hwmod:
[    0.222900] omap_hwmod: mcbsp2_sidetone using broken dt data from mcbsp
[    0.225311] omap_hwmod: mcbsp3_sidetone using broken dt data from mcbsp

These are there because mcbsp is using two hwmods in the DT and hwmod prints
out a warning for these. In legacy mode we also have 2 hwmods for McBSP2/3.
One for the McBSP itself and the other for the sidetone block attached to them.
I'll try to look into this one next.

Since this series fixes the _wait_target_ready issue, can this be sent for 4.0?

Regards,
Peter
---
Peter Ujfalusi (2):
  clk: ti: clk-3xxx: Correct McBSP related DT clock definitions
  clk: ti: clk-3xxx-legacy: Correct McBSP related clock aliases

 drivers/clk/ti/clk-3xxx-legacy.c | 16 +++++++++-------
 drivers/clk/ti/clk-3xxx.c        | 19 +++++++------------
 2 files changed, 16 insertions(+), 19 deletions(-)

-- 
2.3.0


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

* [PATCH 1/2] clk: ti: clk-3xxx: Correct McBSP related DT clock definitions
  2015-03-16 10:40 [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes Peter Ujfalusi
@ 2015-03-16 10:40 ` Peter Ujfalusi
  2015-03-16 10:40 ` [PATCH 2/2] clk: ti: clk-3xxx-legacy: Correct McBSP related clock aliases Peter Ujfalusi
  2015-03-24 18:50 ` [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes Tero Kristo
  2 siblings, 0 replies; 4+ messages in thread
From: Peter Ujfalusi @ 2015-03-16 10:40 UTC (permalink / raw)
  To: t-kristo, mturquette, sboyd; +Cc: tony, linux-omap, linux-kernel

In DT boot we do not have devices named as omap-mcbsp.X.
Correct the McBSP2/4 ick mapping (they were 2->4 and 4->2).
Collect the McBSP clock definition in one location at the same time.

Fixes the following warning on boot:
[    0.307739] omap_hwmod: mcbsp2: _wait_target_ready failed: -16
[    0.307769] omap_hwmod: mcbsp2: cannot be enabled for reset (3)

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
---
 drivers/clk/ti/clk-3xxx.c | 19 +++++++------------
 1 file changed, 7 insertions(+), 12 deletions(-)

diff --git a/drivers/clk/ti/clk-3xxx.c b/drivers/clk/ti/clk-3xxx.c
index 383a06e49b09..757636d166cf 100644
--- a/drivers/clk/ti/clk-3xxx.c
+++ b/drivers/clk/ti/clk-3xxx.c
@@ -34,7 +34,6 @@ static struct ti_dt_clk omap3xxx_clks[] = {
 	DT_CLK(NULL, "omap_96m_alwon_fck", "omap_96m_alwon_fck"),
 	DT_CLK("etb", "emu_core_alwon_ck", "emu_core_alwon_ck"),
 	DT_CLK(NULL, "sys_altclk", "sys_altclk"),
-	DT_CLK(NULL, "mcbsp_clks", "mcbsp_clks"),
 	DT_CLK(NULL, "sys_clkout1", "sys_clkout1"),
 	DT_CLK(NULL, "dpll1_ck", "dpll1_ck"),
 	DT_CLK(NULL, "dpll1_x2_ck", "dpll1_x2_ck"),
@@ -82,8 +81,6 @@ static struct ti_dt_clk omap3xxx_clks[] = {
 	DT_CLK(NULL, "i2c3_fck", "i2c3_fck"),
 	DT_CLK(NULL, "i2c2_fck", "i2c2_fck"),
 	DT_CLK(NULL, "i2c1_fck", "i2c1_fck"),
-	DT_CLK(NULL, "mcbsp5_fck", "mcbsp5_fck"),
-	DT_CLK(NULL, "mcbsp1_fck", "mcbsp1_fck"),
 	DT_CLK(NULL, "core_48m_fck", "core_48m_fck"),
 	DT_CLK(NULL, "mcspi4_fck", "mcspi4_fck"),
 	DT_CLK(NULL, "mcspi3_fck", "mcspi3_fck"),
@@ -122,10 +119,6 @@ static struct ti_dt_clk omap3xxx_clks[] = {
 	DT_CLK(NULL, "uart1_ick", "uart1_ick"),
 	DT_CLK(NULL, "gpt11_ick", "gpt11_ick"),
 	DT_CLK(NULL, "gpt10_ick", "gpt10_ick"),
-	DT_CLK("omap-mcbsp.5", "ick", "mcbsp5_ick"),
-	DT_CLK("omap-mcbsp.1", "ick", "mcbsp1_ick"),
-	DT_CLK(NULL, "mcbsp5_ick", "mcbsp5_ick"),
-	DT_CLK(NULL, "mcbsp1_ick", "mcbsp1_ick"),
 	DT_CLK(NULL, "omapctrl_ick", "omapctrl_ick"),
 	DT_CLK(NULL, "dss_tv_fck", "dss_tv_fck"),
 	DT_CLK(NULL, "dss_96m_fck", "dss_96m_fck"),
@@ -179,15 +172,17 @@ static struct ti_dt_clk omap3xxx_clks[] = {
 	DT_CLK(NULL, "gpt4_ick", "gpt4_ick"),
 	DT_CLK(NULL, "gpt3_ick", "gpt3_ick"),
 	DT_CLK(NULL, "gpt2_ick", "gpt2_ick"),
-	DT_CLK("omap-mcbsp.2", "ick", "mcbsp2_ick"),
-	DT_CLK("omap-mcbsp.3", "ick", "mcbsp3_ick"),
-	DT_CLK("omap-mcbsp.4", "ick", "mcbsp4_ick"),
-	DT_CLK(NULL, "mcbsp4_ick", "mcbsp2_ick"),
+	DT_CLK(NULL, "mcbsp_clks", "mcbsp_clks"),
+	DT_CLK(NULL, "mcbsp1_ick", "mcbsp1_ick"),
+	DT_CLK(NULL, "mcbsp2_ick", "mcbsp2_ick"),
 	DT_CLK(NULL, "mcbsp3_ick", "mcbsp3_ick"),
-	DT_CLK(NULL, "mcbsp2_ick", "mcbsp4_ick"),
+	DT_CLK(NULL, "mcbsp4_ick", "mcbsp4_ick"),
+	DT_CLK(NULL, "mcbsp5_ick", "mcbsp5_ick"),
+	DT_CLK(NULL, "mcbsp1_fck", "mcbsp1_fck"),
 	DT_CLK(NULL, "mcbsp2_fck", "mcbsp2_fck"),
 	DT_CLK(NULL, "mcbsp3_fck", "mcbsp3_fck"),
 	DT_CLK(NULL, "mcbsp4_fck", "mcbsp4_fck"),
+	DT_CLK(NULL, "mcbsp5_fck", "mcbsp5_fck"),
 	DT_CLK("etb", "emu_src_ck", "emu_src_ck"),
 	DT_CLK(NULL, "emu_src_ck", "emu_src_ck"),
 	DT_CLK(NULL, "pclk_fck", "pclk_fck"),
-- 
2.3.0


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

* [PATCH 2/2] clk: ti: clk-3xxx-legacy: Correct McBSP related clock aliases
  2015-03-16 10:40 [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes Peter Ujfalusi
  2015-03-16 10:40 ` [PATCH 1/2] clk: ti: clk-3xxx: Correct McBSP related DT clock definitions Peter Ujfalusi
@ 2015-03-16 10:40 ` Peter Ujfalusi
  2015-03-24 18:50 ` [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes Tero Kristo
  2 siblings, 0 replies; 4+ messages in thread
From: Peter Ujfalusi @ 2015-03-16 10:40 UTC (permalink / raw)
  To: t-kristo, mturquette, sboyd; +Cc: tony, linux-omap, linux-kernel

Correct the McBSP2/4 ick mapping (they were 2->4 and 4->2).
Add missing mcbsp clock aliases.
Collect the McBSP clock definition in one location at the same time.

Fixes the following warning on boot:
[    0.307739] omap_hwmod: mcbsp2: _wait_target_ready failed: -16
[    0.307769] omap_hwmod: mcbsp2: cannot be enabled for reset (3)

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
---
 drivers/clk/ti/clk-3xxx-legacy.c | 16 +++++++++-------
 1 file changed, 9 insertions(+), 7 deletions(-)

diff --git a/drivers/clk/ti/clk-3xxx-legacy.c b/drivers/clk/ti/clk-3xxx-legacy.c
index e0732a4c8f26..0b61548d569b 100644
--- a/drivers/clk/ti/clk-3xxx-legacy.c
+++ b/drivers/clk/ti/clk-3xxx-legacy.c
@@ -4320,7 +4320,6 @@ static struct ti_clk_alias omap3xxx_clks[] = {
 	CLK(NULL, "dpll3_m3x2_ck", &dpll3_m3x2_ck),
 	CLK("etb", "emu_core_alwon_ck", &emu_core_alwon_ck),
 	CLK(NULL, "sys_altclk", &sys_altclk),
-	CLK(NULL, "mcbsp_clks", &mcbsp_clks),
 	CLK(NULL, "sys_clkout1", &sys_clkout1),
 	CLK(NULL, "dpll3_m2_ck", &dpll3_m2_ck),
 	CLK(NULL, "core_ck", &core_ck),
@@ -4369,8 +4368,6 @@ static struct ti_clk_alias omap3xxx_clks[] = {
 	CLK(NULL, "i2c3_fck", &i2c3_fck),
 	CLK(NULL, "i2c2_fck", &i2c2_fck),
 	CLK(NULL, "i2c1_fck", &i2c1_fck),
-	CLK(NULL, "mcbsp5_fck", &mcbsp5_fck),
-	CLK(NULL, "mcbsp1_fck", &mcbsp1_fck),
 	CLK(NULL, "core_48m_fck", &core_48m_fck),
 	CLK(NULL, "mcspi4_fck", &mcspi4_fck),
 	CLK(NULL, "mcspi3_fck", &mcspi3_fck),
@@ -4409,8 +4406,6 @@ static struct ti_clk_alias omap3xxx_clks[] = {
 	CLK(NULL, "uart1_ick", &uart1_ick),
 	CLK(NULL, "gpt11_ick", &gpt11_ick),
 	CLK(NULL, "gpt10_ick", &gpt10_ick),
-	CLK("omap-mcbsp.5", "ick", &mcbsp5_ick),
-	CLK("omap-mcbsp.1", "ick", &mcbsp1_ick),
 	CLK(NULL, "mcbsp5_ick", &mcbsp5_ick),
 	CLK(NULL, "mcbsp1_ick", &mcbsp1_ick),
 	CLK(NULL, "omapctrl_ick", &omapctrl_ick),
@@ -4467,15 +4462,22 @@ static struct ti_clk_alias omap3xxx_clks[] = {
 	CLK(NULL, "gpt4_ick", &gpt4_ick),
 	CLK(NULL, "gpt3_ick", &gpt3_ick),
 	CLK(NULL, "gpt2_ick", &gpt2_ick),
+	CLK(NULL, "mcbsp_clks", &mcbsp_clks),
+	CLK("omap-mcbsp.1", "ick", &mcbsp1_ick),
 	CLK("omap-mcbsp.2", "ick", &mcbsp2_ick),
 	CLK("omap-mcbsp.3", "ick", &mcbsp3_ick),
 	CLK("omap-mcbsp.4", "ick", &mcbsp4_ick),
-	CLK(NULL, "mcbsp4_ick", &mcbsp2_ick),
+	CLK("omap-mcbsp.5", "ick", &mcbsp5_ick),
+	CLK(NULL, "mcbsp1_ick", &mcbsp1_ick),
+	CLK(NULL, "mcbsp2_ick", &mcbsp2_ick),
 	CLK(NULL, "mcbsp3_ick", &mcbsp3_ick),
-	CLK(NULL, "mcbsp2_ick", &mcbsp4_ick),
+	CLK(NULL, "mcbsp4_ick", &mcbsp4_ick),
+	CLK(NULL, "mcbsp5_ick", &mcbsp5_ick),
+	CLK(NULL, "mcbsp1_fck", &mcbsp1_fck),
 	CLK(NULL, "mcbsp2_fck", &mcbsp2_fck),
 	CLK(NULL, "mcbsp3_fck", &mcbsp3_fck),
 	CLK(NULL, "mcbsp4_fck", &mcbsp4_fck),
+	CLK(NULL, "mcbsp5_fck", &mcbsp5_fck),
 	CLK(NULL, "emu_src_mux_ck", &emu_src_mux_ck),
 	CLK("etb", "emu_src_ck", &emu_src_ck),
 	CLK(NULL, "emu_src_mux_ck", &emu_src_mux_ck),
-- 
2.3.0


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

* Re: [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes
  2015-03-16 10:40 [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes Peter Ujfalusi
  2015-03-16 10:40 ` [PATCH 1/2] clk: ti: clk-3xxx: Correct McBSP related DT clock definitions Peter Ujfalusi
  2015-03-16 10:40 ` [PATCH 2/2] clk: ti: clk-3xxx-legacy: Correct McBSP related clock aliases Peter Ujfalusi
@ 2015-03-24 18:50 ` Tero Kristo
  2 siblings, 0 replies; 4+ messages in thread
From: Tero Kristo @ 2015-03-24 18:50 UTC (permalink / raw)
  To: Peter Ujfalusi, mturquette, sboyd; +Cc: tony, linux-omap, linux-kernel

On 03/16/2015 12:40 PM, Peter Ujfalusi wrote:
> Hi,
>
> This series will fix the following error during boot (both DT and legacy boot):
> [    0.307739] omap_hwmod: mcbsp2: _wait_target_ready failed: -16
> [    0.307769] omap_hwmod: mcbsp2: cannot be enabled for reset (3)
>
> The clock definitions/aliases for McBSP ports were not correct.
>
> In case of DT boot we still have the following warning printed from hwmod:
> [    0.222900] omap_hwmod: mcbsp2_sidetone using broken dt data from mcbsp
> [    0.225311] omap_hwmod: mcbsp3_sidetone using broken dt data from mcbsp
>
> These are there because mcbsp is using two hwmods in the DT and hwmod prints
> out a warning for these. In legacy mode we also have 2 hwmods for McBSP2/3.
> One for the McBSP itself and the other for the sidetone block attached to them.
> I'll try to look into this one next.
>
> Since this series fixes the _wait_target_ready issue, can this be sent for 4.0?

I don't think this is a critical fix, the wait_target_ready issue has 
been around for ages. Queued for 4.1 though, thanks.

-Tero

>
> Regards,
> Peter
> ---
> Peter Ujfalusi (2):
>    clk: ti: clk-3xxx: Correct McBSP related DT clock definitions
>    clk: ti: clk-3xxx-legacy: Correct McBSP related clock aliases
>
>   drivers/clk/ti/clk-3xxx-legacy.c | 16 +++++++++-------
>   drivers/clk/ti/clk-3xxx.c        | 19 +++++++------------
>   2 files changed, 16 insertions(+), 19 deletions(-)
>


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

end of thread, other threads:[~2015-03-24 18:50 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-03-16 10:40 [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes Peter Ujfalusi
2015-03-16 10:40 ` [PATCH 1/2] clk: ti: clk-3xxx: Correct McBSP related DT clock definitions Peter Ujfalusi
2015-03-16 10:40 ` [PATCH 2/2] clk: ti: clk-3xxx-legacy: Correct McBSP related clock aliases Peter Ujfalusi
2015-03-24 18:50 ` [PATCH 0/2] clk: ti: OMAP3: McBSP clock fixes Tero Kristo

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).