From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-CO1-obe.outbound.protection.outlook.com (mail-co1nam03on0042.outbound.protection.outlook.com [104.47.40.42]) by dpdk.org (Postfix) with ESMTP id C88151B1C4 for ; Thu, 28 Sep 2017 14:19:45 +0200 (CEST) Received: from BN6PR03CA0022.namprd03.prod.outlook.com (10.168.230.160) by BN3PR03MB2353.namprd03.prod.outlook.com (10.166.74.148) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.77.7; Thu, 28 Sep 2017 12:19:44 +0000 Received: from BL2FFO11FD050.protection.gbl (2a01:111:f400:7c09::134) by BN6PR03CA0022.outlook.office365.com (2603:10b6:404:23::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.56.11 via Frontend Transport; Thu, 28 Sep 2017 12:19:43 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; nxp.com; dkim=none (message not signed) header.d=none;nxp.com; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.168.50 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (192.88.168.50) by BL2FFO11FD050.mail.protection.outlook.com (10.173.161.212) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.56.11 via Frontend Transport; Thu, 28 Sep 2017 12:19:44 +0000 Received: from Tophie.ap.freescale.net ([10.232.14.39]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id v8SCJ72B008785; Thu, 28 Sep 2017 05:19:42 -0700 From: Shreyansh Jain To: CC: , Date: Thu, 28 Sep 2017 17:59:38 +0530 Message-ID: <20170928123000.1711-19-shreyansh.jain@nxp.com> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20170928123000.1711-1-shreyansh.jain@nxp.com> References: <20170928113344.12248-1-shreyansh.jain@nxp.com> <20170928123000.1711-1-shreyansh.jain@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131510747842354335; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.168.50; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(7966004)(336005)(39860400002)(39380400002)(346002)(376002)(2980300002)(1110001)(1109001)(339900001)(199003)(189002)(33646002)(5003940100001)(189998001)(47776003)(81156014)(8936002)(356003)(8676002)(81166006)(6916009)(76176999)(53936002)(2950100002)(50986999)(2906002)(2351001)(77096006)(105606002)(106466001)(498600001)(305945005)(36756003)(6666003)(68736007)(50466002)(50226002)(48376002)(97736004)(1076002)(4326008)(54906003)(86362001)(104016004)(316002)(85426001)(8656003)(16586007)(5660300001); DIR:OUT; SFP:1101; SCL:1; SRVR:BN3PR03MB2353; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; A:1; MX:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BL2FFO11FD050; 1:IkCfQt0b1bQhrvoHKyWz1wKPViWG+zlyrGjYLPphH5duL26+szzN2+64po23qTEHEBHKUrQ1n6TiCmDhyxOg2Pvx4zsjbsgMY8rJSIs4rcOXcMrHUz/MEFv9CZw4vFFv MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 27a7cfc0-d235-43dc-bb40-08d5066b33be X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017052603199)(201703131430075)(201703131517081); SRVR:BN3PR03MB2353; X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2353; 3:yXPj2z1FgW/XjCEr3la46Odp6p/XlgOjYppYlTwX9nx9ZpwTd3dSkLsY8XMGhXyAuDRphHz0a+PHgDOffTq7PBme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8r3+9Yn7etzW/pzyiAg3VqFvh3LQeRjSRUnhxIEzh5O3KEGBk5I34i4sCsxSCDIrD440YDOm4ZFvoRpANFgU0LX2DzmLH6pF8gq5Gd5ApVgLTOb8r2m3FaTer2roAtzFw7E39oXD/HqLec= X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6095135)(2401047)(5005006)(8121501046)(10201501046)(3002001)(93006095)(93001095)(100000703101)(100105400095)(6055026)(6096035)(20161123556025)(20161123559100)(20161123565025)(20161123561025)(201703131430075)(201703131433075)(201703131441075)(201703131448075)(201703161259150)(20161123563025)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:BN3PR03MB2353; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(400006)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:BN3PR03MB2353; X-Forefront-PRVS: 0444EB1997 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN3PR03MB2353; 23:vuv3g0VZihR/OMhDz4D9bNleM58JXawi08M9W7x67?= =?us-ascii?Q?RnmOiyRklulZwlu6qswU5R5JyI/eY022x33uO6ffRYOszEmS9JbH7Z7F0H9A?= =?us-ascii?Q?o7bPUB3w2afF1KQkZMbiteS1ZaamSwVKYM2w2pIUbQ1JazMAN8YlgU8G66i7?= =?us-ascii?Q?d580CUZ6rZkvOhXhnZadN4+r0BRO24i5jcr+mN1HgoHsNR0+FaCClXHAwd4M?= =?us-ascii?Q?EDvtfI5pKfOjxmjorMH1hR/CiY3O41RCOWXrKfFhWhFC36l5Q1F7sO3Qj23q?= =?us-ascii?Q?Cca6O8PqrePQ/afk9lZgkgRb60i1VBs7jE3TWQiZGekk7bg73kJsEcs8yZib?= =?us-ascii?Q?pX3xbF17zhnK6o2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nostics: 1; BN3PR03MB2353; 6:q6PV03sRagmAlSqEfYXEaT/VKQwhQ8IkvalIaHjhZeRKx3CbN8t+87kG5IEFsc8sxImT2LLqjkBjf6S/2sGj731YZhVi0SPdzh6xisx6xVc7nqrdmQKShLoK9KCCk4Vi0oBvGsqbpAb+PvvcuGa7opMwMqOX3syHU8rcdooWyDQDst4gQA3TPpl5TUDtHRuKzIvNg2YgZOJBuqEATW+xJbhREEvYgBCrD7Y0nV9K1iS0izjrXW3TdsxCt+tzMF7V0eW+le+xtsWbK2+Y7s10nGDsEs7xUnr5YYkviG/LEyWQMLOm1yMaoM9Wd6CrOuJxHmhL58uDRS3wMZ/1iAefvA==; 5:2w9Wi/g4zymshUfQUjWsHRN1KlWNwuiYBG3hWu9hEQwgKulo9NiUhAgRJ12rAFB4MBgINUPw/BL1XnOpzCD8d8jXH4b7MSw3jC8KKKlTEYroXQab47IV350XOhk0oAUiDwtAc4zPnEMvRhfapN3s5w==; 24:6gH2F0ag/gJcLmbc1xzEeosIaUGJwYPrqVyC8eOYNOb4go1wi7AKFTOSWibjZq0V1tOdIJKrA7IvanhP6YxJXpvc5Nzj2NhIO9b6SRquPd4=; 7:LU/6BlWRt0NAmcv3/uqmTyCaAXFqlrbmaB9TcmLREIWYmalaUsmauuA/9YJR210q5+Mc/5gLnqk0fXkO+Iam1gcuLhMbpEGWYBBd+F+mjjKEAMpZ2c7YP1/L7KwTaRLmxWG27p6gtjkynZ+UpQ1pD+O+RKCL79iDS70hdSFdtc0878PqGX6IV6dwf3InzLd6IKUX4p7nz1Zys+/muIbC/9vMoHLk35Ca0gbD7Q3K17o= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Sep 2017 12:19:44.0638 (UTC) X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.168.50]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3PR03MB2353 Subject: [dpdk-dev] [PATCH v6 18/40] bus/dpaa: add DPAA mempool logging macros 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, 28 Sep 2017 12:19:46 -0000 Signed-off-by: Shreyansh Jain --- drivers/bus/dpaa/dpaa_bus.c | 5 +++++ drivers/bus/dpaa/rte_bus_dpaa_version.map | 1 + drivers/bus/dpaa/rte_dpaa_logs.h | 20 ++++++++++++++++++++ 3 files changed, 26 insertions(+) diff --git a/drivers/bus/dpaa/dpaa_bus.c b/drivers/bus/dpaa/dpaa_bus.c index 8017df3..dc2b3ad 100644 --- a/drivers/bus/dpaa/dpaa_bus.c +++ b/drivers/bus/dpaa/dpaa_bus.c @@ -70,6 +70,7 @@ #include int dpaa_logtype_bus; +int dpaa_logtype_mempool; struct rte_dpaa_bus rte_dpaa_bus; struct netcfg_info *dpaa_netcfg; @@ -452,4 +453,8 @@ dpaa_init_log(void) dpaa_logtype_bus = rte_log_register("bus.dpaa"); if (dpaa_logtype_bus >= 0) rte_log_set_level(dpaa_logtype_bus, RTE_LOG_NOTICE); + + dpaa_logtype_mempool = rte_log_register("mempool.dpaa"); + if (dpaa_logtype_mempool >= 0) + rte_log_set_level(dpaa_logtype_mempool, RTE_LOG_NOTICE); } diff --git a/drivers/bus/dpaa/rte_bus_dpaa_version.map b/drivers/bus/dpaa/rte_bus_dpaa_version.map index 853bc47..a2394b8 100644 --- a/drivers/bus/dpaa/rte_bus_dpaa_version.map +++ b/drivers/bus/dpaa/rte_bus_dpaa_version.map @@ -8,6 +8,7 @@ DPDK_17.11 { bman_new_pool; bman_query_free_buffers; bman_release; + dpaa_logtype_mempool; dpaa_netcfg; fman_ccsr_map_fd; fman_dealloc_bufs_mask_hi; diff --git a/drivers/bus/dpaa/rte_dpaa_logs.h b/drivers/bus/dpaa/rte_dpaa_logs.h index cc10937..5335fd8 100644 --- a/drivers/bus/dpaa/rte_dpaa_logs.h +++ b/drivers/bus/dpaa/rte_dpaa_logs.h @@ -36,6 +36,7 @@ #include extern int dpaa_logtype_bus; +extern int dpaa_logtype_mempool; #define DPAA_BUS_LOG(level, fmt, args...) \ rte_log(RTE_LOG_ ## level, dpaa_logtype_bus, "%s(): " fmt "\n", \ @@ -62,4 +63,23 @@ extern int dpaa_logtype_bus; #define DPAA_BUS_WARN(fmt, args...) \ DPAA_BUS_LOG(WARNING, fmt, ## args) +/* Mempool related logs */ + +#define DPAA_MEMPOOL_LOG(level, fmt, args...) \ + rte_log(RTE_LOG_ ## level, dpaa_logtype_mempool, "%s(): " fmt "\n", \ + __func__, ##args) + +#define MEMPOOL_INIT_FUNC_TRACE() DPAA_MEMPOOL_LOG(DEBUG, " >>") + +#define DPAA_MEMPOOL_DPDEBUG(fmt, args...) \ + RTE_LOG_DP(DEBUG, PMD, fmt, ## args) +#define DPAA_MEMPOOL_DEBUG(fmt, args...) \ + DPAA_MEMPOOL_LOG(DEBUG, fmt, ## args) +#define DPAA_MEMPOOL_ERR(fmt, args...) \ + DPAA_MEMPOOL_LOG(ERR, fmt, ## args) +#define DPAA_MEMPOOL_INFO(fmt, args...) \ + DPAA_MEMPOOL_LOG(INFO, fmt, ## args) +#define DPAA_MEMPOOL_WARN(fmt, args...) \ + DPAA_MEMPOOL_LOG(WARNING, fmt, ## args) + #endif /* _DPAA_LOGS_H_ */ -- 2.9.3