Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1638204
| From | Colin King <colin.king@canonical.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH] mmc: sdricoh_cs: remove redundant check if len is non-zero |
| Date | 2017-05-09 17:50 +0200 |
| Message-ID | <tFfyG-3F4-3@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
From: Colin Ian King <colin.king@canonical.com>
At the end of either of the read or write loops len is always zero
and hence the non-zero check on len and return of -EIO is redundant
and can be removed.
Detected by CoverityScan, CID#114293 ("Logically dead code")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
drivers/mmc/host/sdricoh_cs.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/drivers/mmc/host/sdricoh_cs.c b/drivers/mmc/host/sdricoh_cs.c
index 5ff26ab81eb1..70cb00aa79a0 100644
--- a/drivers/mmc/host/sdricoh_cs.c
+++ b/drivers/mmc/host/sdricoh_cs.c
@@ -256,9 +256,6 @@ static int sdricoh_blockio(struct sdricoh_host *host, int read,
}
}
- if (len)
- return -EIO;
-
return 0;
}
--
2.11.0
Back to linux.kernel | Previous | Next | Find similar | Unroll thread
[PATCH] mmc: sdricoh_cs: remove redundant check if len is non-zero Colin King <colin.king@canonical.com> - 2017-05-09 17:50 +0200
csiph-web