diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-04-20 16:53:27 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-04-23 16:46:11 -0700 |
commit | aec238825f448706dd886ac8df46e9c25a883dec (patch) | |
tree | f72e049373bd46e4dd97cd0b9b075bc982d6007e /drivers/staging/frontier | |
parent | aa8f827a4d7dbea98a9076a4f85b1317391dc031 (diff) | |
download | linux-stable-aec238825f448706dd886ac8df46e9c25a883dec.tar.gz linux-stable-aec238825f448706dd886ac8df46e9c25a883dec.tar.bz2 linux-stable-aec238825f448706dd886ac8df46e9c25a883dec.zip |
staging: frontier: tranzport.c: remove err() usage
err() was a very old USB-specific macro that I thought had
gone away. This patch removes it from being used in the
driver and uses dev_err() instead.
CC: "David Täht" <d@teklibre.com>
CC: Hitoshi Nakamori <hitoshi.nakamori@gmail.com>
CC: "Ken O'Brien" <kernel@kenobrien.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/frontier')
-rw-r--r-- | drivers/staging/frontier/tranzport.c | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/drivers/staging/frontier/tranzport.c b/drivers/staging/frontier/tranzport.c index 29e99bbcae48..376706f1c712 100644 --- a/drivers/staging/frontier/tranzport.c +++ b/drivers/staging/frontier/tranzport.c @@ -353,7 +353,7 @@ static int usb_tranzport_open(struct inode *inode, struct file *file) interface = usb_find_interface(&usb_tranzport_driver, subminor); if (!interface) { - err("%s - error, can't find device for minor %d\n", + printk(KERN_ERR "%s - error, can't find device for minor %d\n", __func__, subminor); retval = -ENODEV; goto unlock_disconnect_exit; @@ -517,9 +517,11 @@ static ssize_t usb_tranzport_read(struct file *file, char __user *buffer, goto exit; } - /* verify that the device wasn't unplugged */ if (dev->intf == NULL) { + /* verify that the device wasn't unplugged */ + if (dev->intf == NULL) { retval = -ENODEV; - err("No device or device unplugged %d\n", retval); + printk(KERN_ERR "%s: No device or device unplugged %d\n", + __func__, retval); goto unlock_exit; } @@ -691,7 +693,8 @@ static ssize_t usb_tranzport_write(struct file *file, /* verify that the device wasn't unplugged */ if (dev->intf == NULL) { retval = -ENODEV; - err("No device or device unplugged %d\n", retval); + printk(KERN_ERR "%s: No device or device unplugged %d\n", + __func__, retval); goto unlock_exit; } @@ -726,7 +729,7 @@ static ssize_t usb_tranzport_write(struct file *file, } if (dev->interrupt_out_endpoint == NULL) { - err("Endpoint should not be be null!\n"); + dev_err(&dev->intf->dev, "Endpoint should not be be null!\n"); goto unlock_exit; } @@ -746,7 +749,8 @@ static ssize_t usb_tranzport_write(struct file *file, retval = usb_submit_urb(dev->interrupt_out_urb, GFP_KERNEL); if (retval) { dev->interrupt_out_busy = 0; - err("Couldn't submit interrupt_out_urb %d\n", retval); + dev_err(&dev->intf->dev, + "Couldn't submit interrupt_out_urb %d\n", retval); goto unlock_exit; } retval = bytes_to_write; |