summaryrefslogtreecommitdiff
path: root/drivers/net
diff options
context:
space:
mode:
authorSeung-Woo Kim <sw0312.kim@samsung.com>2017-01-17 13:22:22 +0900
committerSeung-Woo Kim <sw0312.kim@samsung.com>2017-01-16 22:09:52 -0800
commit54df3e5cb316dc40094213d5cc79b3f63cd410d5 (patch)
treee1d9385ca99f7462c2036ca19557093af56abc9e /drivers/net
parent4b6d05be4499f141ca7770262a9f30da8d365798 (diff)
net: bcm4358: fix not to check same value in macro
When BCMBUSTYPE is not defined, then BUSTYPE(bustype) is just bustype. So comparing bustype and BUSTYPE(bustype) is not necessary. This patch removes following build warning with gcc 6. drivers/net/wireless/bcmdhd4358/siutils.c: In function 'si_doattach': drivers/net/wireless/bcmdhd4358/siutils.c:512:14: warning: self-comparison always evaluates to false [-Wtautological-compare] if (bustype != BUSTYPE(bustype)) { ^~ Change-Id: I1cac3dd31bcb86983469830013a1093ed9ceaa89 Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/wireless/bcmdhd4358/siutils.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/wireless/bcmdhd4358/siutils.c b/drivers/net/wireless/bcmdhd4358/siutils.c
index dc265f2fa1ea..1e8172ab2221 100644
--- a/drivers/net/wireless/bcmdhd4358/siutils.c
+++ b/drivers/net/wireless/bcmdhd4358/siutils.c
@@ -509,11 +509,13 @@ si_doattach(si_info_t *sii, uint devid, osl_t *osh, void *regs,
}
sih->bustype = bustype;
+#ifdef BCMBUSTYPE
if (bustype != BUSTYPE(bustype)) {
SI_ERROR(("si_doattach: bus type %d does not match configured bus type %d\n",
bustype, BUSTYPE(bustype)));
return NULL;
}
+#endif
/* bus/core/clk setup for register access */
if (!si_buscore_prep(sii, bustype, devid, sdh)) {