From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <dev-bounces@dpdk.org>
Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124])
	by inbox.dpdk.org (Postfix) with ESMTP id 4632FA0542;
	Fri, 28 Oct 2022 11:58:51 +0200 (CEST)
Received: from [217.70.189.124] (localhost [127.0.0.1])
	by mails.dpdk.org (Postfix) with ESMTP id D2E7A40A80;
	Fri, 28 Oct 2022 11:58:50 +0200 (CEST)
Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31])
 by mails.dpdk.org (Postfix) with ESMTP id 3318440693;
 Fri, 28 Oct 2022 11:58:46 +0200 (CEST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple;
 d=intel.com; i=@intel.com; q=dns/txt; s=Intel;
 t=1666951126; x=1698487126;
 h=from:to:cc:subject:date:message-id:in-reply-to:
 references:mime-version:content-transfer-encoding;
 bh=vOy+JwaM+BVeewaR6VQ9tmYbSmVJQ7Rn5+pBwmvjd48=;
 b=aij38NvECSKJ6IeLiT7jQpGYPyXQhqMy+a5RUKu1bueP7HsDLHJttXuP
 A1POZzrbUYDLXCmJW6doiugnqZLt8USG+jf5TLY4MGIRIfolISqLpGnl0
 ewi3ZjiahLbq78cvSZOCyomSLYzIL2MEunxJ0kpR1zbwvs3uAeAwbR8Yo
 UijB2cfc3DJ2zkwHcgXNZ2ajz31woI8lPhfF0QsoO9WzZRVH34A+v1now
 L5hqSKdz6L6qjE6qO5GEgYiAgUooClb7sQ2KzNNc0vUE01QCGh+2fUSoc
 03oETvmEGAN5kZTxrzUf/GdpKl+0OvuEBfTyOXCHLJwAYwbMJEq03zDJA Q==;
X-IronPort-AV: E=McAfee;i="6500,9779,10513"; a="370523285"
X-IronPort-AV: E=Sophos;i="5.95,220,1661842800"; d="scan'208";a="370523285"
Received: from fmsmga002.fm.intel.com ([10.253.24.26])
 by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384;
 28 Oct 2022 02:58:45 -0700
X-ExtLoop1: 1
X-IronPort-AV: E=McAfee;i="6500,9779,10513"; a="738051308"
X-IronPort-AV: E=Sophos;i="5.95,220,1661842800"; d="scan'208";a="738051308"
Received: from unknown (HELO localhost.localdomain) ([10.190.213.60])
 by fmsmga002.fm.intel.com with ESMTP; 28 Oct 2022 02:58:43 -0700
From: Megha Ajmera <megha.ajmera@intel.com>
To: dev@dpdk.org, jasvinder.singh@intel.com, cristian.dumitrescu@intel.com,
 stephen@networkplumber.org
Cc: stable@dpdk.org
Subject: [PATCH v6 2/3] sched: fix number of subport profiles
Date: Fri, 28 Oct 2022 09:55:30 +0000
Message-Id: <20221028095531.678682-2-megha.ajmera@intel.com>
X-Mailer: git-send-email 2.25.1
In-Reply-To: <20221028095531.678682-1-megha.ajmera@intel.com>
References: <20221006190038.431828-1-megha.ajmera@intel.com>
 <20221028095531.678682-1-megha.ajmera@intel.com>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
Errors-To: dev-bounces@dpdk.org

Removed unused subport field from profile.cfg
Correctly using subport profile id in subport config load.

Fixes: 802d214dc880 ("examples/qos_sched: update subport rate dynamically")
Cc: stable@dpdk.org

Signed-off-by: Megha Ajmera <megha.ajmera@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
---
 examples/qos_sched/cfg_file.c  | 2 +-
 examples/qos_sched/profile.cfg | 2 --
 2 files changed, 1 insertion(+), 3 deletions(-)

diff --git a/examples/qos_sched/cfg_file.c b/examples/qos_sched/cfg_file.c
index 3d5d75fcf0..ca871d3287 100644
--- a/examples/qos_sched/cfg_file.c
+++ b/examples/qos_sched/cfg_file.c
@@ -157,7 +157,7 @@ cfg_load_subport_profile(struct rte_cfgfile *cfg,
 
 	profiles = rte_cfgfile_num_sections(cfg, "subport profile",
 					   sizeof("subport profile") - 1);
-	subport_params[0].n_pipe_profiles = profiles;
+	port_params.n_subport_profiles = profiles;
 
 	for (i = 0; i < profiles; i++) {
 		char sec_name[32];
diff --git a/examples/qos_sched/profile.cfg b/examples/qos_sched/profile.cfg
index c9ec187c93..e8de101b6c 100644
--- a/examples/qos_sched/profile.cfg
+++ b/examples/qos_sched/profile.cfg
@@ -26,8 +26,6 @@ number of subports per port = 1
 number of pipes per subport = 4096
 queue sizes = 64 64 64 64 64 64 64 64 64 64 64 64 64
 
-subport 0-8 = 0                ; These subports are configured with subport profile 0
-
 [subport profile 0]
 tb rate = 1250000000           ; Bytes per second
 tb size = 1000000              ; Bytes
-- 
2.25.1