From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f195.google.com (mail-wr0-f195.google.com [209.85.128.195]) by dpdk.org (Postfix) with ESMTP id A58DB1B249 for ; Mon, 30 Oct 2017 16:36:00 +0100 (CET) Received: by mail-wr0-f195.google.com with SMTP id o44so13027685wrf.11 for ; Mon, 30 Oct 2017 08:36:00 -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=rjDeTRuWKaWttZAPjcbKfX2DCHTHZx8KAPIasJ3HCIE=; b=N3LcWjpD2LUUnGRuGFZAmeu+8h3FAEUGdw3FxOaY/6uN1MSF05Dq+GmIQCe0IUvyJh yjf/7GgLjNTKVoWGOoPNs77hQOPmDPVk6FNtES7hgFgW68stHReb9+kJxLeNbhfyeMtF mGefMpKOVIAdWHjIM1prgjx7wSqL+Mnnit/BymG1bUQ6GKpj0MYN6liXfviVdNTfXfUN 2NGTxNDKf9ozffERJ27iIvJfd0scjY51ukCQGcDRlqOpidM2qSOu8cW4JrVJypjBg4O8 OCvWuyzacqwYDiiBi2+hJRbnVZhNUp47QrdXVVoh1LOwvGly639TRrDZOZmNdjueWF09 NaKA== 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=rjDeTRuWKaWttZAPjcbKfX2DCHTHZx8KAPIasJ3HCIE=; b=fEP6J0/AefnQTPwCZGaZn9i8Y8aOnFwxVWCcQDU3hN6GgsdAQUbXQ1+PjmNptFR8ns mlfmRBe1iimxVzG96rUXunsg2VbT5YQ1zTpgIaMuy8yGEWbFmnyOCC2GUgA3VzE5W1zp 6JT+aO+nAxzeLUVlVQ5Av3yeaTY1T3f/WxiBgygsoWd2WcRSdKpORf0peslLW5PuWrsd evE9ePhnBLYPXTiVFAjKa2G0XoamVo0KZg0AOFsbX9riZwkOQIIU61Hf24rMahsBgRJw bony7GjUT8cWHKYe9/0knA9KEMmOlhsxH0fYB/FA0c4QR/InQkPx/C9F20ZFHlluicUW njRw== X-Gm-Message-State: AMCzsaWhFclwFiFlhv5SqvYRs7E6oyevvCJZij90OKYWz7sD7c+qxnz9 gZ9akl6fpN0H8PlIT8dcDY4= X-Google-Smtp-Source: ABhQp+Q8Qnb4SQaAmI6L9tCnn74xnUtGzlNKyBJSQ4PeSCfpwHQ9sFAY2FRq3kUiwKfBOUJSS5rCog== X-Received: by 10.223.146.37 with SMTP id 34mr7823977wrj.79.1509377760359; Mon, 30 Oct 2017 08:36:00 -0700 (PDT) Received: from localhost ([2a00:23c5:bef3:400:4a51:b7ff:fe0b:4749]) by smtp.gmail.com with ESMTPSA id d18sm12868120wra.50.2017.10.30.08.35.59 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 30 Oct 2017 08:35:59 -0700 (PDT) From: luca.boccassi@gmail.com To: Wei Dai Cc: dpdk stable Date: Mon, 30 Oct 2017 15:34:11 +0000 Message-Id: <20171030153511.13322-8-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20171030153511.13322-1-luca.boccassi@gmail.com> References: <20171030153511.13322-1-luca.boccassi@gmail.com> Subject: [dpdk-stable] patch 'net/ixgbe: fix mapping of user priority to TC' has been queued to LTS release 16.11.4 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 Oct 2017 15:36:00 -0000 Hi, FYI, your patch has been queued to LTS release 16.11.4 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 11/01/17. So please shout if anyone has objections. Thanks. Kind regards, Luca Boccassi --- >>From c31b1e7fc352af4044517288ac0eeda978783e78 Mon Sep 17 00:00:00 2001 From: Wei Dai Date: Mon, 21 Aug 2017 15:50:05 +0800 Subject: [PATCH] net/ixgbe: fix mapping of user priority to TC [ upstream commit a8e54b44515ce741a0b73fe2e35e99f6f1dcef4b ] This patch fixes the mapping of user priority to traffic class in Rx/Tx path of DCB configuration. Each DCB traffic class should include all user priorities mapping to it in both Rx and Tx path. Fixes: 0807f80d35d0 ("ixgbe: DCB / flow control") Signed-off-by: Wei Dai --- drivers/net/ixgbe/ixgbe_rxtx.c | 41 +++++++++++++++++++++++++++++++++-------- 1 file changed, 33 insertions(+), 8 deletions(-) diff --git a/drivers/net/ixgbe/ixgbe_rxtx.c b/drivers/net/ixgbe/ixgbe_rxtx.c index d1e300a58..8b18b5302 100644 --- a/drivers/net/ixgbe/ixgbe_rxtx.c +++ b/drivers/net/ixgbe/ixgbe_rxtx.c @@ -3395,12 +3395,19 @@ ixgbe_vmdq_dcb_rx_config(struct rte_eth_dev *dev, dcb_config->num_tcs.pg_tcs = ETH_4_TCS; dcb_config->num_tcs.pfc_tcs = ETH_4_TCS; } + + /* Initialize User Priority to Traffic Class mapping */ + for (j = 0; j < IXGBE_DCB_MAX_TRAFFIC_CLASS; j++) { + tc = &dcb_config->tc_config[j]; + tc->path[IXGBE_DCB_RX_CONFIG].up_to_tc_bitmap = 0; + } + /* User Priority to Traffic Class mapping */ for (i = 0; i < ETH_DCB_NUM_USER_PRIORITIES; i++) { j = vmdq_rx_conf->dcb_tc[i]; tc = &dcb_config->tc_config[j]; - tc->path[IXGBE_DCB_RX_CONFIG].up_to_tc_bitmap = - (uint8_t)(1 << j); + tc->path[IXGBE_DCB_RX_CONFIG].up_to_tc_bitmap |= + (uint8_t)(1 << i); } } @@ -3422,12 +3429,18 @@ ixgbe_dcb_vt_tx_config(struct rte_eth_dev *dev, dcb_config->num_tcs.pfc_tcs = ETH_4_TCS; } + /* Initialize User Priority to Traffic Class mapping */ + for (j = 0; j < IXGBE_DCB_MAX_TRAFFIC_CLASS; j++) { + tc = &dcb_config->tc_config[j]; + tc->path[IXGBE_DCB_TX_CONFIG].up_to_tc_bitmap = 0; + } + /* User Priority to Traffic Class mapping */ for (i = 0; i < ETH_DCB_NUM_USER_PRIORITIES; i++) { j = vmdq_tx_conf->dcb_tc[i]; tc = &dcb_config->tc_config[j]; - tc->path[IXGBE_DCB_TX_CONFIG].up_to_tc_bitmap = - (uint8_t)(1 << j); + tc->path[IXGBE_DCB_TX_CONFIG].up_to_tc_bitmap |= + (uint8_t)(1 << i); } } @@ -3443,12 +3456,18 @@ ixgbe_dcb_rx_config(struct rte_eth_dev *dev, dcb_config->num_tcs.pg_tcs = (uint8_t)rx_conf->nb_tcs; dcb_config->num_tcs.pfc_tcs = (uint8_t)rx_conf->nb_tcs; + /* Initialize User Priority to Traffic Class mapping */ + for (j = 0; j < IXGBE_DCB_MAX_TRAFFIC_CLASS; j++) { + tc = &dcb_config->tc_config[j]; + tc->path[IXGBE_DCB_RX_CONFIG].up_to_tc_bitmap = 0; + } + /* User Priority to Traffic Class mapping */ for (i = 0; i < ETH_DCB_NUM_USER_PRIORITIES; i++) { j = rx_conf->dcb_tc[i]; tc = &dcb_config->tc_config[j]; - tc->path[IXGBE_DCB_RX_CONFIG].up_to_tc_bitmap = - (uint8_t)(1 << j); + tc->path[IXGBE_DCB_RX_CONFIG].up_to_tc_bitmap |= + (uint8_t)(1 << i); } } @@ -3464,12 +3483,18 @@ ixgbe_dcb_tx_config(struct rte_eth_dev *dev, dcb_config->num_tcs.pg_tcs = (uint8_t)tx_conf->nb_tcs; dcb_config->num_tcs.pfc_tcs = (uint8_t)tx_conf->nb_tcs; + /* Initialize User Priority to Traffic Class mapping */ + for (j = 0; j < IXGBE_DCB_MAX_TRAFFIC_CLASS; j++) { + tc = &dcb_config->tc_config[j]; + tc->path[IXGBE_DCB_TX_CONFIG].up_to_tc_bitmap = 0; + } + /* User Priority to Traffic Class mapping */ for (i = 0; i < ETH_DCB_NUM_USER_PRIORITIES; i++) { j = tx_conf->dcb_tc[i]; tc = &dcb_config->tc_config[j]; - tc->path[IXGBE_DCB_TX_CONFIG].up_to_tc_bitmap = - (uint8_t)(1 << j); + tc->path[IXGBE_DCB_TX_CONFIG].up_to_tc_bitmap |= + (uint8_t)(1 << i); } } -- 2.11.0