Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp5957760rwd; Wed, 24 May 2023 08:59:12 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5Mh8AxyxyBY+IqFJO2i7fTUNm+wzHznSLBFNF5ESqqNlH9IuyH3S1vocM+rCdxQET5rVP/ X-Received: by 2002:a05:6a21:1088:b0:103:ef39:a829 with SMTP id nl8-20020a056a21108800b00103ef39a829mr14398046pzb.26.1684943951785; Wed, 24 May 2023 08:59:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684943951; cv=none; d=google.com; s=arc-20160816; b=LV0Xqy5hOtFXAve4ZHUnzAQvNEtxVcrBJW3wnZn24LeFzaKEIE2Gk72vAEHj35HQ1F STWw5fsbhGAo2UYK3h0bsaf0frQWCAp9P5LS6nw6JSy0ohcTBWrwn7Dv9tUV0WxCjkEo 9J+BWRFHE7RNYLVxdAVIuP8FCIGccBPRBRDxCdqx77FpoolMWnwkgP1fLlgSc0foKD0Z 4CRJ3Bc5IdExRm8eUhE5JP/jRcoSJyzYLBXw8qBxybQMi92nEGTmGfuB+m2LCuqlHmj2 Qpknwuop+afRauAkYem82tWhmvJPs60g76GAkXtVCi5a7xIYKYOvBSNIjWqEAZabG/FQ rfCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=tz1/pNZHR/jVc4nqglLdrx5et5Bifwwwx4ktEu7+FV4=; b=JNTWY1GiDVyTl96bUiUshDdefedWKVBCIhvqIQZw0Ulm7CtmENAyX5W6lnv7FHPHE8 wRH1pFLLGRk9swM6h85/jwQbomWxd2OzDMO8mBjuiGuq1GI6q2nmG+WQJk+tczUhIfKA krzBZ1i0HvyXis/Krumty6Wz0sMUvqnJcLKBMLJBMlaSHsNQcRheAKrGZzBQthYcjV7I kyk9+2NeiqWVL5/+YK3NkYf1D5A/6t5MxXOXmVDhbw3th/Y30Zmok1SGjoF5RdOEJ6qc jXvkC28RPs0KPTbubuzfKqqXJQo4IZsHQKI/vdP7k0FwFYYDHbfffQZp9q7idgbv4xWQ MEnw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=oDrl9cg8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s15-20020a63af4f000000b0050bfc85d989si2415890pgo.154.2023.05.24.08.58.58; Wed, 24 May 2023 08:59:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=oDrl9cg8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237247AbjEXPwF (ORCPT + 99 others); Wed, 24 May 2023 11:52:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49254 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237197AbjEXPwE (ORCPT ); Wed, 24 May 2023 11:52:04 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2C3B4119 for ; Wed, 24 May 2023 08:52:00 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id A76FE6326E for ; Wed, 24 May 2023 15:51:59 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9A7C3C4339C; Wed, 24 May 2023 15:51:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684943519; bh=XWnQo/qdI9QS7Vl/TkbgebkpbwZYMFbbX7jgoE+jOEU=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=oDrl9cg8f/SvTELCMV33pKctM2szKyacR/eO0Q1jQWAeWTh1hfYZQswJbhdxGIMUC 0MSuSHsyWEV9Ug+dOST1xVUsLbbw02/1PSnW21LIURe5MvLfnGO5G9O3G4nWOwwfUg EYIUQpTzudn4A2vwvmDTC0nEFbHx0pcVCueQ6AE44lvgUEkhP3Ah6SfexPa9+rFgob c5DVRTFSSQTzSeyyAQZ7wXnt8BXSzxYSY/9fr96DZo3t0RaX3BZoSJ3vfpa5viqWHS p1tvAPVGKzt6wZnc3DALBTJvuA5CH8sRJGc01fmyWGO4iv37LtAu6cg1i//5ymOr72 JtPRTaJ+jTKXQ== Date: Wed, 24 May 2023 08:51:57 -0700 From: Jakub Kicinski To: Jiapeng Chong Cc: jesse.brandeburg@intel.com, anthony.l.nguyen@intel.com, davem@davemloft.net, edumazet@google.com, pabeni@redhat.com, intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Abaci Robot Subject: Re: [PATCH v2] iavf: Remove useless else if Message-ID: <20230524085157.59aeebea@kernel.org> In-Reply-To: <20230524100203.28645-1-jiapeng.chong@linux.alibaba.com> References: <20230524100203.28645-1-jiapeng.chong@linux.alibaba.com> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 > Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=5255 > Signed-off-by: Jiapeng Chong 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