From patchwork Thu Aug 18 08:07:29 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Ajmera, Megha" X-Patchwork-Id: 115225 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A16B8A034C; Thu, 18 Aug 2022 10:09:45 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7366D40694; Thu, 18 Aug 2022 10:09:45 +0200 (CEST) Received: from mga06.intel.com (mga06b.intel.com [134.134.136.31]) by mails.dpdk.org (Postfix) with ESMTP id 7D0DE410E7 for ; Thu, 18 Aug 2022 10:09:43 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1660810183; x=1692346183; h=from:to:subject:date:message-id:mime-version: content-transfer-encoding; bh=gXb7V3rD92/LmiLh5ZXubwxo+4Vrxm8Caddd8/vid80=; b=hCM9v9oip6CWL44RoCcpKD+VX8RdCZCf6aIw8joMc9Vm8Ab+RZt4I+lL qX0mms9GlqqS2e2Z04iw7RM/lE1Ad+woDn7Oy1U//0j8JexGW24MfZkFQ WtZB6nMtXlYqaUoOm/U8+/O4hVgElRshG01XVt2V5DEET+jmI+mLEG+Ls lOsllT6UrODRt8AISfSuMjYPVjQDZYUyBOuLJnKgLEwI14W/zFgD1YEHp VvBGecPMjLFsC79Ij58+DmFCmiLofZqtaUBSBSAOBuVsPghH/uUGAz9tj yPsOxr3aep/Zk4otEEpZh4arcn8Y5lUgBwBOgTnpw1hns5iYtypJR+GqS A==; X-IronPort-AV: E=McAfee;i="6500,9779,10442"; a="354436824" X-IronPort-AV: E=Sophos;i="5.93,245,1654585200"; d="scan'208";a="354436824" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by orsmga104.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Aug 2022 01:08:59 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.93,245,1654585200"; d="scan'208";a="667998611" Received: from unknown (HELO localhost.localdomain) ([10.190.213.60]) by fmsmga008.fm.intel.com with ESMTP; 18 Aug 2022 01:08:57 -0700 From: Megha Ajmera To: dev@dpdk.org, jasvinder.singh@intel.com, cristian.dumitrescu@intel.com Subject: [PATCH] sched: Support to config 100G rate to subport/pipe Date: Thu, 18 Aug 2022 08:07:29 +0000 Message-Id: <20220818080729.1455935-1-megha.ajmera@intel.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Currently in hqos tc rates, tb sizes can be configured upto 25G. Signed-off-by: Megha Ajmera --- examples/qos_sched/cfg_file.c | 64 +++++++++++++++++------------------ 1 file changed, 32 insertions(+), 32 deletions(-) diff --git a/examples/qos_sched/cfg_file.c b/examples/qos_sched/cfg_file.c index 450482f07d..cea041e69b 100644 --- a/examples/qos_sched/cfg_file.c +++ b/examples/qos_sched/cfg_file.c @@ -62,67 +62,67 @@ cfg_load_pipe(struct rte_cfgfile *cfg, struct rte_sched_pipe_params *pipe_params entry = rte_cfgfile_get_entry(cfg, pipe_name, "tb rate"); if (entry) - pipe_params[j].tb_rate = (uint64_t)atoi(entry); + pipe_params[j].tb_rate = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tb size"); if (entry) - pipe_params[j].tb_size = (uint64_t)atoi(entry); + pipe_params[j].tb_size = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc period"); if (entry) - pipe_params[j].tc_period = (uint64_t)atoi(entry); + pipe_params[j].tc_period = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 0 rate"); if (entry) - pipe_params[j].tc_rate[0] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[0] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 1 rate"); if (entry) - pipe_params[j].tc_rate[1] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[1] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 2 rate"); if (entry) - pipe_params[j].tc_rate[2] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[2] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 3 rate"); if (entry) - pipe_params[j].tc_rate[3] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[3] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 4 rate"); if (entry) - pipe_params[j].tc_rate[4] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[4] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 5 rate"); if (entry) - pipe_params[j].tc_rate[5] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[5] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 6 rate"); if (entry) - pipe_params[j].tc_rate[6] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[6] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 7 rate"); if (entry) - pipe_params[j].tc_rate[7] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[7] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 8 rate"); if (entry) - pipe_params[j].tc_rate[8] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[8] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 9 rate"); if (entry) - pipe_params[j].tc_rate[9] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[9] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 10 rate"); if (entry) - pipe_params[j].tc_rate[10] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[10] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 11 rate"); if (entry) - pipe_params[j].tc_rate[11] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[11] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 12 rate"); if (entry) - pipe_params[j].tc_rate[12] = (uint64_t)atoi(entry); + pipe_params[j].tc_rate[12] = atol(entry); entry = rte_cfgfile_get_entry(cfg, pipe_name, "tc 12 oversubscription weight"); if (entry) @@ -163,67 +163,67 @@ cfg_load_subport_profile(struct rte_cfgfile *cfg, entry = rte_cfgfile_get_entry(cfg, sec_name, "tb rate"); if (entry) - subport_profile[i].tb_rate = (uint64_t)atoi(entry); + subport_profile[i].tb_rate = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tb size"); if (entry) - subport_profile[i].tb_size = (uint64_t)atoi(entry); + subport_profile[i].tb_size = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc period"); if (entry) - subport_profile[i].tc_period = (uint64_t)atoi(entry); + subport_profile[i].tc_period = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 0 rate"); if (entry) - subport_profile[i].tc_rate[0] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[0] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 1 rate"); if (entry) - subport_profile[i].tc_rate[1] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[1] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 2 rate"); if (entry) - subport_profile[i].tc_rate[2] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[2] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 3 rate"); if (entry) - subport_profile[i].tc_rate[3] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[3] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 4 rate"); if (entry) - subport_profile[i].tc_rate[4] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[4] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 5 rate"); if (entry) - subport_profile[i].tc_rate[5] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[5] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 6 rate"); if (entry) - subport_profile[i].tc_rate[6] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[6] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 7 rate"); if (entry) - subport_profile[i].tc_rate[7] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[7] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 8 rate"); if (entry) - subport_profile[i].tc_rate[8] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[8] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 9 rate"); if (entry) - subport_profile[i].tc_rate[9] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[9] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 10 rate"); if (entry) - subport_profile[i].tc_rate[10] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[10] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 11 rate"); if (entry) - subport_profile[i].tc_rate[11] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[11] = atol(entry); entry = rte_cfgfile_get_entry(cfg, sec_name, "tc 12 rate"); if (entry) - subport_profile[i].tc_rate[12] = (uint64_t)atoi(entry); + subport_profile[i].tc_rate[12] = atol(entry); } return 0;