[2/3] sched: removed unused subport field in hqos profile

Message ID 20221006190038.431828-2-megha.ajmera@intel.com (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series [1/3] sched: fix subport profile id not set correctly |

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Ajmera, Megha Oct. 6, 2022, 7 p.m. UTC
  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: cristian.dumitrescu@intel.com

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

Comments

Cristian Dumitrescu Oct. 11, 2022, 2:26 p.m. UTC | #1
> -----Original Message-----
> From: Ajmera, Megha <megha.ajmera@intel.com>
> Sent: Thursday, October 6, 2022 8:01 PM
> To: dev@dpdk.org; Singh, Jasvinder <jasvinder.singh@intel.com>;
> Dumitrescu, Cristian <cristian.dumitrescu@intel.com>
> Cc: stable@dpdk.org
> Subject: [PATCH 2/3] sched: removed unused subport field in hqos profile
> 
> 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: cristian.dumitrescu@intel.com
> 
> Signed-off-by: Megha Ajmera <megha.ajmera@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

Hi Megha,

Please fix:
-the title: "sched: fix number of subport profiles".
-add Cc: stable@dpdk.org, not Cc to me; you need to add me in the "To:" line of the email

Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>

Regards,
Cristian
  

Patch

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