00c4141cc504337bea02b3c194707b952af0e480
[openwrt/staging/mans0n.git] /
1 From a7f4a80c0070b673d4a4ce94b99979ea6d0c6296 Mon Sep 17 00:00:00 2001
2 From: Arend Van Spriel <arend.vanspriel@broadcom.com>
3 Date: Tue, 20 Feb 2018 00:14:21 +0100
4 Subject: [PATCH] brcmfmac: usb: call brcmf_usb_up() during brcmf_bus_preinit()
5
6 By calling brcmf_usb_up() during brcmf_bus_preinit() it does not need
7 to be called in brcmf_usb_bus_setup().
8
9 Reviewed-by: Hante Meuleman <hante.meuleman@broadcom.com>
10 Reviewed-by: Pieter-Paul Giesberts <pieter-paul.giesberts@broadcom.com>
11 Reviewed-by: Franky Lin <franky.lin@broadcom.com>
12 Signed-off-by: Arend van Spriel <arend.vanspriel@broadcom.com>
13 Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
14 ---
15 drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c | 7 ++-----
16 1 file changed, 2 insertions(+), 5 deletions(-)
17
18 --- a/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c
19 +++ b/drivers/net/wireless/broadcom/brcm80211/brcmfmac/usb.c
20 @@ -1146,8 +1146,9 @@ static int brcmf_usb_get_fwname(struct d
21 }
22
23 static const struct brcmf_bus_ops brcmf_usb_bus_ops = {
24 - .txdata = brcmf_usb_tx,
25 + .preinit = brcmf_usb_up,
26 .stop = brcmf_usb_down,
27 + .txdata = brcmf_usb_tx,
28 .txctl = brcmf_usb_tx_ctlpkt,
29 .rxctl = brcmf_usb_rx_ctlpkt,
30 .wowl_config = brcmf_usb_wowl_config,
31 @@ -1165,10 +1166,6 @@ static int brcmf_usb_bus_setup(struct br
32 return ret;
33 }
34
35 - ret = brcmf_usb_up(devinfo->dev);
36 - if (ret)
37 - goto fail;
38 -
39 ret = brcmf_bus_started(devinfo->dev);
40 if (ret)
41 goto fail;