public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Vladimir Oltean <vladimir.oltean@nxp.com>
To: Stephen Hemminger <stephen@networkplumber.org>
Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	"David S. Miller" <davem@davemloft.net>,
	Eric Dumazet <edumazet@google.com>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Andrew Lunn <andrew@lunn.ch>,
	Vivien Didelot <vivien.didelot@gmail.com>,
	Florian Fainelli <f.fainelli@gmail.com>,
	Jonathan Toppins <jtoppins@redhat.com>,
	Jay Vosburgh <j.vosburgh@gmail.com>,
	Veaceslav Falico <vfalico@gmail.com>,
	Hangbin Liu <liuhangbin@gmail.com>,
	Jamal Hadi Salim <jhs@mojatatu.com>,
	Cong Wang <xiyou.wangcong@gmail.com>,
	Jiri Pirko <jiri@resnulli.us>,
	Brian Hutchinson <b.hutchman@gmail.com>
Subject: Re: [PATCH v2 net] net/sched: make dev_trans_start() have a better chance of working with stacked interfaces
Date: Wed, 27 Jul 2022 16:17:25 +0000	[thread overview]
Message-ID: <20220727161725.jalgpkk4zvskdfh4@skbuf> (raw)
In-Reply-To: <20220727084404.34ebf5e6@hermes.local>

On Wed, Jul 27, 2022 at 08:44:04AM -0700, Stephen Hemminger wrote:
> On Wed, 27 Jul 2022 18:20:00 +0300
> Vladimir Oltean <vladimir.oltean@nxp.com> wrote:
> 
> > +	do {
> > +		have_lowers = false;
> > +
> > +		netdev_for_each_lower_dev(dev, lower, iter) {
> > +			have_lowers = true;
> > +			dev = lower;
> > +			break;
> > +		}
> > +	} while (have_lower
> 
> Would be clearer if this was a helper function.
> Something like dev_leaf_device?

Probably dev_leaf_device_rcu() I presume, so that the caller takes and
keeps the RCU critical section for as long as the leaf device is
actually being used, right?

      reply	other threads:[~2022-07-27 16:17 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-27 15:20 [PATCH v2 net] net/sched: make dev_trans_start() have a better chance of working with stacked interfaces Vladimir Oltean
2022-07-27 15:44 ` Stephen Hemminger
2022-07-27 16:17   ` Vladimir Oltean [this message]

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=20220727161725.jalgpkk4zvskdfh4@skbuf \
    --to=vladimir.oltean@nxp.com \
    --cc=andrew@lunn.ch \
    --cc=b.hutchman@gmail.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=f.fainelli@gmail.com \
    --cc=j.vosburgh@gmail.com \
    --cc=jhs@mojatatu.com \
    --cc=jiri@resnulli.us \
    --cc=jtoppins@redhat.com \
    --cc=kuba@kernel.org \
    --cc=liuhangbin@gmail.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=stephen@networkplumber.org \
    --cc=vfalico@gmail.com \
    --cc=vivien.didelot@gmail.com \
    --cc=xiyou.wangcong@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