From: Vladimir Oltean <olteanv@gmail.com>
To: Jonathan McDowell <noodles@earth.li>
Cc: Andrew Lunn <andrew@lunn.ch>,
Vivien Didelot <vivien.didelot@gmail.com>,
Florian Fainelli <f.fainelli@gmail.com>,
David Miller <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Russell King - ARM Linux admin <linux@armlinux.org.uk>,
Matthew Hagan <mnhagan88@gmail.com>,
netdev@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH net-next v2] net: dsa: qca8k: Add 802.1q VLAN support
Date: Fri, 31 Jul 2020 00:10:19 +0300 [thread overview]
Message-ID: <20200730211019.lsqar5vbrxu5xw2u@skbuf> (raw)
In-Reply-To: <20200730104029.GB21409@earth.li>
On Thu, Jul 30, 2020 at 11:40:29AM +0100, Jonathan McDowell wrote:
> > > +
> > > + for (vid = vlan->vid_begin; vid <= vlan->vid_end && !ret; ++vid)
> > > + ret = qca8k_vlan_add(priv, port, vid, !untagged);
> > > +
> > > + if (ret)
> > > + dev_err(priv->dev, "Failed to add VLAN to port %d (%d)", port, ret);
> > > +
> >
> > If for some reason there is a temporary failure in qca8k_vlan_add, you'd
> > be swallowing it instead of printing the error and stopping the
> > execution.
>
> I don't follow; I'm breaking out of the for loop when we get an error? I
> figured that was a better move than potentially printing 4095 error
> messages if they were all going to fail.
>
Oh, you are. What an exotic way to write this loop, my brain stopped
parsing beyond "vid_end".
Thanks,
-Vladimir
next prev parent reply other threads:[~2020-07-30 21:10 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-21 17:16 [RFC PATCH] net: dsa: qca8k: Add 802.1q VLAN support Jonathan McDowell
2020-07-21 17:26 ` Florian Fainelli
2020-07-22 19:38 ` Jonathan McDowell
2020-07-22 22:36 ` Florian Fainelli
2020-07-22 22:58 ` Vladimir Oltean
2020-07-25 17:35 ` Jonathan McDowell
2020-07-21 20:48 ` Russell King - ARM Linux admin
2020-07-22 19:33 ` Jonathan McDowell
2020-07-26 14:56 ` [PATCH net-next v2] " Jonathan McDowell
2020-07-28 16:34 ` Vladimir Oltean
2020-07-30 10:40 ` Jonathan McDowell
2020-07-30 21:10 ` Vladimir Oltean [this message]
2020-08-01 17:05 ` [PATCH net-next v3 1/2] net: dsa: qca8k: Add define for port VID Jonathan McDowell
2020-08-01 20:48 ` Florian Fainelli
2020-08-02 13:21 ` Vladimir Oltean
2020-08-03 22:45 ` David Miller
2020-08-01 17:06 ` [PATCH net-next v3 2/2] net: dsa: qca8k: Add 802.1q VLAN support Jonathan McDowell
2020-08-01 20:50 ` Florian Fainelli
2020-08-02 13:21 ` Vladimir Oltean
2020-08-03 22:46 ` David Miller
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=20200730211019.lsqar5vbrxu5xw2u@skbuf \
--to=olteanv@gmail.com \
--cc=andrew@lunn.ch \
--cc=davem@davemloft.net \
--cc=f.fainelli@gmail.com \
--cc=kuba@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=mnhagan88@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=noodles@earth.li \
--cc=vivien.didelot@gmail.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;
as well as URLs for NNTP newsgroup(s).