diff options
author | Simon Que <sque@chromium.org> | 2013-01-17 09:29:49 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-01-18 14:29:25 -0500 |
commit | 15c8bb1284c2e4b0614274602f0d92c4ea3412df (patch) | |
tree | f991819a242d9634eacbac4ad9f430f1f6effdf2 /drivers/net/usb/dm9601.c | |
parent | fae50823d0ee579e006a7ba2b20880e354388b25 (diff) | |
download | linux-15c8bb1284c2e4b0614274602f0d92c4ea3412df.tar.bz2 |
net: usb: initialize tmp in dm9601.c to avoid warning
In two places, tmp is initialized implicitly by being passed as a
pointer during a function call. However, this is not obvious to the
compiler, which logs a warning.
Signed-off-by: Simon Que <sque@chromium.org>
Acked-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/usb/dm9601.c')
-rw-r--r-- | drivers/net/usb/dm9601.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/usb/dm9601.c b/drivers/net/usb/dm9601.c index 3f554c1149f3..0794004fd9d8 100644 --- a/drivers/net/usb/dm9601.c +++ b/drivers/net/usb/dm9601.c @@ -122,7 +122,7 @@ static int dm_read_shared_word(struct usbnet *dev, int phy, u8 reg, __le16 *valu dm_write_reg(dev, DM_SHARED_CTRL, phy ? 0xc : 0x4); for (i = 0; i < DM_TIMEOUT; i++) { - u8 tmp; + u8 tmp = 0; udelay(1); ret = dm_read_reg(dev, DM_SHARED_CTRL, &tmp); @@ -165,7 +165,7 @@ static int dm_write_shared_word(struct usbnet *dev, int phy, u8 reg, __le16 valu dm_write_reg(dev, DM_SHARED_CTRL, phy ? 0x1a : 0x12); for (i = 0; i < DM_TIMEOUT; i++) { - u8 tmp; + u8 tmp = 0; udelay(1); ret = dm_read_reg(dev, DM_SHARED_CTRL, &tmp); |