Skip to content

Commit 503d0ea

Browse files
author
Paul Walmsley
committed
ARM: OMAP4: hwmod data: Add aliases for McBSP fclk clocks
CLKS signal for McBSP ports can be selected from internal (PRCM) or external (ABE_CLKS pin) source. To be able to use existing code we need to create clock aliases consistent among OMAP2/3/4. Based on a patch from Péter Ujfalusi <[email protected]>; the patch description above is his. Signed-off-by: Paul Walmsley <[email protected]> Cc: Péter Ujfalusi <[email protected]> Cc: Tony Lindgren <[email protected]> Acked-by: Peter Ujfalusi <[email protected]>
1 parent dd775ae commit 503d0ea

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

arch/arm/mach-omap2/omap_hwmod_44xx_data.c

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2996,6 +2996,11 @@ static struct omap_hwmod_ocp_if *omap44xx_mcbsp1_slaves[] = {
29962996
&omap44xx_l4_abe__mcbsp1_dma,
29972997
};
29982998

2999+
static struct omap_hwmod_opt_clk mcbsp1_opt_clks[] = {
3000+
{ .role = "pad_fck", .clk = "pad_clks_ck" },
3001+
{ .role = "prcm_clk", .clk = "mcbsp1_sync_mux_ck" },
3002+
};
3003+
29993004
static struct omap_hwmod omap44xx_mcbsp1_hwmod = {
30003005
.name = "mcbsp1",
30013006
.class = &omap44xx_mcbsp_hwmod_class,
@@ -3012,6 +3017,8 @@ static struct omap_hwmod omap44xx_mcbsp1_hwmod = {
30123017
},
30133018
.slaves = omap44xx_mcbsp1_slaves,
30143019
.slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp1_slaves),
3020+
.opt_clks = mcbsp1_opt_clks,
3021+
.opt_clks_cnt = ARRAY_SIZE(mcbsp1_opt_clks),
30153022
};
30163023

30173024
/* mcbsp2 */
@@ -3071,6 +3078,11 @@ static struct omap_hwmod_ocp_if *omap44xx_mcbsp2_slaves[] = {
30713078
&omap44xx_l4_abe__mcbsp2_dma,
30723079
};
30733080

3081+
static struct omap_hwmod_opt_clk mcbsp2_opt_clks[] = {
3082+
{ .role = "pad_fck", .clk = "pad_clks_ck" },
3083+
{ .role = "prcm_clk", .clk = "mcbsp2_sync_mux_ck" },
3084+
};
3085+
30743086
static struct omap_hwmod omap44xx_mcbsp2_hwmod = {
30753087
.name = "mcbsp2",
30763088
.class = &omap44xx_mcbsp_hwmod_class,
@@ -3087,6 +3099,8 @@ static struct omap_hwmod omap44xx_mcbsp2_hwmod = {
30873099
},
30883100
.slaves = omap44xx_mcbsp2_slaves,
30893101
.slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp2_slaves),
3102+
.opt_clks = mcbsp2_opt_clks,
3103+
.opt_clks_cnt = ARRAY_SIZE(mcbsp2_opt_clks),
30903104
};
30913105

30923106
/* mcbsp3 */
@@ -3146,6 +3160,11 @@ static struct omap_hwmod_ocp_if *omap44xx_mcbsp3_slaves[] = {
31463160
&omap44xx_l4_abe__mcbsp3_dma,
31473161
};
31483162

3163+
static struct omap_hwmod_opt_clk mcbsp3_opt_clks[] = {
3164+
{ .role = "pad_fck", .clk = "pad_clks_ck" },
3165+
{ .role = "prcm_clk", .clk = "mcbsp3_sync_mux_ck" },
3166+
};
3167+
31493168
static struct omap_hwmod omap44xx_mcbsp3_hwmod = {
31503169
.name = "mcbsp3",
31513170
.class = &omap44xx_mcbsp_hwmod_class,
@@ -3162,6 +3181,8 @@ static struct omap_hwmod omap44xx_mcbsp3_hwmod = {
31623181
},
31633182
.slaves = omap44xx_mcbsp3_slaves,
31643183
.slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp3_slaves),
3184+
.opt_clks = mcbsp3_opt_clks,
3185+
.opt_clks_cnt = ARRAY_SIZE(mcbsp3_opt_clks),
31653186
};
31663187

31673188
/* mcbsp4 */
@@ -3200,6 +3221,11 @@ static struct omap_hwmod_ocp_if *omap44xx_mcbsp4_slaves[] = {
32003221
&omap44xx_l4_per__mcbsp4,
32013222
};
32023223

3224+
static struct omap_hwmod_opt_clk mcbsp4_opt_clks[] = {
3225+
{ .role = "pad_fck", .clk = "pad_clks_ck" },
3226+
{ .role = "prcm_clk", .clk = "mcbsp4_sync_mux_ck" },
3227+
};
3228+
32033229
static struct omap_hwmod omap44xx_mcbsp4_hwmod = {
32043230
.name = "mcbsp4",
32053231
.class = &omap44xx_mcbsp_hwmod_class,
@@ -3216,6 +3242,8 @@ static struct omap_hwmod omap44xx_mcbsp4_hwmod = {
32163242
},
32173243
.slaves = omap44xx_mcbsp4_slaves,
32183244
.slaves_cnt = ARRAY_SIZE(omap44xx_mcbsp4_slaves),
3245+
.opt_clks = mcbsp4_opt_clks,
3246+
.opt_clks_cnt = ARRAY_SIZE(mcbsp4_opt_clks),
32193247
};
32203248

32213249
/*

0 commit comments

Comments
 (0)