From: Shyam Sunder Reddy Padira Date: Sat, 18 Apr 2026 17:09:06 +0000 (+0530) Subject: staging: rtl8723bs: os_dep: remove redundant else in rtw_dev_unload X-Git-Tag: v7.2-rc1~66^2~132 X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=aa107ae83d9f8bdacc5888b3137e04f18970ae6b;p=thirdparty%2Fkernel%2Flinux.git staging: rtl8723bs: os_dep: remove redundant else in rtw_dev_unload Remove the unnecessary else block following a break statment to simplify the control flow and improve code readability. Signed-off-by: Shyam Sunder Reddy Padira Reviewed-by: Luka Gejak Link: https://patch.msgid.link/20260418170908.16257-1-shyamsunderreddypadira@gmail.com Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/rtl8723bs/os_dep/os_intfs.c b/drivers/staging/rtl8723bs/os_dep/os_intfs.c index d55a68b27096b..b80f1d03ed5ae 100644 --- a/drivers/staging/rtl8723bs/os_dep/os_intfs.c +++ b/drivers/staging/rtl8723bs/os_dep/os_intfs.c @@ -989,12 +989,10 @@ void rtw_dev_unload(struct adapter *padapter) rtw_stop_drv_threads(padapter); while (atomic_read(&pcmdpriv->cmdthd_running)) { - if (cnt > 5) { + if (cnt > 5) break; - } else { - cnt++; - msleep(10); - } + cnt++; + msleep(10); } /* check the status of IPS */