On Thu, Jan 24, 2013 at 1:59 PM, Russell King - ARM Linux <linux@xxxxxxxxxxxxxxxx> wrote: > The clock can be masked independently too via the clock enable bit in > the clock register. > > However, it's interesting to note: experiments that Linus did with having > the primecell automatically masking the clock to the card did not prove > worthwhile (see the comment in the code). We seem to be heading towards > doing this in software and people suggesting it is worthwhile... Why is > this? > > If the hardware can gate the clock and it doesn't produce the power > savings we expect, how does then gating the clock via software then > become worthwhile? It doesn't make sense. We're talking about this I guess: http://marc.info/?l=linux-arm-kernel&m=123790711306850&w=4 In these experiments I actually gated not only the enable bit (bit 8) to the MCI clock, but also the pclk to the PrimeCell itself as well. This was due to the U300 clock framework doing that behind the scenes on clk_disable(host->clk); And the reason the clock framework was doing that was that the U300 had the block clock and the card clock wired to the same clock tap ... The equivalent patch today would also call amba_pclk_disable() when the card was inactive. Thus we also got rid of all the switching leaks in the PL180 logic. (Containing two big state machines for example.) It was an interesting comparison to just enable PwrSave (bit 9) instead, and disable the other clock logic. It turned out that this saving was significantly bigger when gating the entire PrimeCell than the savings for just gating the clock out to the card itself with bit 9. But at this time I didn't have a card in the slot, so as to eliminate the power consumed in the card (assuming this would drown the overall current consumption). So I have second thoughts about this. The experiment was not testing the PwrSave bit with a card inserted, this is the wrong thing to do. To determine if that bit is a good thing to turn on, it needs to be tested with a card in the slot. The only really useful information is that the switching logic inside the PL180 synthesized IP-core consumes circa 200uA, so it could be useful to gate it at times. Anyone wants to re-do the measurements? Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-mmc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html