mwifiex: replace netif_carrier_on/off by netif_device_attach/dettach
authorGanapathi Bhat <gbhat@marvell.com>
Wed, 2 Aug 2017 20:04:46 +0000 (01:34 +0530)
committerKalle Valo <kvalo@codeaurora.org>
Tue, 8 Aug 2017 11:47:06 +0000 (14:47 +0300)
commitbd69cddcdf47919a8f7145779c5da2db3c543bca
treef866df64391856b64c7e4512ce0fc464b9d5a7a4
parent80a88ecf3bccb129146e00e429a4b8a90fb89f11
mwifiex: replace netif_carrier_on/off by netif_device_attach/dettach

Driver is doing netif_carrier_off during suspend, which will set
the IFF_LOWER_UP flag to 0. As a result certain applications
will think this as a real carrier down and behave accordingly.
This will cause issues like loss of IP address, for example. To
fix this use netif_device_dettach during suspend.

Fixes: 0026b32d723e ('mwifiex: fix Tx timeout issue during suspend test')

Signed-off-by: Cathy Luo <cluo@marvell.com>
Signed-off-by: Ganapathi Bhat <gbhat@marvell.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
drivers/net/wireless/marvell/mwifiex/cfg80211.c