From: sfeldma@gmail.com
To: netdev@vger.kernel.org
Cc: jiri@resnulli.us, siva.mannem.lnx@gmail.com,
pjonnala@broadcom.com, stephen@networkplumber.org,
roopa@cumulusnetworks.com, andrew@lunn.ch, f.fainelli@gmail.com,
vivien.didelot@savoirfairelinux.com
Subject: [PATCH net-next v2 3/7] bridge: define some min/max/default ageing time constants
Date: Sun, 20 Sep 2015 08:48:25 -0700 [thread overview]
Message-ID: <1442764109-11110-4-git-send-email-sfeldma@gmail.com> (raw)
In-Reply-To: <1442764109-11110-1-git-send-email-sfeldma@gmail.com>
From: Scott Feldman <sfeldma@gmail.com>
Signed-off-by: Scott Feldman <sfeldma@gmail.com>
---
v2: Per Jiri review comment: add BR_DEFAULT_AGEING_TIME to defines
include/linux/if_bridge.h | 6 ++++++
net/bridge/br_device.c | 2 +-
2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/include/linux/if_bridge.h b/include/linux/if_bridge.h
index dad8b00..a338a68 100644
--- a/include/linux/if_bridge.h
+++ b/include/linux/if_bridge.h
@@ -46,6 +46,12 @@ struct br_ip_list {
#define BR_LEARNING_SYNC BIT(9)
#define BR_PROXYARP_WIFI BIT(10)
+/* values as per ieee8021QBridgeFdbAgingTime */
+#define BR_MIN_AGEING_TIME (10 * HZ)
+#define BR_MAX_AGEING_TIME (1000000 * HZ)
+
+#define BR_DEFAULT_AGEING_TIME (300 * HZ)
+
extern void brioctl_set(int (*ioctl_hook)(struct net *, unsigned int, void __user *));
typedef int br_should_route_hook_t(struct sk_buff *skb);
diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c
index 6ed2feb..2f81624 100644
--- a/net/bridge/br_device.c
+++ b/net/bridge/br_device.c
@@ -391,7 +391,7 @@ void br_dev_setup(struct net_device *dev)
br->bridge_max_age = br->max_age = 20 * HZ;
br->bridge_hello_time = br->hello_time = 2 * HZ;
br->bridge_forward_delay = br->forward_delay = 15 * HZ;
- br->ageing_time = 300 * HZ;
+ br->ageing_time = BR_DEFAULT_AGEING_TIME;
br_netfilter_rtable_init(br);
br_stp_timer_init(br);
--
1.7.10.4
next prev parent reply other threads:[~2015-09-20 15:45 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-20 15:48 [PATCH net-next v2 0/7] bridge: don't age out externally added FDB entries sfeldma
2015-09-20 15:48 ` [PATCH net-next v2 1/7] rocker: track when FDB entry is touched sfeldma
2015-09-20 15:48 ` [PATCH net-next v2 2/7] rocker: store rocker_port in fdb key rather than pport sfeldma
2015-09-20 15:48 ` sfeldma [this message]
2015-09-21 6:49 ` [PATCH net-next v2 3/7] bridge: define some min/max/default ageing time constants Jiri Pirko
2015-09-20 15:48 ` [PATCH net-next v2 4/7] rocker: adding port ageing_time for ageing out FDB entries sfeldma
2015-09-21 6:49 ` Jiri Pirko
2015-09-20 15:48 ` [PATCH net-next v2 5/7] rocker: add FDB cleanup timer sfeldma
2015-09-22 0:11 ` David Miller
2015-09-20 15:48 ` [PATCH net-next v2 6/7] bridge: don't age externally added FDB entries sfeldma
2015-09-20 15:48 ` [PATCH net-next v2 7/7] switchdev: update documentation on FDB ageing_time sfeldma
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1442764109-11110-4-git-send-email-sfeldma@gmail.com \
--to=sfeldma@gmail.com \
--cc=andrew@lunn.ch \
--cc=f.fainelli@gmail.com \
--cc=jiri@resnulli.us \
--cc=netdev@vger.kernel.org \
--cc=pjonnala@broadcom.com \
--cc=roopa@cumulusnetworks.com \
--cc=siva.mannem.lnx@gmail.com \
--cc=stephen@networkplumber.org \
--cc=vivien.didelot@savoirfairelinux.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).