login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2010
»
April
»
13
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge support netpoll
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: Cong Wang
Subject:
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge support netpoll
Date: Tuesday, April 13, 2010 - 1:57 am
Stephen Hemminger wrote:
quoted text
> On Mon, 12 Apr 2010 12:38:57 +0200 > Eric Dumazet <eric.dumazet@gmail.com> wrote: > >> Le lundi 12 avril 2010 à 18:37 +0800, Cong Wang a écrit : >>> Stephen Hemminger wrote: >>>> There is no protection on dev->priv_flags for SMP access. >>>> It would better bit value in dev->state if you are using it as control flag. >>>> >>>> Then you could use >>>> if (unlikely(test_and_clear_bit(__IN_NETPOLL, &skb->dev->state))) >>>> netpoll_send_skb(...) >>>> >>>> >>> Hmm, I think we can't use ->state here, it is not for this kind of purpose, >>> according to its comments. >>> >>> Also, I find other usages of IFF_XXX flags of ->priv_flags are also using >>> &, | to set or clear the flags. So there must be some other things preventing >>> the race... >> Yes, its RTNL that protects priv_flags changes, hopefully... >> > > The patch was not protecting priv_flags with RTNL. > For example.. > > > @@ -308,7 +312,9 @@ static void netpoll_send_skb(struct netp > tries > 0; --tries) { > if (__netif_tx_trylock(txq)) { > if (!netif_tx_queue_stopped(txq)) { > + dev->priv_flags |= IFF_IN_NETPOLL; > status = ops->ndo_start_xmit(skb, dev); > + dev->priv_flags &= ~IFF_IN_NETPOLL; > if (status == NETDEV_TX_OK) > txq_trans_update(txq);
Hmm, but I checked the bonding case (IFF_BONDING), it doesn't hold rtnl_lock. Strange. --
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[v3 Patch 1/3] netpoll: add generic support for bridge and ...
, Amerigo Wang
, (Wed Apr 7, 11:18 pm)
[v3 Patch 2/3] bridge: make bridge support netpoll
, Amerigo Wang
, (Wed Apr 7, 11:18 pm)
[v3 Patch 3/3] bonding: make bonding support netpoll
, Amerigo Wang
, (Wed Apr 7, 11:19 pm)
Re: [v3 Patch 2/3] bridge: make bridge support netpoll
, Stephen Hemminger
, (Thu Apr 8, 8:37 am)
Re: [v3 Patch 2/3] bridge: make bridge support netpoll
, Cong Wang
, (Thu Apr 8, 10:43 pm)
Re: [v3 Patch 2/3] bridge: make bridge support netpoll
, Cong Wang
, (Mon Apr 12, 3:37 am)
Re: [v3 Patch 2/3] bridge: make bridge support netpoll
, Eric Dumazet
, (Mon Apr 12, 3:38 am)
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge sup ...
, Stephen Hemminger
, (Mon Apr 12, 8:38 am)
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge sup ...
, Cong Wang
, (Tue Apr 13, 1:57 am)
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge sup ...
, Jay Vosburgh
, (Tue Apr 13, 9:52 am)
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge sup ...
, Stephen Hemminger
, (Tue Apr 13, 10:33 am)
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge sup ...
, Cong Wang
, (Wed Apr 14, 1:11 am)
Re: [Bonding-devel] [v3 Patch 2/3] bridge: make bridge sup ...
, Cong Wang
, (Wed Apr 14, 1:16 am)
Navigation
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Greg KH
Og dreams of kernels
Jens Axboe
[PATCH 31/33] Fusion: sg chaining support
Arnd Bergmann
Re: finding your own dead "CONFIG_" variables
Mark Brown
[PATCH 2/2] Subject: natsemi: Allow users to disable workaround for DspCfg reset
Tony Breeds
[LGUEST] Look in object dir for .config
git
:
Brian Downing
Re: Git in a Nutshell guide
John Benes
Re: master has some toys
Matthias Lederhofer
[PATCH 4/7] introduce GIT_WORK_TREE to specify the work tree
Alexander Sulfrian
[RFC/PATCH] RE: git calls SSH_ASKPASS even if DISPLAY is not set
Junio C Hamano
Re: Rss produced by git is not valid xml?
git-commits-head
:
Linux Kernel Mailing List
iSeries: fix section mismatch in iseries_veth
Linux Kernel Mailing List
ixbge: remove TX lock and redo TX accounting.
Linux Kernel Mailing List
ixgbe: fix several counter register errata
Linux Kernel Mailing List
b43: fix build with CONFIG_SSB_PCIHOST=n
Linux Kernel Mailing List
9p: block-based virtio client
linux-netdev
:
Michael Breuer
Re: [PATCH] af_packet: Don't use skb after dev_queue_xmit()
Michael Breuer
Re: [PATCH] af_packet: Don't use skb after dev_queue_xmit()
David Daney
[PATCH 5/7] Staging: Octeon Ethernet: Convert to NAPI.
Wolfgang Grandegger
[PATCH net-next v4 1/3] can: mscan: fix improper return if dlc < 8 in start_xmi...
Amit Kumar Salecha
[PATCHv3 NEXT 2/2] NET: Add Qlogic ethernet driver for CNA devices