Skip to content

Commit

Permalink
IB/iser: Micro-optimize iser logging
Browse files Browse the repository at this point in the history
And fix a checkpatch warning.

Signed-off-by: Sagi Grimberg <sagig@mellanox.com>
Signed-off-by: Or Gerlitz <ogerlitz@mellanox.com>
Signed-off-by: Roland Dreier <roland@purestorage.com>
  • Loading branch information
Sagi Grimberg authored and Roland Dreier committed Dec 16, 2014
1 parent da64bdb commit 60e2090
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions drivers/infiniband/ulp/iser/iscsi_iser.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,30 +73,27 @@

#define iser_dbg(fmt, arg...) \
do { \
if (iser_debug_level > 2) \
if (unlikely(iser_debug_level > 2)) \
printk(KERN_DEBUG PFX "%s: " fmt,\
__func__ , ## arg); \
} while (0)

#define iser_warn(fmt, arg...) \
do { \
if (iser_debug_level > 0) \
if (unlikely(iser_debug_level > 0)) \
pr_warn(PFX "%s: " fmt, \
__func__ , ## arg); \
} while (0)

#define iser_info(fmt, arg...) \
do { \
if (iser_debug_level > 1) \
if (unlikely(iser_debug_level > 1)) \
pr_info(PFX "%s: " fmt, \
__func__ , ## arg); \
} while (0)

#define iser_err(fmt, arg...) \
do { \
printk(KERN_ERR PFX "%s: " fmt, \
__func__ , ## arg); \
} while (0)
#define iser_err(fmt, arg...) \
pr_err(PFX "%s: " fmt, __func__ , ## arg)

#define SHIFT_4K 12
#define SIZE_4K (1ULL << SHIFT_4K)
Expand Down

0 comments on commit 60e2090

Please sign in to comment.