From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-eopbgr20077.outbound.protection.outlook.com [40.107.2.77]) by dpdk.org (Postfix) with ESMTP id 0950A1BDDF for ; Thu, 21 Jun 2018 11:45:53 +0200 (CEST) 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:X-MS-Exchange-SenderADCheck; bh=DoMIZs2eX5RH1Grvprfh3Z+pf+X8dcErySbnJWwOk0A=; b=REBJWo2KZXaDjQJJJAVf8k5o35V1h269Pwba1+eQXAxJpC4T0Si8YAwJiTixjYt51fvXWhr19CUIP6swS4m9lcK4ZEP9EO8ZKxUd6QOQs7ePpNpZHlivO9zKnsbPfvTJ3MrWfzKROFbL+YJFt/syic46ijs50GKvyrlLWPpE6so= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=hemant.agrawal@nxp.com; Received: from bf-netperf1.ap.freescale.net (14.142.187.166) by AM2PR04MB0755.eurprd04.prod.outlook.com (2a01:111:e400:8411::15) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.863.16; Thu, 21 Jun 2018 09:45:50 +0000 From: Hemant Agrawal To: dev@dpdk.org Cc: ferruh.yigit@intel.com, Pavan Nikhilesh Date: Thu, 21 Jun 2018 15:14:03 +0530 Message-Id: <1529574244-18997-9-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1529574244-18997-1-git-send-email-hemant.agrawal@nxp.com> References: <1529574244-18997-1-git-send-email-hemant.agrawal@nxp.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [14.142.187.166] X-ClientProxiedBy: BM1PR0101CA0035.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:1a::21) To AM2PR04MB0755.eurprd04.prod.outlook.com (2a01:111:e400:8411::15) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: e82e161c-1737-4d97-24cb-08d5d75bc66c X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(4534165)(7168020)(4627221)(201703031133081)(201702281549075)(5600026)(711020)(48565401081)(2017052603328)(7153060)(7193020); SRVR:AM2PR04MB0755; X-Microsoft-Exchange-Diagnostics: 1; AM2PR04MB0755; 3:FoS+xSA5Ebh83vd12LoiaZAqJFy/xqUwB8U1qNT4J3pjOkIUd/5Fcv4mBBRsXsz7wnhOEtP2Si7q5etYpuykzcZyq34IHnhXJUUCpE5iYJdoOagaokEu/uaodxD38JH2o8NZXR+BVY1GhN//1A3YlVlIXOXWnNpzvRdqHsCozMdAoYyDFt/sL0HM2llkwJLkzJPv4Ps/P2EfgQq1N4yAqaDy2Dcxosh1MRMD5xDlbT3rq4aagTOD7DezH6Ik1ENs; 25:zua21+0+giAS8oFPdsMfbHU7cDaR4aHha84c6ChnH+XNBIJAVh42+E4u+ddnB/kupvTtcGX6sOcB9OIcfEqRU/isrWSrDNHLQsc5sliEyp3AVy51vyjSkeK22ow/CmNzEaQtR3qfiMGgf/TT+nr4f6Wql3JjLVQk8WvMSTj2h/ChglP+k5Iw7CIvt+Tuc0Ocntezc6tuZujj0jAituaCKCuCmlzVPptvuwzyY3nIegif72MqfyDnnDpynatUhM9oKmCkykHdJuQ7NuWNtI7US0Hy86UAyqx0ycvvBlcqELY3eBMO5XuEVLn5ySBq8FHKRwlvW6ddIm9xJe3Mf20AGw==; 31:6QEYYXLLXH0WGU6IzV6kI2yssevxFyCoLPMgW7sReARRwhrTact0oMe4yhuEF2IWwu+qsqBOAsnO4ZyT39GTVC0X4LuYzT3rMXA7UCDzqDuXvuDHBlZszT80BitevhTfZLn1HmRV7EohHi9gt4IixSrs4tw+ckQWxPgq4t4yYsIq3+oFPT/uqn1a6taCAB1+8R4zJMYUSWTfcsSs9ak+rGWgPtBW3Ys4Zj5c646qbi0= X-MS-TrafficTypeDiagnostic: AM2PR04MB0755: X-Microsoft-Exchange-Diagnostics: 1; AM2PR04MB0755; 20:sCWvAtjL9s2mH3jt7UOsJoTeVvp4s5JyZtYKIdOGN8D/RIHF90nUfng7jOEYYIr1na62nUxGL+6GqKUQeMLINJuHUZZuVq4ThS/XhoyFzFQZAEfO1wAMrQNA3h55L0zHNfImV9MLd+nllcT2zgP7dcDlIVJZkZPDqIxFyqgVXGRqO8yrHRQVt3G+XxtVevs6dsJeBH4F3CtUCIC8kShoSSjAqxf7IF8oZRAfm7JSRuVUztw0Zf9yHRKO+dqYpD2wClUojWEiIvJvjbO9OXv8hD+paRuIHZv9gDDyfdfeXxdIHmu9WYMroHUWBmzqnr/2eZRrxtcmaQ4jiw1wx2GVbv2D0lZtz/aW8KP8EddofjiqppU5DlX96IhX7Xk/SiEQ4u0ZMwL8efUFQfzachE824HU+liSaQVixywbJMgRH0m7UjCS63t9GNgLTEas/pZRwp9y60ZR/4r0EuxT6kcHbaZbO4+PnCSE165uyI342OTWcbq6aLTRTSk+s7E5rRgv; 4:t+ovaYVVD7oSEF1KA/hWblm+KA2D9HKOYyV1FrCRYS62PUu1nDUW8EqB+qrVwUZHMLEmlKEmqTTIPopx4k0GTiNVu01gX6FKBwHtbkSKD/W679cVFYR5DcKMVxLFDMRDghMboCa7KjHE16sXp7zCQCaeV4EEAW86WQa+IC3BX3DbP40Rln39WLVtPzzKlUEAbXWTvO50TEnjwfTz+77mg2nU/3J9qRUFzqWBBeM91ftIQ00oFtdovxebJfxZiu21EweLpdfCTZK1v0eOLDPETtsVAYXoJQX1Z/5qfPJuCda+0rbM/Lke2Y3tl4dY/GtFiAufkEAxiN4qn/Ds8ZXh/887kRrJeSJo/nu3v8td0uA= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197)(275809806118684); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3231254)(944501410)(52105095)(10201501046)(93006095)(93001095)(3002001)(6055026)(149027)(150027)(6041310)(20161123564045)(20161123558120)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(6072148)(201708071742011)(7699016); SRVR:AM2PR04MB0755; BCL:0; PCL:0; RULEID:; SRVR:AM2PR04MB0755; X-Forefront-PRVS: 07106EF9B9 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(396003)(376002)(366004)(39860400002)(346002)(39380400002)(199004)(189003)(50466002)(6116002)(6506007)(55236004)(76176011)(59450400001)(2906002)(6512007)(478600001)(51416003)(48376002)(52116002)(3846002)(2361001)(186003)(26005)(16526019)(956004)(11346002)(97736004)(2351001)(5009440100003)(386003)(446003)(4326008)(8936002)(8676002)(476003)(486006)(7736002)(81156014)(81166006)(305945005)(16586007)(6916009)(6486002)(105586002)(106356001)(2616005)(47776003)(53936002)(36756003)(50226002)(44832011)(86362001)(68736007)(25786009)(5660300001)(316002)(6666003)(66066001)(110426005); DIR:OUT; SFP:1101; SCL:1; SRVR:AM2PR04MB0755; H:bf-netperf1.ap.freescale.net; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; Received-SPF: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; AM2PR04MB0755; 23:jZrnTqx2DnTjlkBCnPHZtnsK5b0QttlB2l8ZCaqyD?= =?us-ascii?Q?KKFe4dwMdfqsVN6tF6QUe3u/P/0F4iq4jzkRe9R0LSoNbBDP6QlPyqHwmHUw?= =?us-ascii?Q?S0GsxKLZ71bPisG0Dy6DKhKBzN6YEiF0qHurNncxBpPKXfReK6IGNlpun2eq?= =?us-ascii?Q?dSjb3pPXdLJB0xKZ9wVvGTo0HXBpImt54pDHpTO8s5Y4UJC3ti4NmDtc1b1R?= =?us-ascii?Q?44uDquu4dsajglYk3rSFLMK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7d?= =?us-ascii?Q?x/VIsSrqyG6DhXrheMi81xVqywAwb7+ujbdFzVN75liBLk6xW2VA8gnOKw8G?= =?us-ascii?Q?DvhNEp/858geDUdkvhynouMOgs96p5BAJNwaif1jgIK7RovcuYf4QrMbOPLe?= =?us-ascii?Q?IV9omU7Fu4bOQTYuSLoKg9FmJSx2pYeFwZ5O9YH1FmQNq9609YDreQt/bikj?= =?us-ascii?Q?31MRFdzvduespmbx24NHezlFutgZbgf+OUWZSzfMYWv?= X-Microsoft-Antispam-Message-Info: LymJyv4tc8xuehEyf8O7AigQhReNV6NkVeovtnNfIyS9YT9VABw6aANDJ/5t18TziijpoCX2orDg7qtHvKfHAydU9PpmY8BnLMEeaOI+9twXURS8+QraZ8i8R+0PNgNANPXblhfEmZWgr4fjEB6PMChUNqPOQQ2AuIxsVegwYa9ii9gSmfEBdIlQ9QaK/kdXLTZAyf0Ani0Kq7JxCPLjxXPw2d7TuhBDsVw+HfFuK3eF2FrG+ar9iH2Uc9F1Dc5lL1gASuiqbgZxXUnc795KU2H15Cbqg3E5+qa3sNYynPQtI8HgL9WDIRnSQcUzCsaXJVv6lQ5GOVpJ+nHp5+SS8g== X-Microsoft-Exchange-Diagnostics: 1; AM2PR04MB0755; 6:aqIndcXiq0INcWGfgMKUrOHf5byyRF4tJORBibVg3VCiObPStgh/dgJaitpw7PJlm2xEndZlEWVqnhPbNVAdL4Lk1gDE1FKcLI/Vz0ImlctHXqluLJ6MWZ4fz/ve3bFUY16l//L6WYz1lQxvbCt9NmFahwkUgbBemqaBpgnFoLiOmXSg0srYeNryzUm77UMf64BUsLQFF5uUUKie0gqHlpfiAAMngmpHd9lSHH+i0GofGkBYMFbiTE4pui3MRG2A8TKaBDcoNFU6BC5aHIJLA9H0CxsSpa8TkxlaK4HZYIPDi/0hgzuqkoz/qQ5JOiGweuTGD06MY4SiKeLs+DULChypA078sCBZ6+Je7CP5B4Vvt3W5uE3JUpOjv/4tZabHKF3L390+sshZ3oVGzPZg6TxjPugSrTRkkKdEY2aC+tV6/ciN6R6kw0aaa4ZldowTO1ay3qJGZ1mLry2hxg5DRA==; 5:bwXxSKQ962h/JbdcO2mvhcQlsZDaME4KxhwOEvK5OE9rK1nVe38xbjIguLF+MMcbqT+ePrgzx5vN74m0ZoLaOcgH5+E/54u6il/qkL9xAUVYtARlyli8WM2jiA24+guCVovoadiBmIPDk8BXHk8yegQRiqcT5sJmItB4akb6ISo=; 24:7CzDe52tJ/dnUjpmAxyn08o77WUuhE4RodHpdgPIAzoVAl21FMBTW3fj9c/+VgtskZtDfTBZSg7GfNtBzNVO1KHMqv4Znj6MQOC2a3avIOI= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; AM2PR04MB0755; 7:qEHdTFMrdoS5mZRlfmUYtexA/I+Frv8335pNgz5vcRTznAJyOUFp+M8o6pe2n9mnSQRoIZnL6Vvj0WQGLHLOrmZjwOCzhdnMNTLUYUbISbF7n4dxqxEMHImUHFss6IDakk3or+dNIMGSwn418M4o6hpee/hXrrhelX/c7cO/yGwYR2u1RB9ChhRD0dWh0ybwfa97qg0yaQjlx+QAQX3+hrRAk+elQWfJSjTR1MjPKCxjQ9FSMW+KiVR52odX+VmM X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 21 Jun 2018 09:45:50.5078 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: e82e161c-1737-4d97-24cb-08d5d75bc66c X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM2PR04MB0755 Subject: [dpdk-dev] [PATCH 09/10] bus/dpaa: cleanup unnecessary global variables 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: , X-List-Received-Date: Thu, 21 Jun 2018 09:45:53 -0000 Changes originally in the patch "drivers: cleanup unnecessary global variables" by Pavan. Signed-off-by: Pavan Nikhilesh Signed-off-by: Hemant Agrawal --- drivers/bus/dpaa/base/fman/netcfg_layer.c | 5 ----- drivers/bus/dpaa/base/qbman/bman_driver.c | 4 ++-- drivers/bus/dpaa/base/qbman/qman.c | 2 +- drivers/bus/dpaa/base/qbman/qman_driver.c | 4 ++-- drivers/bus/dpaa/base/qbman/qman_priv.h | 1 - drivers/bus/dpaa/dpaa_bus.c | 2 +- 6 files changed, 6 insertions(+), 12 deletions(-) diff --git a/drivers/bus/dpaa/base/fman/netcfg_layer.c b/drivers/bus/dpaa/base/fman/netcfg_layer.c index 3e956ce..031c6f1 100644 --- a/drivers/bus/dpaa/base/fman/netcfg_layer.c +++ b/drivers/bus/dpaa/base/fman/netcfg_layer.c @@ -18,11 +18,6 @@ #include #include -/* Structure contains information about all the interfaces given by user - * on command line. - */ -struct netcfg_interface *netcfg_interface; - /* This data structure contaings all configurations information * related to usages of DPA devices. */ diff --git a/drivers/bus/dpaa/base/qbman/bman_driver.c b/drivers/bus/dpaa/base/qbman/bman_driver.c index 1381da3..b14b590 100644 --- a/drivers/bus/dpaa/base/qbman/bman_driver.c +++ b/drivers/bus/dpaa/base/qbman/bman_driver.c @@ -15,9 +15,9 @@ /* * Global variables of the max portal/pool number this bman version supported */ -u16 bman_ip_rev; +static u16 bman_ip_rev; u16 bman_pool_max; -void *bman_ccsr_map; +static void *bman_ccsr_map; /*****************/ /* Portal driver */ diff --git a/drivers/bus/dpaa/base/qbman/qman.c b/drivers/bus/dpaa/base/qbman/qman.c index f5fe5ef..7c17027 100644 --- a/drivers/bus/dpaa/base/qbman/qman.c +++ b/drivers/bus/dpaa/base/qbman/qman.c @@ -625,7 +625,7 @@ struct qman_portal *qman_create_portal( #define MAX_GLOBAL_PORTALS 8 static struct qman_portal global_portals[MAX_GLOBAL_PORTALS]; -rte_atomic16_t global_portals_used[MAX_GLOBAL_PORTALS]; +static rte_atomic16_t global_portals_used[MAX_GLOBAL_PORTALS]; static struct qman_portal * qman_alloc_global_portal(void) diff --git a/drivers/bus/dpaa/base/qbman/qman_driver.c b/drivers/bus/dpaa/base/qbman/qman_driver.c index 07b29d5..f6ecd6b 100644 --- a/drivers/bus/dpaa/base/qbman/qman_driver.c +++ b/drivers/bus/dpaa/base/qbman/qman_driver.c @@ -20,9 +20,9 @@ u16 qm_channel_caam = QMAN_CHANNEL_CAAM; u16 qm_channel_pme = QMAN_CHANNEL_PME; /* Ccsr map address to access ccsrbased register */ -void *qman_ccsr_map; +static void *qman_ccsr_map; /* The qman clock frequency */ -u32 qman_clk; +static u32 qman_clk; static __thread int qmfd = -1; static __thread struct qm_portal_config qpcfg; diff --git a/drivers/bus/dpaa/base/qbman/qman_priv.h b/drivers/bus/dpaa/base/qbman/qman_priv.h index 9e4471e..02f6301 100644 --- a/drivers/bus/dpaa/base/qbman/qman_priv.h +++ b/drivers/bus/dpaa/base/qbman/qman_priv.h @@ -139,7 +139,6 @@ struct qm_portal_config { #define QMAN_REV31 0x0301 #define QMAN_REV32 0x0302 extern u16 qman_ip_rev; /* 0 if uninitialised, otherwise QMAN_REVx */ -extern u32 qman_clk; int qm_set_wpm(int wpm); int qm_get_wpm(int *wpm); diff --git a/drivers/bus/dpaa/dpaa_bus.c b/drivers/bus/dpaa/dpaa_bus.c index 7956bd0..5ba3d28 100644 --- a/drivers/bus/dpaa/dpaa_bus.c +++ b/drivers/bus/dpaa/dpaa_bus.c @@ -50,7 +50,7 @@ struct rte_dpaa_bus rte_dpaa_bus; struct netcfg_info *dpaa_netcfg; /* define a variable to hold the portal_key, once created.*/ -pthread_key_t dpaa_portal_key; +static pthread_key_t dpaa_portal_key; unsigned int dpaa_svr_family; -- 2.7.4