aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJiri Slaby <jirislaby@gmail.com>2009-09-23 18:57:31 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-09-24 10:21:05 -0400
commitb873c2f34ecd4a5a69b41b852cbc365694541c5f (patch)
tree01daaa2aadfa8e88206129ee13d363d009df5a51 /drivers
parent3886de938cc23d5208a34064d8363d6d7b54b461 (diff)
memstick: move dev_dbg
id_reg.if_mode might be unitialized when (*mrq)->error is nonzero. move dev_dbg() inside the if so that we are sure we can use id_reg values. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Cc: 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')
-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 a5b448ea4eab..b3bf1c44d74d 100644
--- a/drivers/memstick/core/memstick.c
+++ b/drivers/memstick/core/memstick.c
@@ -339,9 +339,9 @@ static int h_memstick_read_dev_id(struct memstick_dev *card,
339 card->id.type = id_reg.type; 339 card->id.type = id_reg.type;
340 card->id.category = id_reg.category; 340 card->id.category = id_reg.category;
341 card->id.class = id_reg.class; 341 card->id.class = id_reg.class;
342 dev_dbg(&card->dev, "if_mode = %02x\n", id_reg.if_mode);
342 } 343 }
343 complete(&card->mrq_complete); 344 complete(&card->mrq_complete);
344 dev_dbg(&card->dev, "if_mode = %02x\n", id_reg.if_mode);
345 return -EAGAIN; 345 return -EAGAIN;
346 } 346 }
347} 347}