Netdev List
 help / color / mirror / Atom feed
From: David Miller <davem@davemloft.net>
To: f.fainelli@gmail.com
Cc: netdev@vger.kernel.org, olteanv@gmail.com,
	vladimir.oltean@nxp.com, kuba@kernel.org, ap420073@gmail.com,
	edumazet@google.com, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next v2] net: vlan: Avoid using BUG() in vlan_proto_idx()
Date: Fri, 25 Sep 2020 14:12:34 -0700 (PDT)	[thread overview]
Message-ID: <20200925.141234.274433220362171981.davem@davemloft.net> (raw)
In-Reply-To: <20200925002746.79571-1-f.fainelli@gmail.com>

From: Florian Fainelli <f.fainelli@gmail.com>
Date: Thu, 24 Sep 2020 17:27:44 -0700

> While we should always make sure that we specify a valid VLAN protocol
> to vlan_proto_idx(), killing the machine when an invalid value is
> specified is too harsh and not helpful for debugging. All callers are
> capable of dealing with an error returned by vlan_proto_idx() so check
> the index value and propagate it accordingly.
> 
> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
> ---
> Changes in v2:
> - changed signature to return int
> - changed message to use ntohs()
> - renamed an index variable to 'pidx' instead of 'pdix'

Applied, thanks Florian.

  reply	other threads:[~2020-09-25 21:12 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-25  0:27 [PATCH net-next v2] net: vlan: Avoid using BUG() in vlan_proto_idx() Florian Fainelli
2020-09-25 21:12 ` David Miller [this message]
2020-09-25 21:20   ` Vladimir Oltean
2020-09-28  2:14     ` Florian Fainelli

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=20200925.141234.274433220362171981.davem@davemloft.net \
    --to=davem@davemloft.net \
    --cc=ap420073@gmail.com \
    --cc=edumazet@google.com \
    --cc=f.fainelli@gmail.com \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=olteanv@gmail.com \
    --cc=vladimir.oltean@nxp.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