Received: by 2002:ac0:e350:0:0:0:0:0 with SMTP id g16csp380565imn; Fri, 29 Jul 2022 09:38:05 -0700 (PDT) X-Google-Smtp-Source: AA6agR6W2bANDkiF5mG8K5K8wdIao5NaZNRyGgKubUgPq8ZVo6+EL0zATfLM7rqjsmRvPQNkVUP5 X-Received: by 2002:a05:6402:1bc9:b0:43d:3903:11ee with SMTP id ch9-20020a0564021bc900b0043d390311eemr1321904edb.113.1659112685693; Fri, 29 Jul 2022 09:38:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1659112685; cv=none; d=google.com; s=arc-20160816; b=T1sIZ29QDqy0BYRbdc4GBAhA5RLMwCbnYVVeAcI5bBOCtSpZqwTTJgwMOx/ZhCuP/8 XSiC4AqDV3x5dzcq+LHkYU1JDRKjEMVi2PCQRfvagBU2Z5ONYHdXRncFJ5AElm53e/Ci IBNDoAOCR2zHXE4b2H825byZ1omqezJsnzYQhaY7fH4xlb+pAJ29/fHS5+sT5pQYJbuT 2bTWwYe+oyQujs3BUMI4IlD2PXPrODuGbfCmH5on1cuXSNxAgo9BTyJ0Ej3JzUp+DCAx H6EoMN6u6mqrepO1qraJQe+jOcHs2mGDljcxMWH0KwfwdZDDkNU00qxxeiupm5z1AI5E 3ntQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=8vEvEoXiOGD+iC089b5mhdDPX1NyQHNd+5UkIwp9jpU=; b=mlptI3WRIDnbDTM8hQFxNg2PW/LBWAKicxCexw882kbnGTfvcwUq96KFNXG4DjZ8Y3 EuaeYuFUI2059sQDSApjtLT6B1qlCa17RnSGnkbmfNn/u066pksCLDI18zMTgd0Ocp1v UjAqyi8zyV44KLlaFoSmhZz1GXOIiatAwnE1UKtm3HylVfU0atnOlabFNI4ZzqwWkJIA sdXUFb3NlfNZfCgCHIhvAqkkO6z3X1UYae4l6cPkg64zUcaghN5MfzDYB3lWCpHuJD9Z +wvDa5RH0DMKFPRPH3tyvwSQZPJq06tIaiJN/hXPSDvHrpP02axR8DFNynYhharn4j+C KsFw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@pensando.io header.s=google header.b=F2Y8kzcz; 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=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=pensando.io Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id d13-20020a170906344d00b0071203baa0desi3011801ejb.260.2022.07.29.09.37.32; Fri, 29 Jul 2022 09:38:05 -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=fail header.i=@pensando.io header.s=google header.b=F2Y8kzcz; 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=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=pensando.io Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232888AbiG2QcH (ORCPT + 99 others); Fri, 29 Jul 2022 12:32:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49738 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229519AbiG2QcG (ORCPT ); Fri, 29 Jul 2022 12:32:06 -0400 Received: from mail-pj1-x1031.google.com (mail-pj1-x1031.google.com [IPv6:2607:f8b0:4864:20::1031]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E5D5C3246A for ; Fri, 29 Jul 2022 09:32:04 -0700 (PDT) Received: by mail-pj1-x1031.google.com with SMTP id v16-20020a17090abb9000b001f25244c65dso8889217pjr.2 for ; Fri, 29 Jul 2022 09:32:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pensando.io; s=google; h=message-id:date:mime-version:user-agent:subject:content-language:to :cc:references:from:in-reply-to:content-transfer-encoding; bh=8vEvEoXiOGD+iC089b5mhdDPX1NyQHNd+5UkIwp9jpU=; b=F2Y8kzczwb9Km0nTTNTajsiO92LybDkIifBYVq4p6ymFg7+WSIyfXBFF52ceO21JVD JqWFT19Kn/PRXZpfy7eL1Cv41SlhQ2HdMXOwFfP36dGIOdn1hFq0j3S76arWHXwxdw4k pLD/TV69dbLrO0ugmieC7WExIVCh1vqqOAPmoIVATp9he30zbKarFbt7e3TMgWFfN3Tq kN87eNJBtu7agDtVESu0GYRIrYqZUWVnqxTi7uNKDgS8HsjDStNuHHnfQ/BTDaf5jERU X28afroqc6Grdb8Nu1I+txorb6coSVUmBgJU3vb0lAuqDB+8qt3UWQYd/9X4pOwGdJ4l zQrg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :content-language:to:cc:references:from:in-reply-to :content-transfer-encoding; bh=8vEvEoXiOGD+iC089b5mhdDPX1NyQHNd+5UkIwp9jpU=; b=TSr4+f2BbXnzvjDlDkz3IOa20kdCKMYK+5UzENTvIZp3YOmno+i+pXwbTBZpVMqCX1 /Cy+Y5t/Ahtz4yubdCuCkmSvR9lETrj5bpuYUokcC2Ud31aviHS86BiyMC/fiuedWa+1 yP2ZvTdAn4eY5nV7PlaNOOHsoY5vKyAN01bjJWxTuKC53W1Ox0cGe6HUR0kry/rafP1b 9dbOZzx3/3qkJfEmgopT+0n1iI9pxjo2rSMTBkqOD9tmg6E6SolWc0LDNf5SNOZMRTLo pQgIEE/V5YC3tg4TsXTyeFnQK0TvqwMKVRgmFaRWhlqNgDFMCzh561ED5tTjE7Ex1pnm lbJA== X-Gm-Message-State: ACgBeo07KiJ2ksW9adepzB8l11XwlzFmFhoTts/PbcRr+jW7/XXB2uD1 7rm6XRhTgiRsQyizvDWoI+ADTg== X-Received: by 2002:a17:902:a9c6:b0:16c:9d5a:fde1 with SMTP id b6-20020a170902a9c600b0016c9d5afde1mr4662863plr.3.1659112324302; Fri, 29 Jul 2022 09:32:04 -0700 (PDT) Received: from [192.168.0.3] ([50.53.169.105]) by smtp.gmail.com with ESMTPSA id f15-20020a17090a638f00b001f04479017fsm3291279pjj.29.2022.07.29.09.32.01 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 29 Jul 2022 09:32:03 -0700 (PDT) Message-ID: <4f3764f1-1faa-c28d-21b1-3356ddb3cede@pensando.io> Date: Fri, 29 Jul 2022 09:32:00 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.11.0 Subject: Re: [PATCH net 2/2] net: ionic: fix error check for vlan flags in ionic_set_nic_features() Content-Language: en-US To: Guangbin Huang , davem@davemloft.net, kuba@kernel.org, edumazet@google.com, pabeni@redhat.com, brett@pensando.io, drivers@pensando.io, anthony.l.nguyen@intel.com, jesse.brandeburg@intel.com Cc: intel-wired-lan@lists.osuosl.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, lipeng321@huawei.com References: <20220729101755.4798-1-huangguangbin2@huawei.com> <20220729101755.4798-3-huangguangbin2@huawei.com> From: Shannon Nelson In-Reply-To: <20220729101755.4798-3-huangguangbin2@huawei.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-1.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,NICE_REPLY_A,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=no 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 7/29/22 3:17 AM, Guangbin Huang wrote: > From: Jian Shen > > The prototype of input features of ionic_set_nic_features() is > netdev_features_t, but the vlan_flags is using the private > definition of ionic drivers. It should use the variable > ctx.cmd.lif_setattr.features, rather than features to check > the vlan flags. So fixes it. > > Fixes: beead698b173 ("ionic: Add the basic NDO callbacks for netdev support") > > Signed-off-by: Jian Shen > Signed-off-by: Guangbin Huang Good catch - thanks! Acked-by: Shannon Nelson > --- > drivers/net/ethernet/pensando/ionic/ionic_lif.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/net/ethernet/pensando/ionic/ionic_lif.c b/drivers/net/ethernet/pensando/ionic/ionic_lif.c > index f3568901eb91..1443f788ee37 100644 > --- a/drivers/net/ethernet/pensando/ionic/ionic_lif.c > +++ b/drivers/net/ethernet/pensando/ionic/ionic_lif.c > @@ -1437,7 +1437,7 @@ static int ionic_set_nic_features(struct ionic_lif *lif, > if ((old_hw_features ^ lif->hw_features) & IONIC_ETH_HW_RX_HASH) > ionic_lif_rss_config(lif, lif->rss_types, NULL, NULL); > > - if ((vlan_flags & features) && > + if ((vlan_flags & le64_to_cpu(ctx.cmd.lif_setattr.features)) && > !(vlan_flags & le64_to_cpu(ctx.comp.lif_setattr.features))) > dev_info_once(lif->ionic->dev, "NIC is not supporting vlan offload, likely in SmartNIC mode\n"); >