From bd9bd56036db54652545c8d778adc2d6e59d0423 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Fri, 21 Nov 2008 10:48:00 -0800 Subject: [PATCH] Don't rate-limit packet_ins from flows that the controller set up. --- secchan/ratelimit.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/secchan/ratelimit.c b/secchan/ratelimit.c index 3736703e..e44352c3 100644 --- a/secchan/ratelimit.c +++ b/secchan/ratelimit.c @@ -160,6 +160,13 @@ rate_limit_local_packet_cb(struct relay *r, void *rl_) return false; } + if (opi->reason == OFPR_ACTION) { + /* Don't rate-limit 'ofp-packet_in's generated by flows that the + * controller set up. XXX we should really just rate-limit them + * *separately* so that no one can flood the controller this way. */ + return false; + } + if (!rl->n_queued && get_token(rl)) { /* In the common case where we are not constrained by the rate limit, * let the packet take the normal path. */ -- 2.30.2