summaryrefslogtreecommitdiff
path: root/net/bridge/br_ioctl.c
diff options
context:
space:
mode:
authorScott Feldman <sfeldma@gmail.com>2015-10-08 19:23:19 -0700
committerDavid S. Miller <davem@davemloft.net>2015-10-12 05:20:20 -0700
commitc62987bbd8a1a1664f99e89e3959339350a6131e (patch)
tree3a7455b6ab6b25335c709662b078c2375b700900 /net/bridge/br_ioctl.c
parent464314ea6c119ebc22ee78453e63814453c31611 (diff)
downloadlinux-riscv-c62987bbd8a1a1664f99e89e3959339350a6131e.tar.gz
linux-riscv-c62987bbd8a1a1664f99e89e3959339350a6131e.tar.bz2
linux-riscv-c62987bbd8a1a1664f99e89e3959339350a6131e.zip
bridge: push bridge setting ageing_time down to switchdev
Use SWITCHDEV_F_SKIP_EOPNOTSUPP to skip over ports in bridge that don't support setting ageing_time (or setting bridge attrs in general). If push fails, don't update ageing_time in bridge and return err to user. If push succeeds, update ageing_time in bridge and run gc_timer now to recalabrate when to run gc_timer next, based on new ageing_time. Signed-off-by: Scott Feldman <sfeldma@gmail.com> Signed-off-by: Jiri Pirko <jiri@resnulli.us> Acked-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/bridge/br_ioctl.c')
-rw-r--r--net/bridge/br_ioctl.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/bridge/br_ioctl.c b/net/bridge/br_ioctl.c
index 8d423bc649b9..263b4de4de57 100644
--- a/net/bridge/br_ioctl.c
+++ b/net/bridge/br_ioctl.c
@@ -200,8 +200,7 @@ static int old_dev_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
if (!ns_capable(dev_net(dev)->user_ns, CAP_NET_ADMIN))
return -EPERM;
- br->ageing_time = clock_t_to_jiffies(args[1]);
- return 0;
+ return br_set_ageing_time(br, args[1]);
case BRCTL_GET_PORT_INFO:
{