All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Américo Wang" <xiyou.wangcong@gmail.com>
To: Adam Majer <adamm@zombino.com>
Cc: "Pekka Savola (ipv6)" <pekkas@netcore.fi>,
	Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>,
	netdev@vger.kernel.org, bridge@lists.linux-foundation.org,
	James Morris <jmorris@namei.org>,
	Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>,
	"David S. Miller" <davem@davemloft.net>,
	linux-kernel@vger.kernel.org
Subject: Re: [Bridge] [PATCH 1/2] Issue NETDEV_CHANGE notification when bridge changes state
Date: Wed, 9 Mar 2011 23:09:49 +0800	[thread overview]
Message-ID: <20110309150949.GE16951@cr0.redhat.com> (raw)
In-Reply-To: <20110306051833.GA3098@mira.lan.galacticasoftware.com>

On Sat, Mar 05, 2011 at 11:18:33PM -0600, Adam Majer wrote:
>
>IPv6 address autoconfiguration relies on an UP interface to processes
>traffic normally. A bridge that is UP enters LEARNING state and this
>state "eats" any Router Advertising packets sent to the
>bridge. Issuing a NETDEV_CHANGE notification on the bridge interface
>when it changes state allows autoconfiguration code to retry
>querying router information.
>
...

>+static void br_port_change_notifier_handler(struct work_struct *work)
>+{
>+	struct net_bridge *br = container_of(work,
>+					     struct net_bridge,
>+					     change_notification_worker);
>+
>+	rtnl_lock();
>+	netdev_state_change(br->dev);
>+	rtnl_unlock();
>+}
>+

Do you really want user-space to get this notification too?
Why do you put it into a workqueue? Maybe it has to be called in
process-context?

Thanks.

WARNING: multiple messages have this Message-ID (diff)
From: "Américo Wang" <xiyou.wangcong@gmail.com>
To: Adam Majer <adamm@zombino.com>
Cc: netdev@vger.kernel.org,
	Stephen Hemminger <shemminger@linux-foundation.org>,
	"David S. Miller" <davem@davemloft.net>,
	Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>,
	"Pekka Savola (ipv6)" <pekkas@netcore.fi>,
	James Morris <jmorris@namei.org>,
	Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>,
	Patrick McHardy <kaber@trash.net>,
	bridge@lists.linux-foundation.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] Issue NETDEV_CHANGE notification when bridge changes state
Date: Wed, 9 Mar 2011 23:09:49 +0800	[thread overview]
Message-ID: <20110309150949.GE16951@cr0.redhat.com> (raw)
In-Reply-To: <20110306051833.GA3098@mira.lan.galacticasoftware.com>

On Sat, Mar 05, 2011 at 11:18:33PM -0600, Adam Majer wrote:
>
>IPv6 address autoconfiguration relies on an UP interface to processes
>traffic normally. A bridge that is UP enters LEARNING state and this
>state "eats" any Router Advertising packets sent to the
>bridge. Issuing a NETDEV_CHANGE notification on the bridge interface
>when it changes state allows autoconfiguration code to retry
>querying router information.
>
...

>+static void br_port_change_notifier_handler(struct work_struct *work)
>+{
>+	struct net_bridge *br = container_of(work,
>+					     struct net_bridge,
>+					     change_notification_worker);
>+
>+	rtnl_lock();
>+	netdev_state_change(br->dev);
>+	rtnl_unlock();
>+}
>+

Do you really want user-space to get this notification too?
Why do you put it into a workqueue? Maybe it has to be called in
process-context?

Thanks.

  parent reply	other threads:[~2011-03-09 15:09 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-06  5:18 [Bridge] [PATCH 1/2] Issue NETDEV_CHANGE notification when bridge changes state Adam Majer
2011-03-06  5:18 ` Adam Majer
2011-03-06  5:20 ` [Bridge] [PATCH 2/2] Retry autoconfiguration on interface after NETDEV_CHANGE notification Adam Majer
2011-03-06  5:20   ` Adam Majer
2011-03-06  5:31 ` [Bridge] [PATCH 1/2] Issue NETDEV_CHANGE notification when bridge changes state Adam Majer
2011-03-06  5:31   ` Adam Majer
2011-03-06  6:43 ` [Bridge] " Stephen Hemminger
2011-03-06  6:43   ` Stephen Hemminger
2011-03-06  8:03   ` [Bridge] " Adam Majer
2011-03-06  8:03     ` Adam Majer
2011-03-06 17:45     ` [Bridge] " Stephen Hemminger
2011-03-06 17:45       ` Stephen Hemminger
2011-03-07  0:25       ` [Bridge] " Adam Majer
2011-03-07  0:25         ` Adam Majer
2011-03-07  6:41         ` [Bridge] " Stephen Hemminger
2011-03-07  6:41           ` Stephen Hemminger
2011-03-07  7:44           ` [Bridge] " Nicolas de Pesloüan
2011-03-07  7:44             ` Nicolas de Pesloüan
2011-03-07 18:34             ` [Bridge] [PATCH] bridge: control carrier based on ports online Stephen Hemminger
2011-03-07 18:34               ` Stephen Hemminger
2011-03-07 20:48               ` [Bridge] " Nicolas de Pesloüan
2011-03-07 20:48                 ` Nicolas de Pesloüan
2011-03-07 21:44                 ` [Bridge] " Stephen Hemminger
2011-03-07 21:44                   ` Stephen Hemminger
2011-03-07 21:51                   ` [Bridge] " Nicolas de Pesloüan
2011-03-07 21:51                     ` Nicolas de Pesloüan
2011-03-08  1:08               ` [Bridge] " Adam Majer
2011-03-08  1:08                 ` Adam Majer
2011-03-14 21:29               ` [Bridge] " David Miller
2011-03-14 21:29                 ` David Miller
2011-03-06 18:01     ` [Bridge] [PATCH 1/2] Issue NETDEV_CHANGE notification when bridge changes state Jan Ceuleers
2011-03-06 18:01       ` Jan Ceuleers
2011-03-09 15:09 ` Américo Wang [this message]
2011-03-09 15:09   ` Américo Wang
2011-03-09 16:44   ` [Bridge] " Adam Majer
2011-03-09 16:44     ` Adam Majer

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=20110309150949.GE16951@cr0.redhat.com \
    --to=xiyou.wangcong@gmail.com \
    --cc=adamm@zombino.com \
    --cc=bridge@lists.linux-foundation.org \
    --cc=davem@davemloft.net \
    --cc=jmorris@namei.org \
    --cc=kuznet@ms2.inr.ac.ru \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pekkas@netcore.fi \
    --cc=yoshfuji@linux-ipv6.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.