RFC: clearing clk_old?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I'm trying to see where host->clk_old is cleared in MMC core. Since I
didn't find it, any reason to NOT do one or both of the below patches?

thanks,
grant

ps. This is cut/pasted and white space mangled...hopefully readable though.

diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c
index c9a227c..73c3792 100644
--- a/drivers/mmc/core/core.c
+++ b/drivers/mmc/core/core.c
@@ -787,6 +787,7 @@ void mmc_ungate_clock(struct mmc_host *host)
                BUG_ON(host->ios.clock);
                /* This call will also set host->clk_gated to false */
                __mmc_set_clock(host, host->clk_old);
+               host->clk_old = 0;
        }
 }

@@ -800,6 +801,7 @@ void mmc_set_ungated(struct mmc_host *host)
         */
        spin_lock_irqsave(&host->clk_lock, flags);
        host->clk_gated = false;
+       host->clk_old = 0;
        spin_unlock_irqrestore(&host->clk_lock, flags);
 }



diff --git a/drivers/mmc/core/core.c b/drivers/mmc/core/core.c
index c9a227c..f5ae008 100644
--- a/drivers/mmc/core/core.c
+++ b/drivers/mmc/core/core.c
@@ -800,6 +800,7 @@ void mmc_set_ungated(struct mmc_host *host)
         */
        spin_lock_irqsave(&host->clk_lock, flags);
        host->clk_gated = false;
+       host->clk_old = 0;
        spin_unlock_irqrestore(&host->clk_lock, flags);
 }
--
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




[Index of Archives]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux