From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0062.outbound.protection.outlook.com [104.47.38.62]) by dpdk.org (Postfix) with ESMTP id 39E0AF974 for ; Tue, 17 Jan 2017 14:20:03 +0100 (CET) Received: from BN6PR03CA0059.namprd03.prod.outlook.com (10.173.137.21) by CY1PR0301MB0745.namprd03.prod.outlook.com (10.160.159.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.845.12; Tue, 17 Jan 2017 13:20:02 +0000 Received: from BY2FFO11FD046.protection.gbl (2a01:111:f400:7c0c::175) by BN6PR03CA0059.outlook.office365.com (2603:10b6:404:4c::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.845.12 via Frontend Transport; Tue, 17 Jan 2017 13:20:01 +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;nxp.com; dkim=none (message not signed) header.d=none; 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 BY2FFO11FD046.mail.protection.outlook.com (10.1.15.170) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.803.8 via Frontend Transport; Tue, 17 Jan 2017 13:20:00 +0000 Received: from bf-netperf1.idc ([10.232.134.28]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id v0HDJ8mL021741; Tue, 17 Jan 2017 06:19:57 -0700 From: Hemant Agrawal To: CC: , , , , , , Hemant Agrawal Date: Wed, 18 Jan 2017 00:22:35 +0530 Message-ID: <1484679174-4174-15-git-send-email-hemant.agrawal@nxp.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1484679174-4174-1-git-send-email-hemant.agrawal@nxp.com> References: <1482988612-6638-1-git-send-email-shreyansh.jain@nxp.com> <1484679174-4174-1-git-send-email-hemant.agrawal@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131291328004739906; (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)(7916002)(336005)(39400400002)(39840400002)(39410400002)(39850400002)(39380400002)(39860400002)(39450400003)(2980300002)(1110001)(1109001)(339900001)(189002)(199003)(189998001)(626004)(86362001)(97736004)(5660300001)(6666003)(85426001)(54906002)(15650500001)(6916009)(110136003)(2950100002)(33646002)(81156014)(4326007)(50466002)(81166006)(8676002)(92566002)(68736007)(76176999)(106466001)(50986999)(8936002)(36756003)(48376002)(47776003)(50226002)(105606002)(77096006)(104016004)(5003940100001)(2906002)(356003)(2351001)(30001)(305945005)(8656002)(38730400001); DIR:OUT; SFP:1101; SCL:1; SRVR:CY1PR0301MB0745; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BY2FFO11FD046; 1:Y11a2Xh4UHl1W5SDnTIm2MpKYu47GazKbHiaJF/yppV96KaFzq3Bc40uybn+EX2vTzMnVjCMq348daIIAC8m8P94hoRvzCXtzqb+9HXvNu/LZW84jaPWpkTPFbNTd2iganIDWRog7p3XM99FbjwL7JMivIZ/U2zxIq4qvGTyc2Y8qmAq4COZ4g9GlPMfFaRYyK1cToNGAanGuAlKWEZRtbgYoFVS5bN/owOwMI4F/Gc0rs1VUzD6PJ5KbaC3xORq61vPToxSaOu3a4sF7UEdFd1d2Z/tUpDIyqTP+X7/2wQTq042bT4HWF5NzYmSGCPRVC2OJ9qleA+Fz05kiFXpHBToYc9FWwKtHTOIQGpXHbQddA8bhGl4wDVsjsepWMg9j6lLdqm0mWfQU0RqhqalK1ksIu/O2giype8fofzSeIofZDE55NwxhGKIp1OA4161in0BXdZxdJY7FDXAaUZyLst0eWJ8YNsb990RnlJg8lT3dhcahnrbaml37R/eQGy9/QzrX7lMJaG2zDnY+gQBi4Y48JPKLspX3PbYZ3esmcAN7yRy2cYz/tW8gvNfjDdnaDtKo7DW8zUCn5EFJqgKWni4XceXx+L541R95W6WxiZ5JnHHKIVAooVRfhug73Z2aPN931GFWIUPfFH2/Uq2O8RT77D6Ob5nsBZskLzYCLQE+e1aBX+0v2pDV4jbhmgY/AJDdg9udxh5G82/jupeYgJ/5VfEfCrmxpp/bvFw/Frrr9r0nZVY1PVpOBG7jsYH MIME-Version: 1.0 Content-Type: text/plain X-MS-Office365-Filtering-Correlation-Id: a108bf02-8884-4d94-d342-08d43edb8a46 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001); SRVR:CY1PR0301MB0745; X-Microsoft-Exchange-Diagnostics: 1; CY1PR0301MB0745; 3:qr+ejTqoHnEehC7YsK4M5gZ9l0zuzJElWDuEk/mxlXu4jkLWTU6edkN5/n5f9jryF88SsC0t1UV8jJuXj3sqLdg4sTUsbvZ53VNjlfxvVbo50x0efyZZ25QRvF5+KWB4fsTeBzH3RVjM9r3B7jW6whsSw0cGhQA5b7Ybx17PnD+8CnZsVeLyb/M+t5m0McRsWmsV2UbNO7iy/6LjdcaM2TdbxXEuk7SeHxRQelhaehHXl/+/P3HtZM1cDwmw8hkj74Zpd6AVpQMV1IZUM8Nhhih2ifd54KkkcPMwdDGpccrsHfdfTx5JSxSDZgsdMT8A7rQQd7gzMr3CA9lw4nIlby/JXQDQwoDpFzN8WRaxB2hu22B2W0rDrMTlH3p2Vzbn X-Microsoft-Exchange-Diagnostics: 1; CY1PR0301MB0745; 25:vplQTC5q0CC+wedaTRN6hbrjUnjitTJwcnRHoCXjzmtGlM7gY66mm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antispam-Report-Test: UriScan:(185117386973197); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6095060)(601004)(2401047)(5005006)(8121501046)(13017025)(13023025)(13024025)(13015025)(13018025)(10201501046)(3002001)(6055026)(6096035)(20161123565025)(20161123563025)(20161123556025)(20161123561025)(20161123559025); SRVR:CY1PR0301MB0745; BCL:0; PCL:0; RULEID:(400006); SRVR:CY1PR0301MB0745; X-Microsoft-Exchange-Diagnostics: 1; CY1PR0301MB0745; 4:V0x534FX4KXo04WEH0FD/QgM/9rM4IMhrqVOuuoSgmHJ2a766/YFjusqaKEhGxsyer7noCL0Alh2CNlxtK6+HpGcjcMk7a376HIeJkCglFtC5O2hkDKJZX5Nja9jhcDas9cy5eKMniLOKErtvLdap85AfrOMvts3yaowyw0NoKVCnypDKRa4G46P1wKzlbdYbWB6o7e33Tdil/cnPrQeDtJEdpKXYg3wBlURHvZlW7PsvvC7lEy+Qa5F1T1eWrh9S78tMLbSgoTrZ50yHP1OpuCY6HnYX21x5Bp86K/5mOfLKkgz2QEOSgUfKvU4DuoTdFAWylYRjDXsJmgJ0HojOJOpkSA+5OWfzuyIFoO5gXXd4dI089RoCsLXcoMFbWmI1l7ExxnkmoefqWnU1eHZypOeNigNkt17rUwFM7ZiN9jysDj7w3fYkHdQhPcqggtZOqE9+rJOHTBqWE+wZcIoHK9BYHTaXhz5D6rS6SwL+A53Y3wefUbfaK9QYUKjgrmQwVRB7LqonslFOA9y0fmxPOA73jLntNxFpVy8ohzrnPUzJzji2mlqLzHmmBgH9iH7+zIkN8sf08u07m7q+krqhwLR+Bi3iaPASeH0cD1XftommtRLt0k4Ug5pqM16nFA9TfR38pmzsI/iHWFEXal1HvjwtWXY+MZqNVJ/d8cEi8Ghmp1Pp06mp1SotXcGSsjp+t6NUQn2mYmD+QSLkenyppq1utvA6b4f5QbqwNMTBr7GWo/HzK5tFs3IcBI+o4qy X-Forefront-PRVS: 01901B3451 X-Microsoft-Exchange-Diagnostics: =?us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lYM3Cwxwc; 5:o+hiTGH8E31J9yc/kqRQwDgmGwnxODo1SxBhT5/vCcmWC8jxRAV5MRCKO6NYu8LEdoqUJiGFGWtYmBV3QMT1bhkJXbUG2BUKkQWIVsEZTMwCQ56t3421JyerkmGBbBSwvDxJi5O9dvEnp39nMwKeiTwIJmBe4YGnnV4PwFV7RS40rzUjz2740mqEyYk2zpOP; 24:/m6oAQC2VudDMbEvJ/J7wu1hWE3LGYkmWY0DH8slH3uO+dE1WziaMoylocDS+R11OedF3U/Tlotp0xcqsEFiBBzWdrL/sLfBv6qwAwIrLJ4= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY1PR0301MB0745; 7:IJzemAAw/TQe0ZNRFkd0UaFmiOg1iplseQusuJqLIXDBeUwzOyxfYDspQKR3NPAIkg1rg/xTLgNMakecKmctSWpH5AItkh1/mZ9/UuGNgXbXCyBZxpuc/WOUQEw8sOHMVZFzAJUE9bghUni3ZSUfsNX8XYnMW0FD5f6KtGI8x/sxx0MR2GO/g5ROT1C3x3i6G5IrjQHw6ZEufWP4OY3ABV9WI4UAfEfRkx7Wt8PtV0TgapMC+sHn9Dk9vlOKUtTh9dTV41wVliFBxQ9PUJEz5SF1ddC2sDaoP3u81feU2sprbp2D6phJRDOwsf+h3paff/3vvwSH1cX05cKWwFErylxjvnwuYhaz8+KMGAYOzEuMOm9ZG6dKPAbr5GsE4X7tArFZz5A+KWjT05X9PIpb6mkIFYqubRJBxTFFCyZghe6bNOYfAXLyL+nFR2UaR+VeHUOXfCoTX0uIlrvEi+0oKA== X-MS-Exchange-CrossTenant-OriginalArrivalTime: 17 Jan 2017 13:20:00.2711 (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: CY1PR0301MB0745 Subject: [dpdk-dev] [PATCHv4 14/33] bus/fslmc: add debug log message support 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: Tue, 17 Jan 2017 13:20:04 -0000 Signed-off-by: Hemant Agrawal --- config/common_base | 7 +++ config/defconfig_arm64-dpaa2-linuxapp-gcc | 5 ++ drivers/bus/fslmc/Makefile | 5 ++ drivers/bus/fslmc/fslmc_logs.h | 76 +++++++++++++++++++++++++++++++ drivers/common/dpaa2/qbman/Makefile | 5 ++ drivers/net/dpaa2/Makefile | 5 ++ drivers/net/dpaa2/dpaa2_ethdev.c | 9 +++- 7 files changed, 110 insertions(+), 2 deletions(-) create mode 100644 drivers/bus/fslmc/fslmc_logs.h diff --git a/config/common_base b/config/common_base index 9448a16..cced010 100644 --- a/config/common_base +++ b/config/common_base @@ -294,6 +294,13 @@ CONFIG_RTE_LIBRTE_FSLMC_BUS=n # Compile burst-oriented NXP DPAA2 PMD driver # CONFIG_RTE_LIBRTE_DPAA2_PMD=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_INIT=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_DRIVER=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_RX=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_TX=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_TX_FREE=n + +# # Compile burst-oriented VIRTIO PMD driver # CONFIG_RTE_LIBRTE_VIRTIO_PMD=y diff --git a/config/defconfig_arm64-dpaa2-linuxapp-gcc b/config/defconfig_arm64-dpaa2-linuxapp-gcc index 13c16c0..d3bc9d8 100644 --- a/config/defconfig_arm64-dpaa2-linuxapp-gcc +++ b/config/defconfig_arm64-dpaa2-linuxapp-gcc @@ -56,3 +56,8 @@ CONFIG_RTE_LIBRTE_FSLMC_BUS=y # Compile burst-oriented NXP DPAA2 PMD driver # CONFIG_RTE_LIBRTE_DPAA2_PMD=y +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_INIT=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_DRIVER=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_RX=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_TX=n +CONFIG_RTE_LIBRTE_DPAA2_DEBUG_TX_FREE=n diff --git a/drivers/bus/fslmc/Makefile b/drivers/bus/fslmc/Makefile index a5a05de..b74c333 100644 --- a/drivers/bus/fslmc/Makefile +++ b/drivers/bus/fslmc/Makefile @@ -35,8 +35,13 @@ include $(RTE_SDK)/mk/rte.vars.mk # LIB = librte_pmd_fslmcbus.a +ifeq ($(CONFIG_RTE_LIBRTE_DPAA2_DEBUG_INIT),y) +CFLAGS += -O0 -g +CFLAGS += "-Wno-error" +else CFLAGS += -O3 CFLAGS += $(WERROR_FLAGS) +endif CFLAGS += "-Wno-strict-aliasing" CFLAGS += -I$(RTE_SDK)/drivers/bus/fslmc diff --git a/drivers/bus/fslmc/fslmc_logs.h b/drivers/bus/fslmc/fslmc_logs.h new file mode 100644 index 0000000..a890e6c --- /dev/null +++ b/drivers/bus/fslmc/fslmc_logs.h @@ -0,0 +1,76 @@ +/*- + * BSD LICENSE + * + * Copyright (c) 2016 NXP. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * * Neither the name of NXP nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT + * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE + * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifndef _FSLMC_LOGS_H_ +#define _FSLMC_LOGS_H_ + +#define PMD_INIT_LOG(level, fmt, args...) \ + RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ##args) + +#ifdef RTE_LIBRTE_DPAA2_DEBUG_INIT +#define PMD_INIT_FUNC_TRACE() PMD_INIT_LOG(DEBUG, " >>") +#else +#define PMD_INIT_FUNC_TRACE() do { } while (0) +#endif + +#ifdef RTE_LIBRTE_DPAA2_DEBUG_RX +#define PMD_RX_LOG(level, fmt, args...) \ + RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args) +#else +#define PMD_RX_LOG(level, fmt, args...) do { } while (0) +#endif + +#ifdef RTE_LIBRTE_DPAA2_DEBUG_TX +#define PMD_TX_LOG(level, fmt, args...) \ + RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args) +#else +#define PMD_TX_LOG(level, fmt, args...) do { } while (0) +#endif + +#ifdef RTE_LIBRTE_DPAA2_DEBUG_TX_FREE +#define PMD_TX_FREE_LOG(level, fmt, args...) \ + RTE_LOG(level, PMD, "%s(): " fmt "\n", __func__, ## args) +#else +#define PMD_TX_FREE_LOG(level, fmt, args...) do { } while (0) +#endif + +#ifdef RTE_LIBRTE_DPAA2_DEBUG_DRIVER +#define PMD_DRV_LOG_RAW(level, fmt, args...) \ + RTE_LOG(level, PMD, "%s(): " fmt, __func__, ## args) +#else +#define PMD_DRV_LOG_RAW(level, fmt, args...) do { } while (0) +#endif + +#define PMD_DRV_LOG(level, fmt, args...) \ + PMD_DRV_LOG_RAW(level, fmt "\n", ## args) + +#endif /* _FSLMC_LOGS_H_ */ diff --git a/drivers/common/dpaa2/qbman/Makefile b/drivers/common/dpaa2/qbman/Makefile index a6f7ece..751e1e6 100644 --- a/drivers/common/dpaa2/qbman/Makefile +++ b/drivers/common/dpaa2/qbman/Makefile @@ -36,8 +36,13 @@ include $(RTE_SDK)/mk/rte.vars.mk # LIB = librte_pmd_dpaa2_qbman.a +ifeq ($(CONFIG_RTE_LIBRTE_DPAA2_DEBUG_INIT),y) +CFLAGS += -O0 -g +CFLAGS += "-Wno-error" +else CFLAGS += -O3 CFLAGS += $(WERROR_FLAGS) +endif CFLAGS += -I$(RTE_SDK)/drivers/common/dpaa2/qbman/include diff --git a/drivers/net/dpaa2/Makefile b/drivers/net/dpaa2/Makefile index 9e7f958..cfe51d6 100644 --- a/drivers/net/dpaa2/Makefile +++ b/drivers/net/dpaa2/Makefile @@ -36,8 +36,13 @@ include $(RTE_SDK)/mk/rte.vars.mk # LIB = librte_pmd_dpaa2.a +ifeq ($(CONFIG_RTE_LIBRTE_DPAA2_DEBUG_INIT),y) +CFLAGS += -O0 -g +CFLAGS += "-Wno-error" +else CFLAGS += -O3 CFLAGS += $(WERROR_FLAGS) +endif CFLAGS += -I$(RTE_SDK)/drivers/net/dpaa2 CFLAGS += -I$(RTE_SDK)/drivers/bus/fslmc diff --git a/drivers/net/dpaa2/dpaa2_ethdev.c b/drivers/net/dpaa2/dpaa2_ethdev.c index 2295f82..5f74a11 100644 --- a/drivers/net/dpaa2/dpaa2_ethdev.c +++ b/drivers/net/dpaa2/dpaa2_ethdev.c @@ -45,6 +45,7 @@ #include #include +#include #include #include "dpaa2_ethdev.h" @@ -54,6 +55,8 @@ static int dpaa2_dev_init(struct rte_eth_dev *eth_dev) { + PMD_INIT_FUNC_TRACE(); + /* For secondary processes, the primary has done all the work */ if (rte_eal_process_type() != RTE_PROC_PRIMARY) return 0; @@ -66,6 +69,8 @@ static int dpaa2_dev_uninit(struct rte_eth_dev *eth_dev __rte_unused) { + PMD_INIT_FUNC_TRACE(); + if (rte_eal_process_type() != RTE_PROC_PRIMARY) return -EPERM; @@ -96,8 +101,8 @@ sizeof(struct dpaa2_dev_priv), RTE_CACHE_LINE_SIZE); if (eth_dev->data->dev_private == NULL) { - RTE_LOG(CRIT, PMD, "Cannot allocate memzone for" - " private port data\n"); + PMD_INIT_LOG(CRIT, "Cannot allocate memzone for" + " private port data\n"); return -ENOMEM; } } -- 1.9.1