|
@@ -97,8 +97,9 @@ static void tx_complete(struct urb *req)
|
|
struct sk_buff *skb = req->context;
|
|
struct sk_buff *skb = req->context;
|
|
struct net_device *dev = skb->dev;
|
|
struct net_device *dev = skb->dev;
|
|
struct usbpn_dev *pnd = netdev_priv(dev);
|
|
struct usbpn_dev *pnd = netdev_priv(dev);
|
|
|
|
+ int status = req->status;
|
|
|
|
|
|
- switch (req->status) {
|
|
|
|
|
|
+ switch (status) {
|
|
case 0:
|
|
case 0:
|
|
dev->stats.tx_bytes += skb->len;
|
|
dev->stats.tx_bytes += skb->len;
|
|
break;
|
|
break;
|
|
@@ -109,7 +110,7 @@ static void tx_complete(struct urb *req)
|
|
dev->stats.tx_aborted_errors++;
|
|
dev->stats.tx_aborted_errors++;
|
|
default:
|
|
default:
|
|
dev->stats.tx_errors++;
|
|
dev->stats.tx_errors++;
|
|
- dev_dbg(&dev->dev, "TX error (%d)\n", req->status);
|
|
|
|
|
|
+ dev_dbg(&dev->dev, "TX error (%d)\n", status);
|
|
}
|
|
}
|
|
dev->stats.tx_packets++;
|
|
dev->stats.tx_packets++;
|
|
|
|
|
|
@@ -150,8 +151,9 @@ static void rx_complete(struct urb *req)
|
|
struct page *page = virt_to_page(req->transfer_buffer);
|
|
struct page *page = virt_to_page(req->transfer_buffer);
|
|
struct sk_buff *skb;
|
|
struct sk_buff *skb;
|
|
unsigned long flags;
|
|
unsigned long flags;
|
|
|
|
+ int status = req->status;
|
|
|
|
|
|
- switch (req->status) {
|
|
|
|
|
|
+ switch (status) {
|
|
case 0:
|
|
case 0:
|
|
spin_lock_irqsave(&pnd->rx_lock, flags);
|
|
spin_lock_irqsave(&pnd->rx_lock, flags);
|
|
skb = pnd->rx_skb;
|
|
skb = pnd->rx_skb;
|