Browse Source

usbnet: mcs7830: apply usbnet_link_change

This patch uses the introduced usbnet_link_change() to handle
link change.

Signed-off-by: Ming Lei <ming.lei@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Ming Lei 12 years ago
parent
commit
4be74c130d
1 changed files with 1 additions and 4 deletions
  1. 1 4
      drivers/net/usb/mcs7830.c

+ 1 - 4
drivers/net/usb/mcs7830.c

@@ -576,10 +576,7 @@ static void mcs7830_status(struct usbnet *dev, struct urb *urb)
 		 */
 		if (data->link_counter > 20) {
 			data->link_counter = 0;
-			if (link)
-				netif_carrier_on(dev->net);
-			else
-				netif_carrier_off(dev->net);
+			usbnet_link_change(dev, link, 0);
 			netdev_dbg(dev->net, "Link Status is: %d\n", link);
 		}
 	} else