From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9A152A0528; Thu, 9 Jul 2020 16:13:14 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 0C99A1E95A; Thu, 9 Jul 2020 16:13:14 +0200 (CEST) Received: from mailout2.w1.samsung.com (mailout2.w1.samsung.com [210.118.77.12]) by dpdk.org (Postfix) with ESMTP id A0D5B1E956 for ; Thu, 9 Jul 2020 16:13:12 +0200 (CEST) Received: from eucas1p1.samsung.com (unknown [182.198.249.206]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20200709141312euoutp02d096a3f5b15dce29a98066dcae27c9ab~gGwi8LqFm2504525045euoutp02C for ; Thu, 9 Jul 2020 14:13:12 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20200709141312euoutp02d096a3f5b15dce29a98066dcae27c9ab~gGwi8LqFm2504525045euoutp02C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1594303992; bh=ZQ1HLqXD3jCCMg2mkWxmbqwuJEDfPu6o3njR0J0n/Fw=; h=Subject:To:Cc:From:Date:In-Reply-To:References:From; b=hLrvtFZdbIucDyZ1Z+jUDTlaeDSvS+mPNve4GEie3mE/7hyuFCzDOuagelz5jA3KX PSBj1mFOvm90fYOWv4eUm0DztI3Ul4tFktclSQdD1FL7KTX70l8T4qKAm2TPgQcMFB YU6JQmWsokMv192QzebC/rC/072EcjjTm+ST/q/I= Received: from eusmges1new.samsung.com (unknown [203.254.199.242]) by eucas1p2.samsung.com (KnoxPortal) with ESMTP id 20200709141312eucas1p21e0d234d99f6798443d763a8457b137f~gGwiy7Snq1246612466eucas1p2z; Thu, 9 Jul 2020 14:13:12 +0000 (GMT) Received: from eucas1p2.samsung.com ( [182.198.249.207]) by eusmges1new.samsung.com (EUCPMTA) with SMTP id D4.C9.06456.8F5270F5; Thu, 9 Jul 2020 15:13:12 +0100 (BST) Received: from eusmtrp1.samsung.com (unknown [182.198.249.138]) by eucas1p1.samsung.com (KnoxPortal) with ESMTPA id 20200709141311eucas1p177aad05654d9b38b967b3db113322272~gGwiXXc2O1954419544eucas1p1Q; Thu, 9 Jul 2020 14:13:11 +0000 (GMT) Received: from eusmgms1.samsung.com (unknown [182.198.249.179]) by eusmtrp1.samsung.com (KnoxPortal) with ESMTP id 20200709141311eusmtrp1f7a5111b322ae66a1a47ea29091a33ec~gGwiWzNA62977229772eusmtrp1I; Thu, 9 Jul 2020 14:13:11 +0000 (GMT) X-AuditID: cbfec7f2-7efff70000001938-c3-5f0725f85405 Received: from eusmtip1.samsung.com ( [203.254.199.221]) by eusmgms1.samsung.com (EUCPMTA) with SMTP id 15.E2.06314.7F5270F5; Thu, 9 Jul 2020 15:13:11 +0100 (BST) Received: from [106.210.88.70] (unknown [106.210.88.70]) by eusmtip1.samsung.com (KnoxPortal) with ESMTPA id 20200709141311eusmtip18b02f1e28f038397e2748e551ddbf6b9~gGwh-jFX-3154231542eusmtip1G; Thu, 9 Jul 2020 14:13:11 +0000 (GMT) To: Bruce Richardson Cc: Thomas Monjalon , dev@dpdk.org From: Lukasz Wojciechowski Message-ID: Date: Thu, 9 Jul 2020 16:13:10 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <20200709140914.GA680@bricha3-MOBL.ger.corp.intel.com> Content-Transfer-Encoding: 8bit Content-Language: en-US X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFupileLIzCtJLcpLzFFi42LZduzned0fquzxBl2/+SxurLK3ePdpO5PF pwcnWByYPX4tWMrqsXjPSyaPYzensQcwR3HZpKTmZJalFunbJXBl7O1yKugQrbjZ1MDYwLhI sIuRg0NCwESicU52FyMXh5DACkaJyfN/sEE4XxglXr+fA+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3CQ+n/gOFmcRUJHYuqYXzBYViJNY vmU+O0SNoMTJmU/AlnECLXv3/RkLxAIziXmbH0Itk5do3jobyhaXuPVkPtMERqFZSNpnIWmZ haRlFpKWBYwsqxhFUkuLc9Nziw31ihNzi0vz0vWS83M3MQKjZtuxn5t3MF7aGHyIUYCDUYmH d8d/tngh1sSy4srcQ4wSHMxKIrxOZ0/HCfGmJFZWpRblxxeV5qQWH2I0BXpuIrOUaHI+MKLz SuINTQ3NLSwNzY3Njc0slMR5OwQOxggJpCeWpGanphakFsH0MXFwSjUwRvKfiJ50/+uNqTdu fl3x53o6c9aGn6u6dK47CL7dJyha/Tvwj/atntXrL95corZI6vzmtrkVPqqe6/qPOU/6rssf l20eczmOOav4zcQI05dmgpdMdP9/+LcrfKt/vtdn4adP7kS2e6zW7OCTFr43d66a4ArXhOU9 Yr9YPnpGv15izBysvvxDqhJLcUaioRZzUXEiAC+w3NewAgAA X-CMS-MailID: 20200709141311eucas1p177aad05654d9b38b967b3db113322272 X-Msg-Generator: CA Content-Type: text/plain; charset="utf-8" X-RootMTR: 20200422214614eucas1p1044184e60bcb04469783ef0dd95091c1 X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20200422214614eucas1p1044184e60bcb04469783ef0dd95091c1 References: <20200417215739.23180-1-l.wojciechow@partner.samsung.com> <20200422214555.11837-1-l.wojciechow@partner.samsung.com> <20200422214555.11837-2-l.wojciechow@partner.samsung.com> <20200626165630.GA564@bricha3-MOBL.ger.corp.intel.com> <1f900349-6701-d355-9084-c97cf5dccb75@partner.samsung.com> <20200709140914.GA680@bricha3-MOBL.ger.corp.intel.com> Subject: Re: [dpdk-dev] [PATCH v2 1/3] config: introduce global rte debug flag 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" W dniu 09.07.2020 o 16:09, Bruce Richardson pisze: > On Thu, Jul 09, 2020 at 03:51:25PM +0200, Lukasz Wojciechowski wrote: >> W dniu 26.06.2020 o 18:56, Bruce Richardson pisze: >>> On Wed, Apr 22, 2020 at 11:45:53PM +0200, Lukasz Wojciechowski wrote: >>>> A new boolean meson build flag is introduced with this patch: rte_debug. >>>> To enable this option add -Drte_debug=true to the meson configure command. >>>> >>>> By enabling this flag the globaly defined macro RTE_DEBUG becomes >>>> defined. It should be used for enabling debug code in all dpdk project >>>> components. Using this flag allows to make additional checks or tests >>>> and provide additional logs even in performance sensitive parts of code. >>>> >>>> The flag is disabled by default. >>>> >>>> Additionally for all enabled to be built libraries >>>> a RTE_DEBUG_{library name} is defined and assigned a value 1. >>>> This standardize names of library specific debug macros. Those can >>>> be used also without rte_debug option by using CFLAGS="-D..." build >>>> parameter. >>>> >>>> Code put inside RTE_DEBUG* #ifdef sections should be also put inside >>>> if (rte_log_can_log(...)) condition to allow run-time filtering of >>>> sanity checks, validations, logs and dumps when using rte_debug option. >>>> >>>> Libraries will be adjusted to the change in separate patches. >>>> >>>> Suggested-by: Bruce Richardson >>>> Signed-off-by: Lukasz Wojciechowski >>> The drivers are missing debug flag options, which probably need to be >>> defined as _ e.g. RTE_DEBUG_NET_I40E, >>> RTE_DEBUG_EVENT_SW, etc. >> I added also flags for drivers constructed as you suggested (see v3). >> It might however be a bit tricky to differentiate library debug flags >> form drivers, e.g. >> RTE_DEBUG_MEMPOOL (library) vs RTE_DEBUG_MEMPOOL_DPAA (driver). >> >> If there is a need the macro names can be changed by adding _LIB_ or _DRV_. >> What do you think? > I don't think DRV is needed for the drivers, though perhaps LIB (or RTE) could > be added for the libs. I actually think that mempool is the only case where > we might have any confusion, for other device classes the library names > tend to have "dev" on the end, e.g. cryptodev, rawdev etc. maybe also with net > > So overall, I'd suggest it's not a problem, but if you want modify the lib > one. If it's not a problem, I'll leave it as it is for now. > > /Bruce > -- Lukasz Wojciechowski Principal Software Engineer Samsung R&D Institute Poland Samsung Electronics Office +48 22 377 88 25 l.wojciechow@partner.samsung.com