From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id EAB79A046B; Thu, 30 Apr 2020 21:10:19 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id B46DF1DC0A; Thu, 30 Apr 2020 21:09:21 +0200 (CEST) Received: from mail-pf1-f196.google.com (mail-pf1-f196.google.com [209.85.210.196]) by dpdk.org (Postfix) with ESMTP id 459091DBD9 for ; Thu, 30 Apr 2020 21:09:12 +0200 (CEST) Received: by mail-pf1-f196.google.com with SMTP id 145so275845pfw.13 for ; Thu, 30 Apr 2020 12:09:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=M/AtJFQOHA13YLupaTRevoU1bj/pruCWydpA7Uao0XY=; b=H/rBOXjn5cBIyYof0DoNzw0nr7dKA+7XdyomCagp6eLOgjrTeMBsemCP96GPfIDzul 6H9PS7veBmxgWyde1wjZIXoT7Wvwdc1ct2pJjMINytKegs/dBZBE1t0MPFoVGkub9v7y USoTDQKFTed7YpO6SYbzI3WjP7NoPtwo5YJDE/Ghvgei6fc5l/nAu/VjVrVkNs3fynLl WU4fTJrvzuN+FiC01HscnNjNjWxi1fGRLlKz9hKZcrV8A2/XY5pcAKW8x4k5rGUZKzhI YeKmxS5x3qhk6QHUpGEMkNfmuNe34IPbtyZWB93udKYOvwjx2URDAc+sjJBtc55SSyAj 2aUQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=M/AtJFQOHA13YLupaTRevoU1bj/pruCWydpA7Uao0XY=; b=Nhi3rAW9PiIrxvbhQoyQrSGkOlEQ/jXlWhCEgDCNzxRR+o9wes86iewhrpJO2ic0yt knziv7MvRhyF/FpXwAoihY9dgMC55kOuzD9hJxG81mtVxUJm6cxY/OgiQzcvqybe2yGy LEhSsPTvOxKHzSCnekI5nSZuYfJ4RPpZfItmWTrStlTcB9Bsb4WT8WfNuUS2LgGvGEsC UdPlav2gmHqu4Vmb5RPG9TxKuTJ/dTkR4TUpAMN9BVY25qHhy5nKGcl6+yhJLM1ARWEF yTV52PoTUduPzbaTc4duyyevyTOntKvivxiLmnR9n1T+j+xLO80YVfdqROESR8JSMVji 2omw== X-Gm-Message-State: AGi0Puad9orhkfb7nRGaKBtWyY6Dk1kvzS4T3AY4AB+3GxxisuqaQO4Y Ik5IC3e3htAFJ9VyE3YuWM/NAy45q5vhWg== X-Google-Smtp-Source: APiQypKCqJVMmc4qVe8ZCRE8/PqOVeOy6w0kqOWTFqpnk/VpBaIbBHclLe5MtkrIwSaKeIoGpcbUyQ== X-Received: by 2002:aa7:81cf:: with SMTP id c15mr190190pfn.211.1588273751082; Thu, 30 Apr 2020 12:09:11 -0700 (PDT) Received: from hermes.lan (204-195-22-127.wavecable.com. [204.195.22.127]) by smtp.gmail.com with ESMTPSA id fy21sm452075pjb.25.2020.04.30.12.09.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 Apr 2020 12:09:09 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Date: Thu, 30 Apr 2020 12:08:53 -0700 Message-Id: <20200430190853.498-8-stephen@networkplumber.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200430190853.498-1-stephen@networkplumber.org> References: <20200430190853.498-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH 7/7] net/netvsc: don't configure RSS if disabled X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" This fixes the problem where driver would not start if only have a single Rx queue and multiple Txq. In that case, RSS should stay disabled. Fixes: 92d23a57cafe ("net/netvsc: support configuring RSS parameters") Signed-off-by: Stephen Hemminger --- drivers/net/netvsc/hn_ethdev.c | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/drivers/net/netvsc/hn_ethdev.c b/drivers/net/netvsc/hn_ethdev.c index 60102362e124..55b8a63804a9 100644 --- a/drivers/net/netvsc/hn_ethdev.c +++ b/drivers/net/netvsc/hn_ethdev.c @@ -376,14 +376,15 @@ static int hn_rss_hash_update(struct rte_eth_dev *dev, hn_rss_hash_init(hv, rss_conf); - err = hn_rndis_conf_rss(hv, 0); - if (err) { - PMD_DRV_LOG(NOTICE, - "rss reconfig failed (RSS disabled)"); - return err; + if (rss_conf->rss_hf != 0) { + err = hn_rndis_conf_rss(hv, 0); + if (err) { + PMD_DRV_LOG(NOTICE, + "rss reconfig failed (RSS disabled)"); + return err; + } } - return hn_vf_rss_hash_update(dev, rss_conf); } @@ -595,11 +596,13 @@ static int hn_dev_configure(struct rte_eth_dev *dev) return err; } - err = hn_rndis_conf_rss(hv, 0); - if (err) { - PMD_DRV_LOG(NOTICE, - "initial RSS config failed"); - return err; + if (rss_conf->rss_hf != 0) { + err = hn_rndis_conf_rss(hv, 0); + if (err) { + PMD_DRV_LOG(NOTICE, + "initial RSS config failed"); + return err; + } } } -- 2.20.1