summaryrefslogtreecommitdiff
path: root/pfinet
diff options
context:
space:
mode:
authorSamuel Thibault <samuel.thibault@ens-lyon.org>2013-02-24 01:11:55 +0100
committerSamuel Thibault <samuel.thibault@ens-lyon.org>2013-02-24 01:11:55 +0100
commit25b928645df760156a58aa707da56eae66a4ae77 (patch)
tree342a1f705da0bc7a594a89cf6f921bc59e075775 /pfinet
parent9c1bdc1b967b625dba29bdb68aa338f95e705399 (diff)
Always set flags on ethernet interface
* pfinet/linux-src/net/core/dev.c (dev_change_flags): Call ethernet_change_flags. * pfinet/iioctl-ops.c (S_iioctl_siocsifflags): Do not call ethernet_change_flags after calling dev_change_flags.
Diffstat (limited to 'pfinet')
-rw-r--r--pfinet/iioctl-ops.c6
-rw-r--r--pfinet/linux-src/net/core/dev.c3
2 files changed, 4 insertions, 5 deletions
diff --git a/pfinet/iioctl-ops.c b/pfinet/iioctl-ops.c
index 9904b9b3..67776809 100644
--- a/pfinet/iioctl-ops.c
+++ b/pfinet/iioctl-ops.c
@@ -188,11 +188,7 @@ S_iioctl_siocsifflags (io_t port,
else if (!dev)
err = ENODEV;
else
- {
- err = dev_change_flags (dev, flags);
- if (!err)
- err = ethernet_change_flags (dev, flags);
- }
+ err = dev_change_flags (dev, flags);
pthread_mutex_unlock (&global_lock);
end_using_socket_port (user);
diff --git a/pfinet/linux-src/net/core/dev.c b/pfinet/linux-src/net/core/dev.c
index 92e105a1..ff16e827 100644
--- a/pfinet/linux-src/net/core/dev.c
+++ b/pfinet/linux-src/net/core/dev.c
@@ -1452,6 +1452,9 @@ int dev_change_flags(struct device *dev, unsigned flags)
dev_set_allmulti(dev, inc);
}
+ if (!ret)
+ ret = ethernet_change_flags(dev, dev->flags);
+
return ret;
}