From patchwork Mon Jan 29 08:10:43 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hemant Agrawal X-Patchwork-Id: 126154 Delivered-To: patch@linaro.org Received: by 10.46.84.92 with SMTP id y28csp2235585ljd; Mon, 29 Jan 2018 00:12:28 -0800 (PST) X-Google-Smtp-Source: AH8x227FtUwX6WUhYdeloMUDbk706WTgPoAP6MstUBr9MODj4gURURqru/jBAorvNSc9Fqf63HHR X-Received: by 10.223.150.208 with SMTP id u74mr7947764wrb.193.1517213548077; Mon, 29 Jan 2018 00:12:28 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1517213548; cv=none; d=google.com; s=arc-20160816; b=mNnNme7hxDNV0TivD5SLvm6e0Tv8I8Y75Kz/IhnsfAOJARqch1zO1WJ/ZQ5cu/jCc2 eQI9ZWJponx6PgAC6EmHaUb2F08t5OC7SOvcbiyAgz1yb1xLrhffyyhPCcL8FfZI5g6g 3oizUuR9fRuqA3/SQzrtbCBdZ8dJ2/j9+CkqDpE6YzkgmNd6g+nMCvhCFqJ219nWvnaP nsYfFHXIS2h115noli8H4uS0EXuvX0D1S76NZqkrsb7ql7NPz6MGiI9Z3kWgahonowcj 3lsq3qDr0jK52EDZT2hMvLFk8pNuJeAnVgks7n1/NX7uRBiff2epjpEzU+hJn9ZkRoCF NbKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:subject:spamdiagnosticmetadata :spamdiagnosticoutput:mime-version:references:in-reply-to:message-id :date:cc:to:from:dkim-signature:arc-authentication-results; bh=LTvacHxuTknv/lwzdxVfsMyW6MrYpAwb1y7v6taPJ84=; b=wDLSeW5bnyPU3R0pQ8lPaS/FP89s0F9EVgdp+E24Us+NJd23kq+3ab01MfwTEMIK5X QUi8slqyZ/Po8ZBkcaXNxCB0R1EydYo/pmjAyXirjVUhQQrvWy/jCZxd67YzCi0fxQCu TCGCdm17NcVFGxQTJgUud6jpu7ev0DLcJ9oPrDidribrCtnk+M7fTuKHwGBpodtGT8JL hThhh6al6+4Wg3Q4vecbTLrwwZkKsWaY8UCqdI6RILJPUCatCT2dDCFZT/0wAxDr38RT qj+RTE+IebguyM+xDCkaugkl3TAz+/C4RW5tIE6UolaQ1jamW7CLA2DYcOUo0vM0icWx Asqg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@nxp.com header.s=selector1 header.b=Gl3wvwo4; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from dpdk.org (dpdk.org. [92.243.14.124]) by mx.google.com with ESMTP id a11si7033772wmh.277.2018.01.29.00.12.27; Mon, 29 Jan 2018 00:12:28 -0800 (PST) Received-SPF: pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) client-ip=92.243.14.124; Authentication-Results: mx.google.com; dkim=fail header.i=@nxp.com header.s=selector1 header.b=Gl3wvwo4; spf=pass (google.com: domain of dev-bounces@dpdk.org designates 92.243.14.124 as permitted sender) smtp.mailfrom=dev-bounces@dpdk.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 4C60A1B32B; Mon, 29 Jan 2018 09:12:26 +0100 (CET) Received: from EUR01-DB5-obe.outbound.protection.outlook.com (mail-db5eur01on0073.outbound.protection.outlook.com [104.47.2.73]) by dpdk.org (Postfix) with ESMTP id 8DBB81B326 for ; Mon, 29 Jan 2018 09:12:20 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=LTvacHxuTknv/lwzdxVfsMyW6MrYpAwb1y7v6taPJ84=; b=Gl3wvwo4F3UuKwkw96D2Zs/nyLi3Zr5giHj+CbpgO1EA+0MGmBoe+dloy+a3g3p6BM5TQttlrn0JVCbUkYc32JnVQIxJH9ORcwSZ/OEQTP1weMg0+J4KTBbAFTpmVnlNcOBCnahouB/B2VzKXBRk6AaaJ7IP89jR737ZevCxcXw= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=hemant.agrawal@nxp.com; Received: from bf-netperf1.ap.freescale.net (192.88.169.1) by AM2PR04MB0756.eurprd04.prod.outlook.com (2a01:111:e400:8411::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.444.14; Mon, 29 Jan 2018 08:12:18 +0000 From: Hemant Agrawal To: thomas@monjalon.net, dev@dpdk.org Cc: jerin.jacob@caviumnetworks.com, olivier.matz@6wind.com, santosh.shukla@caviumnetworks.com Date: Mon, 29 Jan 2018 13:40:43 +0530 Message-Id: <1517213449-678-2-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1517213449-678-1-git-send-email-hemant.agrawal@nxp.com> References: <1516629083-13967-1-git-send-email-hemant.agrawal@nxp.com> <1517213449-678-1-git-send-email-hemant.agrawal@nxp.com> MIME-Version: 1.0 X-Originating-IP: [192.88.169.1] X-ClientProxiedBy: BM1PR01CA0094.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:1::34) To AM2PR04MB0756.eurprd04.prod.outlook.com (2a01:111:e400:8411::16) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 0d21f739-ee4b-4f15-258f-08d566f00470 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(4534165)(4627221)(201703031133081)(201702281549075)(48565401081)(5600026)(4604075)(2017052603307)(7153060)(7193020); SRVR:AM2PR04MB0756; X-Microsoft-Exchange-Diagnostics: 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2gJdeGdbDyBLw/ECFE/tOxx6/Um6eBOOk76MHrxQhp81SJ2TNfkz5J6nbFBdK0/GkQ2mO6FEITFQrr7MywuzsUR10UB+kMfjIyqdRss07DlfwY6fmi1zgWq5oFWggDAS+OOmBCHDZpuxHdDpRnuuXYdvup9GFABKUbxDPy0IBQ6NBZ7M7mXtazzR+9gIWBspebOVvNXS/QLUD9AEW3FGTBwUDq1i/uK9hRwIBeSpsXMJCDXD9o2wvYli0HUGXlR0AgBltDLM2c3LpSa3VDbifgvRdIyl/7ZZ38CZK0Qbh6L0aLxfP2gbvvLm2Ksp503Rj455yfCv86FdEftZFFzPxCv9h6XYym8Er0whPrBP7j03+pmNdy+; 4:PVQ2cHBVGCYxNAOAgQihpF/F75Md4nQLUBEM3E7d+FhewfUgYz+V4c6As4UYeZTVLzYOHsuyySrd/eENjuTy9lW6Cd5uR8WNS+OxaVJ7FXTpQeK+76SYqz8tta4C1F4mnWqcgmntZpaS2VIhYmRlqSEzgwNbqhtqfQS8Uy/k9bl7bBIiJ7BSL5O0Cn7sRBUzDniLFfP+Ik9veFXZSbVOonHoQXmugApSkQGBQv2KLK0SnexSFNgajZaE35LJxyYxBTDANSVvkIotr4KesMwWjd+yLuou81TQRJwQiE5OlV5mWrcL6wVOUS/1xgbl4iUC X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040501)(2401047)(5005006)(8121501046)(93006095)(93001095)(3231101)(944501161)(3002001)(10201501046)(6055026)(6041288)(20161123564045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123562045)(6072148)(201708071742011); SRVR:AM2PR04MB0756; BCL:0; PCL:0; RULEID:; SRVR:AM2PR04MB0756; X-Forefront-PRVS: 0567A15835 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(39860400002)(396003)(366004)(376002)(39380400002)(346002)(189003)(199004)(5660300001)(6486002)(4326008)(86362001)(16526019)(3846002)(105586002)(68736007)(36756003)(6116002)(76176011)(25786009)(6506007)(106356001)(386003)(305945005)(7736002)(51416003)(52116002)(97736004)(81156014)(81166006)(2906002)(50226002)(8676002)(47776003)(478600001)(8936002)(26005)(66066001)(316002)(16586007)(48376002)(6512007)(2950100002)(53936002)(186003)(50466002)(6666003); DIR:OUT; SFP:1101; SCL:1; SRVR:AM2PR04MB0756; H:bf-netperf1.ap.freescale.net; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM2PR04MB0756; 23:RCfe9AtSm8Yq30ngvi7sNTqhQBg2uWwyLxeRTtTY4?= OFjNI4SUSNOjwhd0bmflw32EawpE1WmDrRYmwnNOVOFOpvswzU83hwXfh9BtvokjrgcT/LdPdWmtIo5XXkhXdejoZtUM3HVfJXRnnUPcZtzbeQdaYKlIiU96Cf83tUvljbmVAi8O8hXKeB+hSfUmUJGUw4r2wCRg5EhT+pncovkzYkjqcyfPygJHqNobsJjt8Suj2zuyH7HZktomnDEwD9S2mrDebXRBY2OpNcrIui038nPrKrl62izhfJNuSt6OuJEO1zdFvVB7sSST1VziWxRWMq46BfNJ1fS4YMBx0wMvqxLn6GqLB3hntFZtowfpxaIKRPa59FSziZ8odipap54BD1PWY8qoD9l/TTjRe3KtTqj902nfomtjEGhIn4E6teAbBQygpk0Ew7XIQaM4ODKNJzjJorsC3VayB7QRh+UibDBJuJa2nE+RI5Ral5zTdhoc+rr3dBAgJI82FRdgBptYjfoTuQrFJJkB3mR/rm28xyE5RzK5Wb9CQJqh5FaSrUJrR8RbBRdcHYIpfaNXU+En5R8vhaQrsSgkWnT5z4UKArrb9ddEEcFiwYlXkTYGlAbhrRjAxwCkCCZ3ILIK0bHjn0qnRi7hhC7AhsD/hRIR7Y9NLMx9UJckPJPXv7KEGObeRm+3NF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11P5VrLnYA8=; 7:7+a5TnbSZz+knzm/EWLaqTo4a1bmIx2TH2/cBsVHveJ1jvmVZ2nckDA2rD2vIhrBmPUZyAlLZ4UbMtKkoEob0qfwe+d7WSS0yzAwfsDd18acC/QnX+LHnLKgwtyWUNExCDVHyKyCyLS7dEaI8V6+zXUNwEapAxLIkL/nYkr83NOHA3uf8pkcHECEC+XREmvcHsyqaxfyPkKozCwnN8muo8gW2TzXcPKbeW95vJ1iqTCy+sFKKBMeEV8YK9skXSGI SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 29 Jan 2018 08:12:18.3249 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 0d21f739-ee4b-4f15-258f-08d566f00470 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM2PR04MB0756 Subject: [dpdk-dev] [PATCH v7 1/7] eal: prefix mbuf pool ops name with user defined X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" This patch prefix the mbuf pool ops name with "user" to indicate that it is user defined. Signed-off-by: Hemant Agrawal Acked-by: Olivier Matz Acked-by: Santosh Shukla --- lib/librte_eal/bsdapp/eal/eal.c | 4 ++-- lib/librte_eal/common/eal_common_options.c | 2 +- lib/librte_eal/common/eal_internal_cfg.h | 3 ++- lib/librte_eal/linuxapp/eal/eal.c | 4 ++-- 4 files changed, 7 insertions(+), 6 deletions(-) -- 2.7.4 diff --git a/lib/librte_eal/bsdapp/eal/eal.c b/lib/librte_eal/bsdapp/eal/eal.c index 04cbd81..c602d02 100644 --- a/lib/librte_eal/bsdapp/eal/eal.c +++ b/lib/librte_eal/bsdapp/eal/eal.c @@ -114,7 +114,7 @@ int rte_cycles_vmware_tsc_map; const char * rte_eal_mbuf_default_mempool_ops(void) { - return internal_config.mbuf_pool_ops_name; + return internal_config.user_mbuf_pool_ops_name; } /* Return a pointer to the configuration structure */ @@ -397,7 +397,7 @@ eal_parse_args(int argc, char **argv) switch (opt) { case OPT_MBUF_POOL_OPS_NAME_NUM: - internal_config.mbuf_pool_ops_name = optarg; + internal_config.user_mbuf_pool_ops_name = optarg; break; case 'h': eal_usage(prgname); diff --git a/lib/librte_eal/common/eal_common_options.c b/lib/librte_eal/common/eal_common_options.c index 996a034..7a40414 100644 --- a/lib/librte_eal/common/eal_common_options.c +++ b/lib/librte_eal/common/eal_common_options.c @@ -218,7 +218,7 @@ eal_reset_internal_config(struct internal_config *internal_cfg) #endif internal_cfg->vmware_tsc_map = 0; internal_cfg->create_uio_dev = 0; - internal_cfg->mbuf_pool_ops_name = RTE_MBUF_DEFAULT_MEMPOOL_OPS; + internal_cfg->user_mbuf_pool_ops_name = RTE_MBUF_DEFAULT_MEMPOOL_OPS; } static int diff --git a/lib/librte_eal/common/eal_internal_cfg.h b/lib/librte_eal/common/eal_internal_cfg.h index c67685c..1169fcc 100644 --- a/lib/librte_eal/common/eal_internal_cfg.h +++ b/lib/librte_eal/common/eal_internal_cfg.h @@ -52,7 +52,8 @@ struct internal_config { volatile enum rte_intr_mode vfio_intr_mode; const char *hugefile_prefix; /**< the base filename of hugetlbfs files */ const char *hugepage_dir; /**< specific hugetlbfs directory to use */ - const char *mbuf_pool_ops_name; /**< mbuf pool ops name */ + const char *user_mbuf_pool_ops_name; + /**< user defined mbuf pool ops name */ unsigned num_hugepage_sizes; /**< how many sizes on this system */ struct hugepage_info hugepage_info[MAX_HUGEPAGE_SIZES]; }; diff --git a/lib/librte_eal/linuxapp/eal/eal.c b/lib/librte_eal/linuxapp/eal/eal.c index 229eec9..e8c7100 100644 --- a/lib/librte_eal/linuxapp/eal/eal.c +++ b/lib/librte_eal/linuxapp/eal/eal.c @@ -124,7 +124,7 @@ int rte_cycles_vmware_tsc_map; const char * rte_eal_mbuf_default_mempool_ops(void) { - return internal_config.mbuf_pool_ops_name; + return internal_config.user_mbuf_pool_ops_name; } /* Return a pointer to the configuration structure */ @@ -609,7 +609,7 @@ eal_parse_args(int argc, char **argv) break; case OPT_MBUF_POOL_OPS_NAME_NUM: - internal_config.mbuf_pool_ops_name = optarg; + internal_config.user_mbuf_pool_ops_name = optarg; break; default: