From patchwork Fri Jul 22 17:47:08 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: stephen hemminger X-Patchwork-Id: 106363 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id 69B63B6F00 for ; Sat, 23 Jul 2011 03:51:03 +1000 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754329Ab1GVRu5 (ORCPT ); Fri, 22 Jul 2011 13:50:57 -0400 Received: from suva.vyatta.com ([76.74.103.44]:46800 "EHLO suva.vyatta.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754132Ab1GVRur (ORCPT ); Fri, 22 Jul 2011 13:50:47 -0400 Received: from suva.vyatta.com (suva [127.0.0.1]) by suva.vyatta.com (8.13.7/8.13.7) with ESMTP id p6MHlWIh020935; Fri, 22 Jul 2011 10:47:33 -0700 Received: (from shemminger@localhost) by suva.vyatta.com (8.13.7/8.13.7/Submit) id p6MHlWOA020934; Fri, 22 Jul 2011 10:47:32 -0700 Message-Id: <20110722174758.036523438@vyatta.com> User-Agent: quilt/0.48-1 Date: Fri, 22 Jul 2011 10:47:08 -0700 From: Stephen Hemminger To: "David S. Miller" Cc: netdev@vger.kernel.org Subject: [PATCH 3/5] bridge: notifier called with the wrong device References: <20110722174705.144993799@vyatta.com> Content-Disposition: inline; filename=br-notify-wrong-dev.patch Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org If a new device is added to a bridge, the ethernet address of the bridge network device may change. When the address changes, the appropriate callback is called, but with the wrong device argument. The address of the bridge device (ie br0) changes not the address of the device being passed to add_if (ie eth0). Signed-off-by: Stephen Hemminger --- Patch against net-next. Should go to stable. -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/net/bridge/br_if.c 2011-07-21 20:13:13.539989381 -0700 +++ b/net/bridge/br_if.c 2011-07-21 20:23:12.091989045 -0700 @@ -388,7 +388,7 @@ int br_add_if(struct net_bridge *br, str br_ifinfo_notify(RTM_NEWLINK, p); if (changed_addr) - call_netdevice_notifiers(NETDEV_CHANGEADDR, dev); + call_netdevice_notifiers(NETDEV_CHANGEADDR, br->dev); dev_set_mtu(br->dev, br_min_mtu(br));