usbnet: sierra: apply usbnet_link_change
Use usbnet_link_change to handle link change centrally. Signed-off-by: Ming Lei <ming.lei@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
c10b1710e2
commit
9ef2c44160
@@ -413,11 +413,10 @@ static void sierra_net_handle_lsi(struct usbnet *dev, char *data,
|
|||||||
if (link_up) {
|
if (link_up) {
|
||||||
sierra_net_set_ctx_index(priv, hh->msgspecific.byte);
|
sierra_net_set_ctx_index(priv, hh->msgspecific.byte);
|
||||||
priv->link_up = 1;
|
priv->link_up = 1;
|
||||||
netif_carrier_on(dev->net);
|
|
||||||
} else {
|
} else {
|
||||||
priv->link_up = 0;
|
priv->link_up = 0;
|
||||||
netif_carrier_off(dev->net);
|
|
||||||
}
|
}
|
||||||
|
usbnet_link_change(dev, link_up, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void sierra_net_dosync(struct usbnet *dev)
|
static void sierra_net_dosync(struct usbnet *dev)
|
||||||
|
Reference in New Issue
Block a user