]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
ENGR00143799 Add SCC RAM clock to dependency list for SAHARA clock tree
authorAnish Trivedi <anish@freescale.com>
Fri, 20 May 2011 16:51:01 +0000 (11:51 -0500)
committerOliver Wendt <ow@karo-electronics.de>
Mon, 30 Sep 2013 12:09:07 +0000 (14:09 +0200)
When ARM is in WAIT mode, the SCC RAM clock is disabled since
1 is written to the CCGR register by default. At that point, if SAHARA
tries to access a key or some other piece of data stored in the SCC RAM,
then it might hang.

To prevent this scenario, SCC RAM is added to dependency list
for SCC clock, and SCC clock is added to dependency list for SAHARA.

Signed-off-by: Anish Trivedi <anish@freescale.com>
arch/arm/mach-mx5/clock.c

index 9ff2243b3880a958d8fc1e7f71667a8ba2e7c932..775e3f1fc207d555ba0f800222de911d2c94ac54 100755 (executable)
@@ -4148,36 +4148,44 @@ static struct clk fec_clk[] = {
        },
 };
 
-static struct clk sahara_clk[] = {
+static struct clk scc_clk[] = {
        {
        __INIT_CLK_DEBUG(sahara_clk_0)
        .parent = &ahb_clk,
-       .secondary = &sahara_clk[1],
-       .enable_reg = MXC_CCM_CCGR4,
-       .enable_shift = MXC_CCM_CCGRx_CG7_OFFSET,
+       .secondary = &scc_clk[1],
+       .enable_reg = MXC_CCM_CCGR1,
+       .enable_shift = MXC_CCM_CCGRx_CG15_OFFSET,
        .enable = _clk_enable,
        .disable = _clk_disable,
        },
        {
        __INIT_CLK_DEBUG(sahara_clk_1)
        .parent = &tmax1_clk,
-       .secondary = &emi_fast_clk,
+       .secondary = &scc_clk[2],
+       },
+       {
+       .parent = &emi_fast_clk,
+       .secondary = &emi_intr_clk[0],
        }
 };
 
-static struct clk scc_clk[] = {
+static struct clk sahara_clk[] = {
        {
        __INIT_CLK_DEBUG(scc_clk_0)
        .parent = &ahb_clk,
-       .secondary = &scc_clk[1],
-       .enable_reg = MXC_CCM_CCGR1,
-       .enable_shift = MXC_CCM_CCGRx_CG15_OFFSET,
+       .secondary = &sahara_clk[1],
+       .enable_reg = MXC_CCM_CCGR4,
+       .enable_shift = MXC_CCM_CCGRx_CG7_OFFSET,
        .enable = _clk_enable,
        .disable = _clk_disable,
        },
        {
        __INIT_CLK_DEBUG(scc_clk_1)
        .parent = &tmax1_clk,
+       .secondary = &sahara_clk[2],
+       },
+       {
+       .parent = &scc_clk,
        .secondary = &emi_fast_clk,
        }
 };