From c9178b2dfb1c6d04daffd226f9abf501e8ce85d4 Mon Sep 17 00:00:00 2001 From: Anan Jaser Date: Wed, 23 Sep 2020 00:33:22 +0400 Subject: [PATCH] wireless: bcmdhd4361: fix overlapping comparisons drivers/net/wireless/bcmdhd4361/wl_android.c:7107:22: error: overlapping comparisons always evaluate to false [-Werror,-Wtautological-overlap-compare] if ((adps_mode < 0) && (1 < adps_mode)) { Change-Id: Ic52de37d5048341a0851b011463522b4865d119a --- drivers/net/wireless/bcmdhd4361/wl_android.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/wireless/bcmdhd4361/wl_android.c b/drivers/net/wireless/bcmdhd4361/wl_android.c index 27ce4d5bf0d8..a63c1a0ec615 100644 --- a/drivers/net/wireless/bcmdhd4361/wl_android.c +++ b/drivers/net/wireless/bcmdhd4361/wl_android.c @@ -7104,7 +7104,7 @@ wl_android_set_adps_mode(struct net_device *dev, const char* string_num) adps_mode = bcm_atoi(string_num); WL_ERR(("%s: SET_ADPS %d\n", __FUNCTION__, adps_mode)); - if ((adps_mode < 0) && (1 < adps_mode)) { + if ((adps_mode < 0) || (1 < adps_mode)) { WL_ERR(("%s: Invalid value %d.\n", __FUNCTION__, adps_mode)); return -EINVAL; } -- 2.20.1