Commit 32279240 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman

USB: ks959-sir.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: Samuel Ortiz <samuel@sortiz.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 6f0d27ff
...@@ -247,7 +247,8 @@ static void ks959_speed_irq(struct urb *urb) ...@@ -247,7 +247,8 @@ static void ks959_speed_irq(struct urb *urb)
{ {
/* unlink, shutdown, unplug, other nasties */ /* unlink, shutdown, unplug, other nasties */
if (urb->status != 0) { if (urb->status != 0) {
err("ks959_speed_irq: urb asynchronously failed - %d", dev_err(&urb->dev->dev,
"ks959_speed_irq: urb asynchronously failed - %d\n",
urb->status); urb->status);
} }
} }
...@@ -332,13 +333,15 @@ static void ks959_send_irq(struct urb *urb) ...@@ -332,13 +333,15 @@ static void ks959_send_irq(struct urb *urb)
/* in process of stopping, just drop data */ /* in process of stopping, just drop data */
if (!netif_running(kingsun->netdev)) { if (!netif_running(kingsun->netdev)) {
err("ks959_send_irq: Network not running!"); dev_err(&kingsun->usbdev->dev,
"ks959_send_irq: Network not running!\n");
return; return;
} }
/* unlink, shutdown, unplug, other nasties */ /* unlink, shutdown, unplug, other nasties */
if (urb->status != 0) { if (urb->status != 0) {
err("ks959_send_irq: urb asynchronously failed - %d", dev_err(&kingsun->usbdev->dev,
"ks959_send_irq: urb asynchronously failed - %d\n",
urb->status); urb->status);
return; return;
} }
...@@ -358,7 +361,8 @@ static void ks959_send_irq(struct urb *urb) ...@@ -358,7 +361,8 @@ static void ks959_send_irq(struct urb *urb)
if (kingsun->tx_buf_clear_used > 0) { if (kingsun->tx_buf_clear_used > 0) {
/* There is more data to be sent */ /* There is more data to be sent */
if ((ret = ks959_submit_tx_fragment(kingsun)) != 0) { if ((ret = ks959_submit_tx_fragment(kingsun)) != 0) {
err("ks959_send_irq: failed tx_urb submit: %d", dev_err(&kingsun->usbdev->dev,
"ks959_send_irq: failed tx_urb submit: %d\n",
ret); ret);
switch (ret) { switch (ret) {
case -ENODEV: case -ENODEV:
...@@ -407,7 +411,8 @@ static netdev_tx_t ks959_hard_xmit(struct sk_buff *skb, ...@@ -407,7 +411,8 @@ static netdev_tx_t ks959_hard_xmit(struct sk_buff *skb,
kingsun->tx_buf_clear_used = wraplen; kingsun->tx_buf_clear_used = wraplen;
if ((ret = ks959_submit_tx_fragment(kingsun)) != 0) { if ((ret = ks959_submit_tx_fragment(kingsun)) != 0) {
err("ks959_hard_xmit: failed tx_urb submit: %d", ret); dev_err(&kingsun->usbdev->dev,
"ks959_hard_xmit: failed tx_urb submit: %d\n", ret);
switch (ret) { switch (ret) {
case -ENODEV: case -ENODEV:
case -EPIPE: case -EPIPE:
...@@ -442,7 +447,8 @@ static void ks959_rcv_irq(struct urb *urb) ...@@ -442,7 +447,8 @@ static void ks959_rcv_irq(struct urb *urb)
/* unlink, shutdown, unplug, other nasties */ /* unlink, shutdown, unplug, other nasties */
if (urb->status != 0) { if (urb->status != 0) {
err("kingsun_rcv_irq: urb asynchronously failed - %d", dev_err(&kingsun->usbdev->dev,
"kingsun_rcv_irq: urb asynchronously failed - %d\n",
urb->status); urb->status);
kingsun->receiving = 0; kingsun->receiving = 0;
return; return;
...@@ -536,7 +542,7 @@ static int ks959_net_open(struct net_device *netdev) ...@@ -536,7 +542,7 @@ static int ks959_net_open(struct net_device *netdev)
sprintf(hwname, "usb#%d", kingsun->usbdev->devnum); sprintf(hwname, "usb#%d", kingsun->usbdev->devnum);
kingsun->irlap = irlap_open(netdev, &kingsun->qos, hwname); kingsun->irlap = irlap_open(netdev, &kingsun->qos, hwname);
if (!kingsun->irlap) { if (!kingsun->irlap) {
err("ks959-sir: irlap_open failed"); dev_err(&kingsun->usbdev->dev, "irlap_open failed\n");
goto free_mem; goto free_mem;
} }
...@@ -549,7 +555,8 @@ static int ks959_net_open(struct net_device *netdev) ...@@ -549,7 +555,8 @@ static int ks959_net_open(struct net_device *netdev)
kingsun->rx_urb->status = 0; kingsun->rx_urb->status = 0;
err = usb_submit_urb(kingsun->rx_urb, GFP_KERNEL); err = usb_submit_urb(kingsun->rx_urb, GFP_KERNEL);
if (err) { if (err) {
err("ks959-sir: first urb-submit failed: %d", err); dev_err(&kingsun->usbdev->dev,
"first urb-submit failed: %d\n", err);
goto close_irlap; goto close_irlap;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment