AnsweredAssumed Answered

Change the SSP0 clock from max 28.8MHz to 50 MHz

Question asked by Ankur Patel on Feb 20, 2014
Latest reply on Feb 27, 2014 by Ankur Patel

Hello Friends,

 

I am using imx28evk running linux kernel 3.10.29. I have found that the SSP0 (MMC slot 0) can only run maximum of clock 28.8MHz as mentioned in the

file: drivers/mmc/host/mxs-mmc.c


Line#666

   mmc->f_min = 400000;

  mmc->f_max = 288000000;

 

I want to plug the TI wifi module that runs on 50MHz. In this case, I would like to increase the clock frequency of SSP0 to 50 MHz. Is there any way I can change it?

 

Moreover, I found that "ref_io0" is set to 288 MHz below from file: drivers/clk/mxs/clk-imx28.c. Which code changes the frequency from 228 MHz to 28.8 MHz (maximum) ?

/*

118          * 480 MHz seems too high to be ssp clock source directly,

119          * so set frac0 to get a 288 MHz ref_io0 and ref_io1.

120          */

121         val = readl_relaxed(FRAC0);

122         val &= ~((0x3f << BP_FRAC0_IO0FRAC) | (0x3f << BP_FRAC0_IO1FRAC));

123         val |= (30 << BP_FRAC0_IO0FRAC) | (30 << BP_FRAC0_IO1FRAC);

124         writel_relaxed(val, FRAC0);

 

Any help is highly appreciated.

 

Thank you,

Ankur

Outcomes