[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20110326000456.240291632@clark.kroah.org>
Date: Fri, 25 Mar 2011 17:03:36 -0700
From: Greg KH <gregkh@...e.de>
To: linux-kernel@...r.kernel.org, stable@...nel.org
Cc: stable-review@...nel.org, torvalds@...ux-foundation.org,
akpm@...ux-foundation.org, alan@...rguk.ukuu.org.uk,
Stefan Nilsson XK <stefan.xk.nilsson@...ricsson.com>,
Linus Walleij <linus.walleij@...aro.org>,
Chris Ball <cjb@...top.org>
Subject: [04/35] mmc: sdio: remember new card RCA when redetecting card
2.6.33-longterm review patch. If anyone has any objections, please let us know.
------------------
From: Stefan Nilsson XK <stefan.xk.nilsson@...ricsson.com>
commit 0aab3995485b8a994bf29a995a008c9ea4a28054 upstream.
During redetection of a SDIO card, a request for a new card RCA
was submitted to the card, but was then overwritten by the old RCA.
This caused the card to be deselected instead of selected when using
the incorrect RCA. This bug's been present since the "oldcard"
handling was introduced in 2.6.32.
Signed-off-by: Stefan Nilsson XK <stefan.xk.nilsson@...ricsson.com>
Reviewed-by: Ulf Hansson <ulf.hansson@...ricsson.com>
Reviewed-by: Pawel Wieczorkiewicz <pawel.wieczorkiewicz@...ricsson.com>
Signed-off-by: Linus Walleij <linus.walleij@...aro.org>
Signed-off-by: Chris Ball <cjb@...top.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@...e.de>
---
drivers/mmc/core/sdio.c | 8 ++++++++
1 file changed, 8 insertions(+)
--- a/drivers/mmc/core/sdio.c
+++ b/drivers/mmc/core/sdio.c
@@ -267,6 +267,14 @@ static int mmc_sdio_init_card(struct mmc
if (err)
goto remove;
+ /*
+ * Update oldcard with the new RCA received from the SDIO
+ * device -- we're doing this so that it's updated in the
+ * "card" struct when oldcard overwrites that later.
+ */
+ if (oldcard)
+ oldcard->rca = card->rca;
+
mmc_set_bus_mode(host, MMC_BUSMODE_PUSHPULL);
}
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists