diff options
| -rw-r--r-- | drivers/net/usb/cdc_ncm.c | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/drivers/net/usb/cdc_ncm.c b/drivers/net/usb/cdc_ncm.c index be927964375b..86ba30ba35e8 100644 --- a/drivers/net/usb/cdc_ncm.c +++ b/drivers/net/usb/cdc_ncm.c | |||
| @@ -988,8 +988,6 @@ EXPORT_SYMBOL_GPL(cdc_ncm_select_altsetting); | |||
| 988 | 988 | ||
| 989 | static int cdc_ncm_bind(struct usbnet *dev, struct usb_interface *intf) | 989 | static int cdc_ncm_bind(struct usbnet *dev, struct usb_interface *intf) |
| 990 | { | 990 | { |
| 991 | int ret; | ||
| 992 | |||
| 993 | /* MBIM backwards compatible function? */ | 991 | /* MBIM backwards compatible function? */ |
| 994 | if (cdc_ncm_select_altsetting(intf) != CDC_NCM_COMM_ALTSETTING_NCM) | 992 | if (cdc_ncm_select_altsetting(intf) != CDC_NCM_COMM_ALTSETTING_NCM) |
| 995 | return -ENODEV; | 993 | return -ENODEV; |
| @@ -998,16 +996,7 @@ static int cdc_ncm_bind(struct usbnet *dev, struct usb_interface *intf) | |||
| 998 | * Additionally, generic NCM devices are assumed to accept arbitrarily | 996 | * Additionally, generic NCM devices are assumed to accept arbitrarily |
| 999 | * placed NDP. | 997 | * placed NDP. |
| 1000 | */ | 998 | */ |
| 1001 | ret = cdc_ncm_bind_common(dev, intf, CDC_NCM_DATA_ALTSETTING_NCM, 0); | 999 | return cdc_ncm_bind_common(dev, intf, CDC_NCM_DATA_ALTSETTING_NCM, 0); |
| 1002 | |||
| 1003 | /* | ||
| 1004 | * We should get an event when network connection is "connected" or | ||
| 1005 | * "disconnected". Set network connection in "disconnected" state | ||
| 1006 | * (carrier is OFF) during attach, so the IP network stack does not | ||
| 1007 | * start IPv6 negotiation and more. | ||
| 1008 | */ | ||
| 1009 | usbnet_link_change(dev, 0, 0); | ||
| 1010 | return ret; | ||
| 1011 | } | 1000 | } |
| 1012 | 1001 | ||
| 1013 | static void cdc_ncm_align_tail(struct sk_buff *skb, size_t modulus, size_t remainder, size_t max) | 1002 | static void cdc_ncm_align_tail(struct sk_buff *skb, size_t modulus, size_t remainder, size_t max) |
| @@ -1590,7 +1579,8 @@ static void cdc_ncm_status(struct usbnet *dev, struct urb *urb) | |||
| 1590 | 1579 | ||
| 1591 | static const struct driver_info cdc_ncm_info = { | 1580 | static const struct driver_info cdc_ncm_info = { |
| 1592 | .description = "CDC NCM", | 1581 | .description = "CDC NCM", |
| 1593 | .flags = FLAG_POINTTOPOINT | FLAG_NO_SETINT | FLAG_MULTI_PACKET, | 1582 | .flags = FLAG_POINTTOPOINT | FLAG_NO_SETINT | FLAG_MULTI_PACKET |
| 1583 | | FLAG_LINK_INTR, | ||
| 1594 | .bind = cdc_ncm_bind, | 1584 | .bind = cdc_ncm_bind, |
| 1595 | .unbind = cdc_ncm_unbind, | 1585 | .unbind = cdc_ncm_unbind, |
| 1596 | .manage_power = usbnet_manage_power, | 1586 | .manage_power = usbnet_manage_power, |
| @@ -1603,7 +1593,7 @@ static const struct driver_info cdc_ncm_info = { | |||
| 1603 | static const struct driver_info wwan_info = { | 1593 | static const struct driver_info wwan_info = { |
| 1604 | .description = "Mobile Broadband Network Device", | 1594 | .description = "Mobile Broadband Network Device", |
| 1605 | .flags = FLAG_POINTTOPOINT | FLAG_NO_SETINT | FLAG_MULTI_PACKET | 1595 | .flags = FLAG_POINTTOPOINT | FLAG_NO_SETINT | FLAG_MULTI_PACKET |
| 1606 | | FLAG_WWAN, | 1596 | | FLAG_LINK_INTR | FLAG_WWAN, |
| 1607 | .bind = cdc_ncm_bind, | 1597 | .bind = cdc_ncm_bind, |
| 1608 | .unbind = cdc_ncm_unbind, | 1598 | .unbind = cdc_ncm_unbind, |
| 1609 | .manage_power = usbnet_manage_power, | 1599 | .manage_power = usbnet_manage_power, |
| @@ -1616,7 +1606,7 @@ static const struct driver_info wwan_info = { | |||
| 1616 | static const struct driver_info wwan_noarp_info = { | 1606 | static const struct driver_info wwan_noarp_info = { |
| 1617 | .description = "Mobile Broadband Network Device (NO ARP)", | 1607 | .description = "Mobile Broadband Network Device (NO ARP)", |
| 1618 | .flags = FLAG_POINTTOPOINT | FLAG_NO_SETINT | FLAG_MULTI_PACKET | 1608 | .flags = FLAG_POINTTOPOINT | FLAG_NO_SETINT | FLAG_MULTI_PACKET |
| 1619 | | FLAG_WWAN | FLAG_NOARP, | 1609 | | FLAG_LINK_INTR | FLAG_WWAN | FLAG_NOARP, |
| 1620 | .bind = cdc_ncm_bind, | 1610 | .bind = cdc_ncm_bind, |
| 1621 | .unbind = cdc_ncm_unbind, | 1611 | .unbind = cdc_ncm_unbind, |
| 1622 | .manage_power = usbnet_manage_power, | 1612 | .manage_power = usbnet_manage_power, |
