2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-19 02:34:01 +08:00

mmc: check for > 1 clk_requests when disabling gating

Since we make sure the clock is enabled in the mmc_host_clk_exit()
function we should expect a reference counter of 1, not 0.

Signed-off-by: Linus Walleij <linus.walleij@stericsson.com>
Tested-by: Chris Ball <cjb@laptop.org>
Signed-off-by: Chris Ball <cjb@laptop.org>
This commit is contained in:
Linus Walleij 2010-12-22 09:50:12 +01:00 committed by Chris Ball
parent 253e0a7c3d
commit c288b85554

View File

@ -235,7 +235,8 @@ static inline void mmc_host_clk_exit(struct mmc_host *host)
mmc_host_clk_gate_delayed(host);
if (host->clk_gated)
mmc_host_clk_ungate(host);
BUG_ON(host->clk_requests > 0);
/* There should be only one user now */
WARN_ON(host->clk_requests > 1);
}
#else