From: Ben Pfaff Date: Fri, 6 Jun 2014 04:37:04 +0000 (-0700) Subject: ovs-ofctl: Support "send_flow_rem" in "learn" actions. X-Git-Tag: v2.4.0~2023 X-Git-Url: http://git.cascardo.eti.br/?a=commitdiff_plain;h=3d6832c2bdf5070ca92963830517587e1bc8b2a2;p=cascardo%2Fovs.git ovs-ofctl: Support "send_flow_rem" in "learn" actions. This flag was overlooked when support for the "learn" action was added. (It was always supported in the OpenFlow code, just not in the ovs-ofctl interface.) Signed-off-by: Ben Pfaff Acked-by: Thomas Graf --- diff --git a/lib/learn.c b/lib/learn.c index 8727a5539..ef9fab993 100644 --- a/lib/learn.c +++ b/lib/learn.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011, 2012, 2013 Nicira, Inc. + * Copyright (c) 2011, 2012, 2013, 2014 Nicira, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -580,6 +580,8 @@ learn_parse__(char *orig, char *arg, struct ofpbuf *ofpacts) learn->fin_hard_timeout = atoi(value); } else if (!strcmp(name, "cookie")) { learn->cookie = strtoull(value, NULL, 0); + } else if (!strcmp(name, "send_flow_rem")) { + learn->flags |= OFPFF_SEND_FLOW_REM; } else { struct ofpact_learn_spec *spec; char *error; @@ -654,7 +656,7 @@ learn_format(const struct ofpact_learn *learn, struct ds *s) ds_put_format(s, ",priority=%"PRIu16, learn->priority); } if (learn->flags & OFPFF_SEND_FLOW_REM) { - ds_put_cstr(s, ",OFPFF_SEND_FLOW_REM"); + ds_put_cstr(s, ",send_flow_rem"); } if (learn->cookie != 0) { ds_put_format(s, ",cookie=%#"PRIx64, learn->cookie); diff --git a/utilities/ovs-ofctl.8.in b/utilities/ovs-ofctl.8.in index d26d484c0..ad9fe783e 100644 --- a/utilities/ovs-ofctl.8.in +++ b/utilities/ovs-ofctl.8.in @@ -1477,8 +1477,9 @@ specified. .IQ \fBhard_timeout=\fIseconds\fR .IQ \fBpriority=\fIvalue\fR .IQ \fBcookie=\fIvalue\fR -These key-value pairs have the same meaning as in the usual -\fBovs\-ofctl\fR flow syntax. +.IQ \fBsend_flow_rem\fR +These arguments have the same meaning as in the usual \fBovs\-ofctl\fR +flow syntax. . .IP \fBfin_idle_timeout=\fIseconds\fR .IQ \fBfin_hard_timeout=\fIseconds\fR