2010/11/23 Chris Ball <cjb@xxxxxxxxxx>: > [ 10.136067] mmc0: frequency set to 0 in disable function, this means the clock is already disabled. > [ 10.164089] mmc0: frequency set to 0 in disable function, this means the clock is already disabled. > [ 10.192076] mmc0: frequency set to 0 in disable function, this means the clock is already disabled. > [ 10.291095] mmc1: frequency set to 0 in disable function, this means the clock is already disabled. > [ 10.319029] mmc1: frequency set to 0 in disable function, this means the clock is already disabled. > > * Are we expecting mmc_host_clk_gate_delayed() to be called so often > with host->ios.clock == 0? It didn't use to be like that back when I first wrote the patch, but it seems to be like that nowadays. So yes. Did the gating work by the way? No strangeness because of it? > There's a full log with CONFIG_MMC_DEBUG=y > at http://chris.printf.net/mmc-clkgate-debug in case it helps you see > what's going on. > > * If you think the current behavior should stay, we would at least want > to convert it to a dev_dbg so that it's only visible under MMC_DEBUG=y, > right? Hm? It's pr_debug() already in host.c: pr_debug("%s: frequency set to 0 in disable function, " "this means the clock is already disabled.\n", mmc_hostname(host)); pr_debug is only printed when -DDEBUG is set, which is what MMC_DEBUG=y does isn't it? But I can patch it to use dev_dbg() I think, does the below patch solve the thing you want? Yours, Linus Walleij >From 75428e5cc51f1775389d5e3ad953e3b9edd43984 Mon Sep 17 00:00:00 2001 From: Linus Walleij <linus.walleij@xxxxxxxxxxxxxx> Date: Wed, 24 Nov 2010 14:08:14 +0100 Subject: [PATCH] mmc: switch clockgating message from pr_debug to dev_dbg This prints clock gating information with the dev_* macro instead. Signed-off-by: Linus Walleij <linus.walleij@xxxxxxxxxxxxxx> --- drivers/mmc/core/host.c | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/mmc/core/host.c b/drivers/mmc/core/host.c index 92e3370..69fa70a 100644 --- a/drivers/mmc/core/host.c +++ b/drivers/mmc/core/host.c @@ -68,9 +68,9 @@ static void mmc_host_clk_gate_delayed(struct mmc_host *host) unsigned long flags; if (!freq) { - pr_debug("%s: frequency set to 0 in disable function, " - "this means the clock is already disabled.\n", - mmc_hostname(host)); + dev_dbg(mmc_dev(host), "frequency set to 0 in disable " + "function, this means the clock is already " + "disabled\n"); return; } /* @@ -101,7 +101,7 @@ static void mmc_host_clk_gate_delayed(struct mmc_host *host) /* This will set host->ios.clock to 0 */ mmc_gate_clock(host); spin_lock_irqsave(&host->clk_lock, flags); - pr_debug("%s: gated MCI clock\n", mmc_hostname(host)); + dev_dbg(mmc_dev(host), "gated MCI clock\n"); } spin_unlock_irqrestore(&host->clk_lock, flags); mutex_unlock(&host->clk_gate_mutex); @@ -136,7 +136,7 @@ void mmc_host_clk_ungate(struct mmc_host *host) spin_unlock_irqrestore(&host->clk_lock, flags); mmc_ungate_clock(host); spin_lock_irqsave(&host->clk_lock, flags); - pr_debug("%s: ungated MCI clock\n", mmc_hostname(host)); + dev_dbg(mmc_dev(host), "ungated MCI clock\n"); } host->clk_requests++; spin_unlock_irqrestore(&host->clk_lock, flags); -- 1.7.3.2 -- 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