]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
net: usb: rtl8150: remove set but not used variable 'rx_stat'
authorYue Haibing <yuehaibing@huawei.com>
Fri, 18 Jan 2019 02:06:49 +0000 (02:06 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sat, 19 Jan 2019 18:29:56 +0000 (10:29 -0800)
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/net/usb/rtl8150.c: In function 'read_bulk_callback':
drivers/net/usb/rtl8150.c:391:6: warning:
 variable 'rx_stat' set but not used [-Wunused-but-set-variable]

Signed-off-by: Yue Haibing <yuehaibing@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/usb/rtl8150.c

index 80373a9171dd2d0e06a19cb21aeb37934bea4b37..3f145e4c6c083f2a2523499fa2f47ef175619908 100644 (file)
@@ -388,7 +388,6 @@ static void read_bulk_callback(struct urb *urb)
        unsigned pkt_len, res;
        struct sk_buff *skb;
        struct net_device *netdev;
-       u16 rx_stat;
        int status = urb->status;
        int result;
        unsigned long flags;
@@ -424,7 +423,6 @@ static void read_bulk_callback(struct urb *urb)
                goto goon;
 
        res = urb->actual_length;
-       rx_stat = le16_to_cpu(*(__le16 *)(urb->transfer_buffer + res - 4));
        pkt_len = res - 4;
 
        skb_put(dev->rx_skb, pkt_len);