Commit 04d948a9 authored by Bjørn Mork's avatar Bjørn Mork Committed by David S. Miller

net: cdc_mbim: manage_power should always set needs_remote_wakeup

Reported-by: default avatarOliver Neukum <oneukum@suse.de>
Signed-off-by: default avatarBjørn Mork <bjorn@mork.no>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 96635fbd
......@@ -44,13 +44,11 @@ static int cdc_mbim_manage_power(struct usbnet *dev, int on)
if ((on && atomic_add_return(1, &info->pmcount) == 1) || (!on && atomic_dec_and_test(&info->pmcount))) {
/* need autopm_get/put here to ensure the usbcore sees the new value */
rv = usb_autopm_get_interface(dev->intf);
if (rv < 0)
goto err;
dev->intf->needs_remote_wakeup = on;
if (!rv)
usb_autopm_put_interface(dev->intf);
}
err:
return rv;
return 0;
}
static int cdc_mbim_wdm_manage_power(struct usb_interface *intf, int status)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment