MLK-17443 wireless: bcmdhd: fix build warning
authorGao Pan <pandy.gao@nxp.com>
Tue, 23 Jan 2018 06:15:37 +0000 (14:15 +0800)
committerNitin Garg <nitin.garg@nxp.com>
Tue, 20 Mar 2018 19:53:26 +0000 (14:53 -0500)
case1: statement "if (bustype != BUSTYPE(bustype))"
equals "if (bustype != bustype)" when BCMBUSTYPE is
not defined. Some compilers treat it as a build warning.

case2: fix misleadingly indented of dhd_os_sdunlock(dhdp)

Signed-off-by: Gao Pan <pandy.gao@nxp.com>
Tested-by: Peng Fan <peng.fan@nxp.com>
drivers/net/wireless/bcmdhd/dhd_sdio.c
drivers/net/wireless/bcmdhd/siutils.c

index 425fbba..61a2d9a 100644 (file)
@@ -8146,7 +8146,7 @@ dhd_bus_devreset(dhd_pub_t *dhdp, uint8 flag)
                        } else
                                bcmerror = BCME_SDIO_ERROR;
 
-                               dhd_os_sdunlock(dhdp);
+                       dhd_os_sdunlock(dhdp);
                } else {
                        bcmerror = BCME_SDIO_ERROR;
                        DHD_INFO(("%s called when dongle is not in reset\n",
index edcd1c1..d6ff576 100644 (file)
@@ -400,11 +400,6 @@ si_doattach(si_info_t *sii, uint devid, osl_t *osh, void *regs,
        }
 
        sih->bustype = bustype;
-       if (bustype != BUSTYPE(bustype)) {
-               SI_ERROR(("si_doattach: bus type %d does not match configured bus type %d\n",
-                       bustype, BUSTYPE(bustype)));
-               return NULL;
-       }
 
        /* bus/core/clk setup for register access */
        if (!si_buscore_prep(sii, bustype, devid, sdh)) {