[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1469582642.4159.4.camel@perches.com>
Date: Tue, 26 Jul 2016 18:24:02 -0700
From: Joe Perches <joe@...ches.com>
To: Yuval Mintz <Yuval.Mintz@...gic.com>,
Ariel Elior <Ariel.Elior@...gic.com>,
everest-linux-l2@...gic.com
Cc: linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [PATCH] qed: Add and use specific logging functions to reduce
object size
On Tue, 2016-07-26 at 14:25 -0700, Joe Perches wrote:
> Current DP_ macros generate a lot of code.
> Using functions with vsprintf extension %pV helps reduce that size.
Yuval, I used the same KERN_<LEVEL> output types, but it
is unusual that DP_INFO outputs at KERN_NOTICE.
Was that a copy/paste defect or should it be emitted at
KERN_INFO and DP_VERBOSE be emitted at KERN_DEBUG?
> define DP_INFO(cdev, fmt, ...) \
> - do { \
> - if (unlikely((cdev)->dp_level <= QED_LEVEL_INFO)) { \
> - pr_notice("[%s:%d(%s)]" fmt, \
> - __func__, __LINE__, \
> - DP_NAME(cdev) ? DP_NAME(cdev) : "", \
> - ## __VA_ARGS__); \
> - } \
> - } while (0)
[]
> -#define DP_VERBOSE(cdev, module, fmt, ...) \
> - do { \
> - if (unlikely(((cdev)->dp_level <= QED_LEVEL_VERBOSE) && \
> - ((cdev)->dp_module & module))) { \
> - pr_notice("[%s:%d(%s)]" fmt, \
> - __func__, __LINE__, \
> - DP_NAME(cdev) ? DP_NAME(cdev) : "", \
> - ## __VA_ARGS__); \
> - } \
> - } while (0)
Powered by blists - more mailing lists