summaryrefslogtreecommitdiff
path: root/drivers/memstick
diff options
context:
space:
mode:
authorAlex Dubov <oakad@yahoo.com>2008-03-10 11:43:38 -0700
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-03-10 18:01:18 -0700
commit29196dc67e1b76ce84e25228783f6b8a3c48e9dd (patch)
treea007d8aca64c24851f8977239f3b044b93893bad /drivers/memstick
parentd114ad54ffb020dc781b6159c1c2f391c6ec418f (diff)
memstick: make sure number of command retries is exactly as specified
Signed-off-by: Alex Dubov <oakad@yahoo.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/memstick')
-rw-r--r--drivers/memstick/core/memstick.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/memstick/core/memstick.c b/drivers/memstick/core/memstick.c
index 3c97bac4e47b..decd6a49fd5a 100644
--- a/drivers/memstick/core/memstick.c
+++ b/drivers/memstick/core/memstick.c
@@ -236,7 +236,7 @@ int memstick_next_req(struct memstick_host *host, struct memstick_request **mrq)
rc = host->card->next_request(host->card, mrq);
if (!rc)
- host->retries = cmd_retries;
+ host->retries = cmd_retries > 1 ? cmd_retries - 1 : 1;
else
*mrq = NULL;