From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f67.google.com (mail-wm0-f67.google.com [74.125.82.67]) by dpdk.org (Postfix) with ESMTP id 898C71B363 for ; Wed, 14 Feb 2018 09:57:55 +0100 (CET) Received: by mail-wm0-f67.google.com with SMTP id f3so20631555wmc.1 for ; Wed, 14 Feb 2018 00:57:55 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:in-reply-to:references:content-transfer-encoding; bh=g43LMbJ27sSimaKOsfp8lTOLbum+k18iLoWlKPbJVS4=; b=JRJEDoaFzhirM9W+3zIH8+0dwT3LxGNoeuozg+y5cOISE25gQoklAY7fRcDA4W6wKr nJ6zca+M9hzhI6yR9Be8bKFIY9fzyEGkrKj99TUHc8XX2UzPz5fiNDZ7C3fKb2Uz8EF/ NQjfRBgGiapV7hchuf9f6/bs8+lQC4Od3AAKiJNIsfRHa+zSdohk3oKJ4mlGRs/yEZe7 DZkxGfWXWRMND3DCC3fHd5gbniv12TDHEhtupwl/j7nK7nNCWoqmt5LD6luqW48osZXm im/Zj+xHYeYqOLhyPlAtmVlzPgS9ResdW329vBTbOed6KinkS9/v7Dc1I+HMKYUyTqyG 7dvg== 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:in-reply-to:references :content-transfer-encoding; bh=g43LMbJ27sSimaKOsfp8lTOLbum+k18iLoWlKPbJVS4=; b=qcAadhzDS0ZMiK/RCDxwPcdM7EZI1RpSBZTQ1hv7hp1cTZ1xFe6Xs3wzePGswGeOhO FrCDP1se8Yr4qZvUufQYEyONiai3Ew5vifuneEFz6VGJ0/pu1MTk8y5k1HUpkFnMqirp j16Nzh3kp//cCPexzinTXpxjW+OK1nptWaYJMeUEgs64EO3zAv87CnP0cD8rfCDnlb33 79rYGZjBQdrjp9IrEkVCURvGlllV1Y/NHQqHF5qxmhQcxPsfYA8/Z5/Ss42wPsogbE/6 E2WHJQ5KYLrZuhdNizQUkpVToY+4Bc42AFwhosTjFGSkDBi9rSAy2ycqe+dxS+vuoxwf jfrA== X-Gm-Message-State: APf1xPBs5AqYzyZXUi8axAoBvf/XXG2P6JXmPmuZtneZgnstjt9cyfmn KAXP5s35S8uQuRZ9ky4NjZlWxMmyqg== X-Google-Smtp-Source: AH8x224Ev1sp1pTvkaX/ysdnH6TsiEbaMMToaj4V9rf4WoGR9a2805cy9px4NSnfVKPlcw7q7DBiWQ== X-Received: by 10.28.178.198 with SMTP id b189mr3294066wmf.55.1518598675139; Wed, 14 Feb 2018 00:57:55 -0800 (PST) Received: from laranjeiro-vm.dev.6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id 42sm18593706wrw.15.2018.02.14.00.57.54 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 14 Feb 2018 00:57:54 -0800 (PST) From: Nelio Laranjeiro To: stable@dpdk.org, Yuanhan Liu Cc: =?UTF-8?q?N=C3=A9lio=20Laranjeiro?= , Adrien Mazarguil , Yongseok Koh Date: Wed, 14 Feb 2018 09:58:31 +0100 Message-Id: <2d98fa595aa52077b882379b7878ae5c4c988a8b.1518598604.git.nelio.laranjeiro@6wind.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <9e4118bfe3df2a78d9cf6d5ca74efe4ece730799.1518598604.git.nelio.laranjeiro@6wind.com> References: <9e4118bfe3df2a78d9cf6d5ca74efe4ece730799.1518598604.git.nelio.laranjeiro@6wind.com> MIME-Version: 1.0 In-Reply-To: <20180207093155.GA31542@yliu-mob> References: <20180207093155.GA31542@yliu-mob> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [dpdk-stable] [PATCH 3/3] net/mlx5: fix flow priority on queue action 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: Wed, 14 Feb 2018 08:57:55 -0000 From: NĂ©lio Laranjeiro [ backported from upstream commit c3299d76867f23e595d8e1b3e6b9ad4d6aa87155 ] A single queue should have the same verbs priority as an RSS one. Fixes: 8086cf08b2f0 ("net/mlx5: handle RSS hash configuration in RSS flow") Cc: stable@dpdk.org Signed-off-by: Nelio Laranjeiro Acked-by: Yongseok Koh --- drivers/net/mlx5/mlx5_flow.c | 30 +----------------------------- 1 file changed, 1 insertion(+), 29 deletions(-) diff --git a/drivers/net/mlx5/mlx5_flow.c b/drivers/net/mlx5/mlx5_flow.c index c18c77d48..82efddc5a 100644 --- a/drivers/net/mlx5/mlx5_flow.c +++ b/drivers/net/mlx5/mlx5_flow.c @@ -882,8 +882,6 @@ priv_flow_convert_items_validate(struct priv *priv, } if (parser->drop) { parser->drop_q.offset += cur_item->dst_sz; - } else if (parser->queues_n == 1) { - parser->queue[HASH_RXQ_ETH].offset += cur_item->dst_sz; } else { for (n = 0; n != hash_rxq_init_n; ++n) parser->queue[n].offset += cur_item->dst_sz; @@ -1126,19 +1124,6 @@ priv_flow_convert(struct priv *priv, if (!parser->drop_q.ibv_attr) return ENOMEM; parser->drop_q.offset = sizeof(struct ibv_flow_attr); - } else if (parser->queues_n == 1) { - unsigned int priority = - attr->priority + - hash_rxq_init[HASH_RXQ_ETH].flow_priority; - unsigned int offset = parser->queue[HASH_RXQ_ETH].offset; - - parser->queue[HASH_RXQ_ETH].ibv_attr = - priv_flow_convert_allocate(priv, priority, - offset, error); - if (!parser->queue[HASH_RXQ_ETH].ibv_attr) - return ENOMEM; - parser->queue[HASH_RXQ_ETH].offset = - sizeof(struct ibv_flow_attr); } else { for (i = 0; i != hash_rxq_init_n; ++i) { unsigned int priority = @@ -1188,22 +1173,9 @@ priv_flow_convert(struct priv *priv, * Last step. Complete missing specification to reach the RSS * configuration. */ - if (parser->drop) { - /* - * Drop queue priority needs to be adjusted to - * their most specific layer priority. - */ - parser->drop_q.ibv_attr->priority = - attr->priority + - hash_rxq_init[parser->layer].flow_priority; - } else if (parser->queues_n > 1) { + if (!parser->drop) { priv_flow_convert_finalise(priv, parser); } else { - /* - * Action queue have their priority overridden with - * Ethernet priority, this priority needs to be adjusted to - * their most specific layer priority. - */ parser->queue[HASH_RXQ_ETH].ibv_attr->priority = attr->priority + hash_rxq_init[parser->layer].flow_priority; -- 2.11.0