Received: by 2002:a6b:fb09:0:0:0:0:0 with SMTP id h9csp1984780iog; Sun, 26 Jun 2022 03:45:51 -0700 (PDT) X-Google-Smtp-Source: AGRyM1u1QLtlovQgB4+3mFFqQNuLDq6ujvBDSxz745Aj0bwmN0qzTAFjJdTpZRBsrccddRasv3af X-Received: by 2002:a17:90a:5502:b0:1ec:788a:2d13 with SMTP id b2-20020a17090a550200b001ec788a2d13mr14089211pji.182.1656240350769; Sun, 26 Jun 2022 03:45:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1656240350; cv=none; d=google.com; s=arc-20160816; b=PfXlWJ0AKm0ZYJcQzlwe7/vUA7gcWObJNEZNhwCfcdGv3cWiln2yMKo9b8sAu4nVdq b4YKagJRl6ugn5f3i8bXIIZ0YwisGJKowKrbiDfw4cNSsVTS7lPn8c7h6ryjigFbPypW 4ChwacjEsNpa/dGQaWWT0a/tyxdHkNaGNGaeozND2oSK972R07wVGzVHXkV8CSSiHGFe K2L873mfcNSEfHXQbgpUel/EjLCudLvPPln8Wzy27/IhIW1ePT4P4iMXu6NHq0j1aoJq lzz/x2Lm9WrlJELvXH4zeaTA3z403+KMWJgFFg4Gv6aJJ9EtS9I0awKruwAGU+tz/Biu avSw== 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 :message-id:date:subject:cc:to:from:dkim-signature; bh=CT9UzjAprHUqV7ZTg5rA+EnKneUfvjzMy7Q3wVldT2o=; b=lfm79ZZE+FQgmQPjHvwcZslaeJfraGRnfcqYvMvjKZV5iAQ0Sl4Bi+ODaPzqunhIEN mz2PL8X+p0vSYn4qOGuVFM4AtXUoZKLQjpLFBrf+V2wx1JN/hYEzm4I31O77bPNd9qTQ I2ZIRxfU4EdF4PKyBtxuSGbv4UIEFoF8ZQqolvtxlG4yMm86Dt7DpouidHpl8UegNEWX JqQoqrw7jVlGi1mhbTuzPHkeoeAdVW9lmM+3ps9XrFr3MGJIkco+SiCm8dPmaJt0VtcR V8YxWAtyZzjcTDhdxIPbkhapJQbUgiN4/XL0iCK93L9EwU6kJIm+KiV1URvnUE0R9l4N UU/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=S9F3gYcd; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id 15-20020a62190f000000b005182fb67e66si9541883pfz.159.2022.06.26.03.45.38; Sun, 26 Jun 2022 03:45:50 -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=@gmail.com header.s=20210112 header.b=S9F3gYcd; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234257AbiFZKgA (ORCPT + 99 others); Sun, 26 Jun 2022 06:36:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60452 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232828AbiFZKf4 (ORCPT ); Sun, 26 Jun 2022 06:35:56 -0400 Received: from mail-pf1-x429.google.com (mail-pf1-x429.google.com [IPv6:2607:f8b0:4864:20::429]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D4E9B1275B; Sun, 26 Jun 2022 03:35:52 -0700 (PDT) Received: by mail-pf1-x429.google.com with SMTP id a15so6434461pfv.13; Sun, 26 Jun 2022 03:35:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=CT9UzjAprHUqV7ZTg5rA+EnKneUfvjzMy7Q3wVldT2o=; b=S9F3gYcdAgALN/i00FyqnFPtw72EX93LhTZjMcfrkZUtXojwUQ9tPv/wzwSjp1qmWk TTZufc3+EeKVDchJO/N9kqI6IP9t4OMy+QPy02kqaNxRVAEGoQ2j4oozWseT+euZJaZa WwMfRf/17IKfcMeVkaDXkOhBnTNBoRsoUE7587XITamp2UYpa1AiEr4L13IIT1g1jVtu +t7ygiWiLTigI7XjxQbVzh7vWEnQDTQAnXTqn9dmF2jnN53kEJuBP0ckSNiB7ZEIs2Uy 7Ktp5TtzKeM8yuDyBEXY9a/ZzxVFOhxQES4k5HvrEdlf11fajT6MYCXu3CPyxVic1NV5 UgTA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=CT9UzjAprHUqV7ZTg5rA+EnKneUfvjzMy7Q3wVldT2o=; b=yjJi8i/zG9DO8tW3qjWsPz4wLGQ7izj/kxCqxMgat5QjsrQchI8y5HqTzpEve7tx5r 3Fyr7AwPPT/KmqSKa9rYo1lRBaNxkKOrnGRZA2X37covPz/2/WuQPQw9dWKFUR/LiaOB GpcCTaFek3Nnhb15YPLGzpqviDDxULZ9F+78pn3NG3zoVRrii6yR3QI6EV/0rwOe9JM0 Leuq/5/x4Q18gpZcjkwoovWuaWNLScNqTdJb658YQ0QZKl14VG05NfuDBVW3gDd6VMs6 uePBe1xjVTJpufQI27IW/PdMAUSjaHfF4WhTHbIDPCEivOm97SpxZNyORZaUpZikgw3M QD4w== X-Gm-Message-State: AJIora/cqls/PB8EjpNRri0JBFBDk5qeqF+bymeTOwsPmFG+vU6bUvhu VJ0h9BLiKYvugObreyhJP0l75TADkaUab6EaJclfng== X-Received: by 2002:a63:f91b:0:b0:40d:d291:1555 with SMTP id h27-20020a63f91b000000b0040dd2911555mr3559579pgi.399.1656239752099; Sun, 26 Jun 2022 03:35:52 -0700 (PDT) Received: from ip-172-31-11-128.ap-south-1.compute.internal (ec2-35-154-4-181.ap-south-1.compute.amazonaws.com. [35.154.4.181]) by smtp.gmail.com with ESMTPSA id n9-20020a635c49000000b0040cf8789851sm4849234pgm.35.2022.06.26.03.35.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 26 Jun 2022 03:35:51 -0700 (PDT) From: Praghadeesh T K S To: Rain River , Zhu Yanjun , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Cc: skhan@linuxfoundation.org, praghadeeshtks@zohomail.in, linux-kernel-mentees@lists.linuxfoundation.org, Praghadeesh T K S Subject: [PATCH] net: ethernet/nvidia: fix possible condition with no effect Date: Sun, 26 Jun 2022 10:35:39 +0000 Message-Id: <20220626103539.80283-1-praghadeeshthevendria@gmail.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,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 Fix Coccinelle bug, removed condition with no effect. Signed-off-by: Praghadeesh T K S --- drivers/net/ethernet/nvidia/forcedeth.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/net/ethernet/nvidia/forcedeth.c b/drivers/net/ethernet/nvidia/forcedeth.c index 5116bad..8e49cfa 100644 --- a/drivers/net/ethernet/nvidia/forcedeth.c +++ b/drivers/net/ethernet/nvidia/forcedeth.c @@ -3471,9 +3471,6 @@ static int nv_update_linkspeed(struct net_device *dev) } else if (adv_lpa & LPA_10FULL) { newls = NVREG_LINKSPEED_FORCE|NVREG_LINKSPEED_10; newdup = 1; - } else if (adv_lpa & LPA_10HALF) { - newls = NVREG_LINKSPEED_FORCE|NVREG_LINKSPEED_10; - newdup = 0; } else { newls = NVREG_LINKSPEED_FORCE|NVREG_LINKSPEED_10; newdup = 0; -- 2.34.1