Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

staging: r8188eu: remove useless if else

Eliminate the follow coccicheck warning:

./drivers/staging/r8188eu/hal/usb_halinit.c:1105:3-5: WARNING: possible
condition with no effect (if == else).

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Link: https://lore.kernel.org/r/20220211080322.80388-1-jiapeng.chong@linux.alibaba.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Jiapeng Chong and committed by
Greg Kroah-Hartman
5d2ed511 3b335cf1

+1 -5
+1 -5
drivers/staging/r8188eu/hal/usb_halinit.c
··· 1102 1102 /* enable update TSF */ 1103 1103 rtw_write8(Adapter, REG_BCN_CTRL, rtw_read8(Adapter, REG_BCN_CTRL) & (~BIT(4))); 1104 1104 } 1105 - if ((pmlmeinfo->state & 0x03) == WIFI_FW_AP_STATE) { 1106 - rtw_write32(Adapter, REG_RCR, rtw_read32(Adapter, REG_RCR) | RCR_CBSSID_BCN); 1107 - } else { 1108 - rtw_write32(Adapter, REG_RCR, rtw_read32(Adapter, REG_RCR) | RCR_CBSSID_BCN); 1109 - } 1105 + rtw_write32(Adapter, REG_RCR, rtw_read32(Adapter, REG_RCR) | RCR_CBSSID_BCN); 1110 1106 } 1111 1107 break; 1112 1108 case HW_VAR_MLME_JOIN: