From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f68.google.com (mail-wm0-f68.google.com [74.125.82.68]) by dpdk.org (Postfix) with ESMTP id E886F100C for ; Mon, 30 Apr 2018 16:54:31 +0200 (CEST) Received: by mail-wm0-f68.google.com with SMTP id l1so14743060wmb.2 for ; Mon, 30 Apr 2018 07:54:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=l3+1ehrPpRA6azzbw53z9uGMXLe7B74drHuKLUptGIg=; b=CsEh80jKGdmuFzQiPei+YzxODQlgPkN5C/dNTq0IgK3/0SoIdFtpDuisM3DDaDwl+A XzB0dEMFgW/DgM2ePAofo1X50O7LAzsXDOsyqdWV4HbFcngsr69AG2oFXD039s13MMa3 TUq7H24K84j1+TJdx2p0kZV2w4A/AKIrLT3nSdWJCFwvYVla0FLZdr7/asPI/gkuBqR/ gjh1pYUl2kfozrt6JJhz9k9I/yy3y56H2pNq9Wa8v2TmKtjQo1T87lTHcLCHR2kzN3k5 ebswItvSPrF5pZdNOFcJ2cfC23aNZBT3zWCXVVJztoF1QJkRwFZi16Nt1nlz+T9Ucp6Q acyA== 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; bh=l3+1ehrPpRA6azzbw53z9uGMXLe7B74drHuKLUptGIg=; b=lqlzDrLVzuA8OXGq54w6ACJmAR8kr4yjUc6vzlJQLhDP8AmfKN1OLalk43tuc2UOvz o2DHggyyer5epVtv7IwqRwFvFkw6bPE4XpjjR8tRmn9pCNITdTElXOh9g4ABHWQaO4Y3 QIp7ND/Wsk4AY17mFAO4S2I1j79qJzfo8jvpUn3/7AxlvL+zk3oEdL6GsM6dHWKEoZM/ 9K5C5CE/fDl+qHdg/Gwk/GnFjbgG59kqW38zX9FDP6+UO5vukemQG2Nb2yyguOa6K+en 7L3K5lD3NIefzSWkbA+PkOZRVdET6dn1Po+4U3yHVNSuNCW0WuZMZAjU/qH5uXpT4Lo/ DVcQ== X-Gm-Message-State: ALQs6tAV3IEf2n9ginCeZYNDC7J8oNO9vCybYlk9hcjLiv6Z7MCeifKB dHSdg3+m2uvGSHl12blLmWs= X-Google-Smtp-Source: AB8JxZrMHhF+Vw+xkkgS8zyk6Vhr5PVOtDHAD4A4DT4M7W37o0NxkQyGyJ3DWLxDs+W7Yz/2nm8Shg== X-Received: by 10.28.146.136 with SMTP id u130mr8261929wmd.125.1525100071390; Mon, 30 Apr 2018 07:54:31 -0700 (PDT) Received: from localhost ([2a00:23c5:be9a:5200:ce4c:82c0:d567:ecbb]) by smtp.gmail.com with ESMTPSA id c21-v6sm7277997wre.43.2018.04.30.07.54.30 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 30 Apr 2018 07:54:30 -0700 (PDT) From: luca.boccassi@gmail.com To: Adrien Mazarguil Cc: Nelio Laranjeiro , Ferruh Yigit , dpdk stable Date: Mon, 30 Apr 2018 15:53:36 +0100 Message-Id: <20180430145402.23057-17-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180430145402.23057-1-luca.boccassi@gmail.com> References: <20180430144223.18657-85-luca.boccassi@gmail.com> <20180430145402.23057-1-luca.boccassi@gmail.com> Subject: [dpdk-stable] patch 'net/mlx4: fix ignored RSS hash types' has been queued to stable release 18.02.2 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 30 Apr 2018 14:54:32 -0000 Hi, FYI, your patch has been queued to stable release 18.02.2 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 05/02/18. So please shout if anyone has objections. Thanks. Luca Boccassi --- >>From fd5885ebc62c5b5b6d674057773a0d8fd5a64dca Mon Sep 17 00:00:00 2001 From: Adrien Mazarguil Date: Thu, 19 Apr 2018 12:07:27 +0200 Subject: [PATCH] net/mlx4: fix ignored RSS hash types [ upstream commit ef134c8daa0873daa3aa9b02313d6f452c3477a2 ] When an unsupported hash type is part of a RSS configuration structure, it is silently ignored instead of triggering an error. This may lead applications to assume that such types are accepted, while they are in fact not part of the resulting flow rules. Fixes: 078b8b452e6b ("net/mlx4: add RSS flow rule action support") Signed-off-by: Adrien Mazarguil Acked-by: Nelio Laranjeiro Acked-by: Ferruh Yigit --- drivers/net/mlx4/mlx4_flow.c | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/drivers/net/mlx4/mlx4_flow.c b/drivers/net/mlx4/mlx4_flow.c index a3b4480b4..4d26df326 100644 --- a/drivers/net/mlx4/mlx4_flow.c +++ b/drivers/net/mlx4/mlx4_flow.c @@ -706,6 +706,7 @@ fill: const struct rte_flow_action_queue *queue; const struct rte_flow_action_rss *rss; const struct rte_eth_rss_conf *rss_conf; + uint64_t fields; unsigned int i; case RTE_FLOW_ACTION_TYPE_VOID: @@ -780,10 +781,15 @@ fill: " of the context size"; goto exit_action_not_supported; } + rte_errno = 0; + fields = mlx4_conv_rss_hf(priv, rss_conf->rss_hf); + if (fields == (uint64_t)-1 && rte_errno) { + msg = "unsupported RSS hash type requested"; + goto exit_action_not_supported; + } flow->rss = mlx4_rss_get - (priv, - mlx4_conv_rss_hf(priv, rss_conf->rss_hf), - rss_conf->rss_key, rss->num, rss->queue); + (priv, fields, rss_conf->rss_key, rss->num, + rss->queue); if (!flow->rss) { msg = "either invalid parameters or not enough" " resources for additional multi-queue" -- 2.14.2