mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Steven Rostedt <rostedt@goodmis.org>
To: menglong8.dong@gmail.com
Cc: kuba@kernel.org, dsahern@kernel.org, idosch@idosch.org,
	nhorman@tuxdriver.com, davem@davemloft.net,
	netdev@vger.kernel.org, linux-kernel@vger.kernel.org,
	Menglong Dong <imagedong@tencent.com>
Subject: Re: [PATCH v6 net-next] net: drop_monitor: support drop reason
Date: Mon, 7 Feb 2022 09:43:01 -0500	[thread overview]
Message-ID: <20220207094301.5c061d23@gandalf.local.home> (raw)
In-Reply-To: <20220205081738.565394-1-imagedong@tencent.com>

On Sat,  5 Feb 2022 16:17:38 +0800
menglong8.dong@gmail.com wrote:

> --- a/net/core/drop_monitor.c
> +++ b/net/core/drop_monitor.c
> @@ -48,6 +48,16 @@
>  static int trace_state = TRACE_OFF;
>  static bool monitor_hw;
>  
> +#undef EM
> +#undef EMe
> +
> +#define EM(a, b)	[a] = #b,
> +#define EMe(a, b)	[a] = #b
> +
> +static const char *drop_reasons[SKB_DROP_REASON_MAX + 1] = {

Do you need to define the size above? Can't the compiler do it for you?

static const char *drop_reasons[] = {

-- Steve

> +	TRACE_SKB_DROP_REASON
> +};
> +
>  /* net_dm_mutex
>   *

  parent reply	other threads:[~2022-02-07 14:46 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-05  8:17 menglong8.dong
2022-02-06 11:26 ` Ido Schimmel
2022-02-08  2:54   ` Menglong Dong
2022-02-07 14:43 ` Steven Rostedt [this message]
2022-02-08  2:56   ` Menglong Dong

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=20220207094301.5c061d23@gandalf.local.home \
    --to=rostedt@goodmis.org \
    --cc=davem@davemloft.net \
    --cc=dsahern@kernel.org \
    --cc=idosch@idosch.org \
    --cc=imagedong@tencent.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=menglong8.dong@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=nhorman@tuxdriver.com \
    /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

all inboxes | Powered by JetHome®