[brcm63xx] resync kernel configuration
[openwrt.git] / target / linux / s3c24xx / patches-2.6.26 / 1216-fix-scard-stop-on-resume.patch.patch
1 From 81b94de6dbb00676ddca78219eacf41b1928b33f Mon Sep 17 00:00:00 2001
2 From: Andy Green <andy@openmoko.com>
3 Date: Fri, 25 Jul 2008 23:06:20 +0100
4 Subject: [PATCH] fix-scard-stop-on-resume.patch
5 Reported-by: Ville-Pekka Vainio <vpivaini@cs.helsinki.fi>
6
7 The reporter noticed SD Card clock is running again after resume. After
8 looking at the code I saw I missed two tricks, this will force it off
9 after resume and will do better generally depending on what the last SD Card
10 packet was.
11
12 Since bulk read packet is normally last action (which set the clock off even
13 without this) the old patch worked for normal cases. But after resume, the last
14 packet on the wire was not a bulk transfer and we didn't take care about the
15 clock then.
16
17 Signed-off-by: Andy Green <andy@openmoko.com>
18 ---
19 drivers/mfd/glamo/glamo-mci.c | 6 +++---
20 1 files changed, 3 insertions(+), 3 deletions(-)
21
22 diff --git a/drivers/mfd/glamo/glamo-mci.c b/drivers/mfd/glamo/glamo-mci.c
23 index 67bb815..93f4074 100644
24 --- a/drivers/mfd/glamo/glamo-mci.c
25 +++ b/drivers/mfd/glamo/glamo-mci.c
26 @@ -619,12 +619,9 @@ done:
27 host->complete_what = COMPLETION_NONE;
28 host->mrq = NULL;
29 mmc_request_done(host->mmc, cmd->mrq);
30 - return;
31 -
32 bail:
33 /* stop the clock to card */
34 __glamo_mci_fix_card_div(host, -1);
35 - return;
36 }
37
38 static void glamo_mci_request(struct mmc_host *mmc, struct mmc_request *mrq)
39 @@ -690,6 +687,9 @@ static void glamo_mci_set_ios(struct mmc_host *mmc, struct mmc_ios *ios)
40 host->real_rate = __glamo_mci_set_card_clock(host, ios->clock, &div);
41 host->clk_div = div;
42
43 + /* stop the clock to card, because we are idle until transfer */
44 + __glamo_mci_fix_card_div(host, -1);
45 +
46 if ((ios->power_mode == MMC_POWER_ON) ||
47 (ios->power_mode == MMC_POWER_UP)) {
48 dev_info(&host->pdev->dev,
49 --
50 1.5.6.3
51
This page took 0.044349 seconds and 5 git commands to generate.