summaryrefslogtreecommitdiff
path: root/drivers/mmc/core/sd_ops.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mmc/core/sd_ops.c')
-rw-r--r--drivers/mmc/core/sd_ops.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/mmc/core/sd_ops.c b/drivers/mmc/core/sd_ops.c
index 76af349c14b4..da508497a6e0 100644
--- a/drivers/mmc/core/sd_ops.c
+++ b/drivers/mmc/core/sd_ops.c
@@ -29,6 +29,8 @@ static int mmc_app_cmd(struct mmc_host *host, struct mmc_card *card)
BUG_ON(!host);
BUG_ON(card && (card->host != host));
+ memset(&cmd, 0, sizeof(struct mmc_command));
+
cmd.opcode = MMC_APP_CMD;
if (card) {
@@ -199,6 +201,8 @@ int mmc_send_if_cond(struct mmc_host *host, u32 ocr)
static const u8 test_pattern = 0xAA;
u8 result_pattern;
+ memset(&cmd, 0, sizeof(struct mmc_command));
+
/*
* To support SD 2.0 cards, we must always invoke SD_SEND_IF_COND
* before SD_APP_OP_COND. This command will harmlessly fail for