From: Stefan Richter Date: Wed, 30 May 2007 05:33:47 +0000 (+0200) Subject: [PATCH] ieee1394: eth1394: bring back a parent device X-Git-Tag: v2.6.21.5~37 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=89f518f161a04e825e9143778521afe8c4c1adf0;p=thirdparty%2Fkernel%2Fstable.git [PATCH] ieee1394: eth1394: bring back a parent device This adds a real parent device to eth1394's ethX device like in Linux 2.6.20 and older. However, due to unfinished conversion of the ieee1394 away from class_device, we now refer to the FireWire controller's PCI device as the parent, not to the ieee1394 driver's fw-host device. Having a real parent device instead of a virtual one allows udev scripts to distinguish eth1394 interfaces from networking bridges, bondings and the likes. Fixes a regression since 2.6.21: https://bugs.gentoo.org/show_bug.cgi?id=177199 Signed-off-by: Stefan Richter Signed-off-by: Chris Wright Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/ieee1394/eth1394.c b/drivers/ieee1394/eth1394.c index 03e44b337eb01..6c819513a930d 100644 --- a/drivers/ieee1394/eth1394.c +++ b/drivers/ieee1394/eth1394.c @@ -584,10 +584,9 @@ static void ether1394_add_host (struct hpsb_host *host) } SET_MODULE_OWNER(dev); -#if 0 - /* FIXME - Is this the correct parent device anyway? */ - SET_NETDEV_DEV(dev, &host->device); -#endif + + /* This used to be &host->device in Linux 2.6.20 and before. */ + SET_NETDEV_DEV(dev, host->device.parent); priv = netdev_priv(dev);