]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/blob - releases/3.0.18/mmc-sdhci-fix-tuning-timer-incorrect-setting-when-suspending-host.patch
5.1-stable patches
[thirdparty/kernel/stable-queue.git] / releases / 3.0.18 / mmc-sdhci-fix-tuning-timer-incorrect-setting-when-suspending-host.patch
1 From c6ced0db08010ed75df221a2946c5228454b38d5 Mon Sep 17 00:00:00 2001
2 From: Aaron Lu <aaron.lu@amd.com>
3 Date: Wed, 28 Dec 2011 11:11:12 +0800
4 Subject: mmc: sdhci: Fix tuning timer incorrect setting when suspending host
5
6 From: Aaron Lu <aaron.lu@amd.com>
7
8 commit c6ced0db08010ed75df221a2946c5228454b38d5 upstream.
9
10 When suspending host, the tuning timer shoule be deactivated.
11 And the HOST_NEEDS_TUNING flag should be set after tuning timer is
12 deactivated.
13
14 Signed-off-by: Philip Rakity <prakity@marvell.com>
15 Signed-off-by: Aaron Lu <aaron.lu@amd.com>
16 Acked-by: Adrian Hunter <adrian.hunter@intel.com>
17 Signed-off-by: Chris Ball <cjb@laptop.org>
18 Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
19
20 ---
21 drivers/mmc/host/sdhci.c | 3 +--
22 1 file changed, 1 insertion(+), 2 deletions(-)
23
24 --- a/drivers/mmc/host/sdhci.c
25 +++ b/drivers/mmc/host/sdhci.c
26 @@ -2227,9 +2227,8 @@ int sdhci_suspend_host(struct sdhci_host
27 /* Disable tuning since we are suspending */
28 if (host->version >= SDHCI_SPEC_300 && host->tuning_count &&
29 host->tuning_mode == SDHCI_TUNING_MODE_1) {
30 + del_timer_sync(&host->tuning_timer);
31 host->flags &= ~SDHCI_NEEDS_RETUNING;
32 - mod_timer(&host->tuning_timer, jiffies +
33 - host->tuning_count * HZ);
34 }
35
36 ret = mmc_suspend_host(host->mmc);