Hi Pablo >-----Original Message----- >From: De Lara Guarch, Pablo [mailto:[email protected]] >Sent: 11 July 2018 17:44 >To: Verma, Shally <[email protected]> >Cc: [email protected]; Athreya, Narayana Prasad ><[email protected]>; Challa, Mahipal ><[email protected]>; Gupta, Ashish <[email protected]>; Sahu, >Sunila <[email protected]> >Subject: RE: [PATCH v2 1/5] compress/zlib: add ZLIB PMD support > >External Email > >And the last comments, sorry for the multiple replies.
No issues. > >> -----Original Message----- >> From: Shally Verma [mailto:[email protected]] >> Sent: Monday, July 2, 2018 5:57 PM >> To: De Lara Guarch, Pablo <[email protected]> >> Cc: [email protected]; [email protected]; >> [email protected]; Ashish Gupta >> <[email protected]>; Sunila Sahu >> <[email protected]> >> Subject: [PATCH v2 1/5] compress/zlib: add ZLIB PMD support >> >> From: Ashish Gupta <[email protected]> >> >> Add sw zlib pmd support in compressdev driver. >> Add device probe and remove support. >> Add ZLIB build file support. >> >> Signed-off-by: Sunila Sahu <[email protected]> >> Signed-off-by: Shally Verma <[email protected]> >> Signed-off-by: Ashish Gupta <[email protected]> > >... > >> +++ b/drivers/compress/zlib/zlib_pmd.c > >... > >> +static void >> +zlib_init_log(void) >> +{ >> + zlib_logtype_driver = rte_log_register("compress_zlib"); > >The standard for the name of the logtype for PMDs is >"pmd.driverType.driverName", >so in this case it would be "pmd.compress.zlib". > > >> + if (zlib_logtype_driver >= 0) >> + rte_log_set_level(zlib_logtype_driver, RTE_LOG_INFO); } >> diff --git a/drivers/compress/zlib/zlib_pmd_private.h >> b/drivers/compress/zlib/zlib_pmd_private.h >> new file mode 100644 >> index 0000000..d4c80b1 >> --- /dev/null >> +++ b/drivers/compress/zlib/zlib_pmd_private.h > >... > >> +#define ZLIB_PMD_INFO(fmt, args...) \ >> + ZLIB_PMD_LOG(INFO, fmt, ## args) >> +#define ZLIB_PMD_ERR(fmt, args...) \ >> + ZLIB_PMD_LOG(ERR, fmt, ## args) >> +#define ZLIB_PMD_WARN(fmt, args...) \ >> + ZLIB_PMD_LOG(WARNING, fmt, ## args) > >What do you think of having a single macro ZLIB_LOG(level, fmt, args...)? > I find it simpler to use ZLIB_PMD_INFO/ERR?DEBUG version . So would prefer to stick to them. Thanks for review. Shally

