diff options
author | hayeswang <hayeswang@realtek.com> | 2014-03-06 02:07:17 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-03-06 13:15:12 -0500 |
commit | d104eafa643e393c224c536744bcebef30cedda1 (patch) | |
tree | 54b92d162bffa6f0c898f962d0c2f8a3f0e5ba61 /drivers/net/usb | |
parent | db8515eff338f2f372b46d24385c359d4e411b2d (diff) |
r8152: replace tp->netdev with netdev
Replace some tp->netdev with netdev.
Signed-off-by: Hayes Wang <hayeswang@realtek.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/usb')
-rw-r--r-- | drivers/net/usb/r8152.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/usb/r8152.c b/drivers/net/usb/r8152.c index c8bad6283fa9..151398b7a5be 100644 --- a/drivers/net/usb/r8152.c +++ b/drivers/net/usb/r8152.c | |||
@@ -1037,6 +1037,7 @@ static void read_bulk_callback(struct urb *urb) | |||
1037 | static void write_bulk_callback(struct urb *urb) | 1037 | static void write_bulk_callback(struct urb *urb) |
1038 | { | 1038 | { |
1039 | struct net_device_stats *stats; | 1039 | struct net_device_stats *stats; |
1040 | struct net_device *netdev; | ||
1040 | unsigned long flags; | 1041 | unsigned long flags; |
1041 | struct tx_agg *agg; | 1042 | struct tx_agg *agg; |
1042 | struct r8152 *tp; | 1043 | struct r8152 *tp; |
@@ -1050,10 +1051,11 @@ static void write_bulk_callback(struct urb *urb) | |||
1050 | if (!tp) | 1051 | if (!tp) |
1051 | return; | 1052 | return; |
1052 | 1053 | ||
1053 | stats = rtl8152_get_stats(tp->netdev); | 1054 | netdev = tp->netdev; |
1055 | stats = rtl8152_get_stats(netdev); | ||
1054 | if (status) { | 1056 | if (status) { |
1055 | if (net_ratelimit()) | 1057 | if (net_ratelimit()) |
1056 | netdev_warn(tp->netdev, "Tx status %d\n", status); | 1058 | netdev_warn(netdev, "Tx status %d\n", status); |
1057 | stats->tx_errors += agg->skb_num; | 1059 | stats->tx_errors += agg->skb_num; |
1058 | } else { | 1060 | } else { |
1059 | stats->tx_packets += agg->skb_num; | 1061 | stats->tx_packets += agg->skb_num; |
@@ -1066,7 +1068,7 @@ static void write_bulk_callback(struct urb *urb) | |||
1066 | 1068 | ||
1067 | usb_autopm_put_interface_async(tp->intf); | 1069 | usb_autopm_put_interface_async(tp->intf); |
1068 | 1070 | ||
1069 | if (!netif_carrier_ok(tp->netdev)) | 1071 | if (!netif_carrier_ok(netdev)) |
1070 | return; | 1072 | return; |
1071 | 1073 | ||
1072 | if (!test_bit(WORK_ENABLE, &tp->flags)) | 1074 | if (!test_bit(WORK_ENABLE, &tp->flags)) |