netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: Roland Dreier <roland@kernel.org>
Cc: Or Gerlitz <or.gerlitz@gmail.com>,
	Eli Cohen <eli@dev.mellanox.co.il>,
	"linux-rdma@vger.kernel.org" <linux-rdma@vger.kernel.org>,
	Eli Cohen <eli@mellanox.com>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>
Subject: Re: [PATCH for-next 0/8] Add Mellanox mlx5 driver for Connect-IB devices
Date: Mon, 01 Jul 2013 13:19:02 -0700	[thread overview]
Message-ID: <1372709942.2481.13.camel@joe-AO722> (raw)
In-Reply-To: <CAL1RGDW_Z06ZqpOhz3tAkKn=rpLEZE6hWZkLNd9OQgCbrX6YAg@mail.gmail.com>

On Mon, 2013-07-01 at 11:11 -0700, Roland Dreier wrote:
> On Mon, Jul 1, 2013 at 11:03 AM, Joe Perches <joe@perches.com> wrote:
> > There's some value in block enabling/disabling messages
> > that dynamic_debug doesn't currently offer.
> 
> As far as I can see, the mlx5 stuff ends up being per-file.  Which
> dynamic debug already does offer.

I didn't look too closely.

I do think that all __func__, __LINE__ and pid bits are
useless as it's all duplicated dynamic_debug functionality.

+#define mlx5_core_dbg(dev, format, arg...)                                    \
+do {                                                                          \
+       if (debug_mask & mlx5_core_debug_mask)                                 \
+               pr_debug("%s:%s:%d:(pid %d): " format, (dev)->priv.name,       \
+                        __func__, __LINE__, current->pid, ##arg);             \
+} while (0)
+
+#define mlx5_core_dbg_mask(dev, mask, format, arg...)                         \
+do {                                                                          \
+       if ((mask) & mlx5_core_debug_mask)                                     \
+               pr_debug("%s:%s:%d:(pid %d): " format, (dev)->priv.name,       \
+                        __func__, __LINE__, current->pid, ##arg);             \
+} while (0)

btw:

mlx5_core_dbg should just be

#define mlx5_core_dbg(dev, fmt, ...)				\
	mlx5_core_dbg_mask(dev, debug_mask, fmt, ##__VA_ARGS__)

[]

I think these are the groupings.

+enum {
+       MLX5_MOD_MAIN,
+       MLX5_MOD_CMDIF,
+       MLX5_MOD_EQ,
+       MLX5_MOD_QP,
+       MLX5_MOD_PGALLOC,
+       MLX5_MOD_FW,
+       MLX5_MOD_UAR,
+       MLX5_MOD_ALLOC,
+       MLX5_MOD_DEBUG,
+       MLX5_MOD_HEALTH,
+       MLX5_MOD_MAD,
+       MLX5_MOD_MCG,
+       MLX5_MOD_MR,
+       MLX5_MOD_PD,
+       MLX5_MOD_PORT,
+       MLX5_MOD_SRQ,
+       MLX5_MOD_CQ,
+       MLX5_MOD_CMD_DATA, /* print command payload only */
+       MLX5_CMD_DATA_TIME,
+};
+

  reply	other threads:[~2013-07-01 20:19 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1371384149-24558-1-git-send-email-eli@dev.mellanox.co.il>
     [not found] ` <CAJZOPZ+NQa3CWnw3rZQh2UuwdrNhiwtVSyuk9D9YtwfQQ9e1XA@mail.gmail.com>
     [not found]   ` <CAJZOPZKLb9k1xXkTnrtzYKpwrSJDQgBpONUVCp3et36JeaEi-Q@mail.gmail.com>
     [not found]     ` <CAJZOPZKLb9k1xXkTnrtzYKpwrSJDQgBpONUVCp3et36JeaEi-Q-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-07-01 17:49       ` [PATCH for-next 0/8] Add Mellanox mlx5 driver for Connect-IB devices Roland Dreier
2013-07-01 18:03         ` Joe Perches
2013-07-01 18:11           ` Roland Dreier
2013-07-01 20:19             ` Joe Perches [this message]
2013-07-01 21:20               ` Roland Dreier
     [not found]                 ` <CAL1RGDVgSucpRhyxBZDVeLO+Q+Y7HuPsDjUy6kaFMoL3E8s77g-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-07-01 21:53                   ` Joe Perches
2013-07-02 21:02           ` Or Gerlitz
2013-07-02 21:03           ` Or Gerlitz
     [not found]         ` <CAL1RGDX5mHj5oVqFhQ4Ssr25jpL4rV2Tv=zXvLOZfwupJ0gqJw-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-07-01 18:03           ` Roland Dreier
     [not found]             ` <CAL1RGDXsgo9mHteu5MwqnoULd1jqE_LDZ=YfHMH4J=pRZqeLgQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-07-02 21:15               ` Or Gerlitz
2013-07-01 21:22           ` Roland Dreier
     [not found]             ` <CAL1RGDVQD_Uk0ZJse=Xc74nzAeUMAwYjYAhaPp2OJvgBD=TcOQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-07-02 20:59               ` Or Gerlitz
2013-07-03 16:41           ` Or Gerlitz
     [not found]             ` <51D45449.5010604-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
2013-07-03 19:26               ` Roland Dreier
2013-07-03 20:25                 ` Or Gerlitz
     [not found]                 ` <CAL1RGDU0JiGPFEAu87JbxxbHWbgZVsRz1qbz4BvqbCJU9RtRAA-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2013-07-07 12:08                   ` Jack Morgenstein
2013-07-02 21:36         ` Or Gerlitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1372709942.2481.13.camel@joe-AO722 \
    --to=joe@perches.com \
    --cc=eli@dev.mellanox.co.il \
    --cc=eli@mellanox.com \
    --cc=linux-rdma@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=or.gerlitz@gmail.com \
    --cc=roland@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).