Skip to content

Commit

Permalink
mmc: card: Fix use of uninitialized data in mmc_blk_issue_rw_rq.
Browse files Browse the repository at this point in the history
mmc_blk_issue_rw_rq did not zero out mmc_command on stack.

Signed-off-by: Chris Ball <[email protected]>
  • Loading branch information
cjb committed May 25, 2011
1 parent 30574ed commit 62929e4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/mmc/card/block.c
Original file line number Diff line number Diff line change
Expand Up @@ -504,6 +504,7 @@ static int mmc_blk_issue_rw_rq(struct mmc_queue *mq, struct request *req)
struct mmc_command cmd;
u32 readcmd, writecmd, status = 0;

memset(&cmd, 0, sizeof(struct mmc_command));
memset(&brq, 0, sizeof(struct mmc_blk_request));
brq.mrq.cmd = &brq.cmd;
brq.mrq.data = &brq.data;
Expand Down

0 comments on commit 62929e4

Please sign in to comment.