Commit 29196dc67e1b76ce84e25228783f6b8a3c48e9dd

Authored by Alex Dubov
Committed by Linus Torvalds
1 parent d114ad54ff

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>

Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff

drivers/memstick/core/memstick.c
... ... @@ -236,7 +236,7 @@
236 236 rc = host->card->next_request(host->card, mrq);
237 237  
238 238 if (!rc)
239   - host->retries = cmd_retries;
  239 + host->retries = cmd_retries > 1 ? cmd_retries - 1 : 1;
240 240 else
241 241 *mrq = NULL;
242 242