Re: [PATCH v2] iavf: Remove useless else if

From: Jakub Kicinski
Date: Wed May 24 2023 - 11:52:08 EST


On Wed, 24 May 2023 18:02:03 +0800 Jiapeng Chong wrote:
> The assignment of the else and if branches is the same, so the if else
> here is redundant, so we remove it.
>
> ./drivers/net/ethernet/intel/iavf/iavf_main.c:2203:6-8: WARNING: possible condition with no effect (if == else).
>
> Reported-by: Abaci Robot <abaci@xxxxxxxxxxxxxxxxx>
> Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=5255
> Signed-off-by: Jiapeng Chong <jiapeng.chong@xxxxxxxxxxxxxxxxx>

Looking thru git history most of the patches you send for this check
are converting perfectly valid code. Please change the check to ignore

if (cond)
/*A*/
else if (cond2)
/*B*/
else
/*B*/
--
pw-bot: reject