diff options
author | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-01-13 15:30:24 -0200 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-01-13 16:28:17 -0200 |
commit | c61c3094a630b2f795addc3a74fbd5ff7f704ca9 (patch) | |
tree | b871fe2f56322a8cdf2c9d8fb2f13acbd7644f7e | |
parent | e4a3bc1c2c1aebb09ef12f0eb52cf5e6a1d5b9d3 (diff) |
[media] go7007-usb: only use go->dev after allocated
Fixes those warnings:
drivers/staging/media/go7007/go7007-usb.c: In function 'go7007_usb_probe':
drivers/staging/media/go7007/go7007-usb.c:1060: warning: 'go' is used uninitialized in this function
While here, comment a code that will never run.
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
-rw-r--r-- | drivers/staging/media/go7007/go7007-usb.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/drivers/staging/media/go7007/go7007-usb.c b/drivers/staging/media/go7007/go7007-usb.c index 58684da45e6c..1d747de6dfa6 100644 --- a/drivers/staging/media/go7007/go7007-usb.c +++ b/drivers/staging/media/go7007/go7007-usb.c @@ -1057,7 +1057,7 @@ static int go7007_usb_probe(struct usb_interface *intf, char *name; int video_pipe, i, v_urb_len; - dev_dbg(go->dev, "probing new GO7007 USB board\n"); + printk(KERN_DEBUG "go7007-usb: probing new board\n"); switch (id->driver_info) { case GO7007_BOARDID_MATRIX_II: @@ -1097,13 +1097,16 @@ static int go7007_usb_probe(struct usb_interface *intf, board = &board_px_tv402u; break; case GO7007_BOARDID_LIFEVIEW_LR192: - dev_err(go->dev, "The Lifeview TV Walker Ultra is not supported. Sorry!\n"); + printk(KERN_ERR + "The Lifeview TV Walker Ultra is not supported. Sorry!\n"); return -ENODEV; +#if 0 name = "Lifeview TV Walker Ultra"; board = &board_lifeview_lr192; break; +#endif case GO7007_BOARDID_SENSORAY_2250: - dev_info(go->dev, "Sensoray 2250 found\n"); + printk(KERN_INFO "Sensoray 2250 found\n"); name = "Sensoray 2250/2251"; board = &board_sensoray_2250; break; @@ -1112,8 +1115,9 @@ static int go7007_usb_probe(struct usb_interface *intf, board = &board_ads_usbav_709; break; default: - dev_err(go->dev, "unknown board ID %d!\n", - (unsigned int)id->driver_info); + printk(KERN_ERR + "unknown board ID %d!\n", + (unsigned int)id->driver_info); return -ENODEV; } |