From 730389b6dc0c601884781da319086e89da5be378 Mon Sep 17 00:00:00 2001 From: Susant Sahani Date: Wed, 30 Nov 2016 16:24:42 +0530 Subject: As per use case we should allow ForwardDelaySec to be set as 0 (#4765) So let's set ForwardDelaySec to USEC_INFINITY . Reference: https://wiki.linuxfoundation.org/networking/bridge#does-dhcp-work-overthrough-a-bridge --- src/network/netdev/bridge.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/network/netdev') diff --git a/src/network/netdev/bridge.c b/src/network/netdev/bridge.c index 08e31b974f..9fdcb55376 100644 --- a/src/network/netdev/bridge.c +++ b/src/network/netdev/bridge.c @@ -72,7 +72,7 @@ static int netdev_bridge_post_create(NetDev *netdev, Link *link, sd_netlink_mess return log_netdev_error_errno(netdev, r, "Could not append IFLA_INFO_DATA attribute: %m"); /* convert to jiffes */ - if (b->forward_delay > 0) { + if (b->forward_delay != USEC_INFINITY) { r = sd_netlink_message_append_u32(req, IFLA_BR_FORWARD_DELAY, usec_to_jiffies(b->forward_delay)); if (r < 0) return log_netdev_error_errno(netdev, r, "Could not append IFLA_BR_FORWARD_DELAY attribute: %m"); @@ -160,6 +160,7 @@ static void bridge_init(NetDev *n) { b->mcast_snooping = -1; b->vlan_filtering = -1; b->stp = -1; + b->forward_delay = USEC_INFINITY; } const NetDevVTable bridge_vtable = { -- cgit v1.2.3-54-g00ecf