mirror of
https://github.com/openvswitch/ovs
synced 2025-08-31 14:25:26 +00:00
ofp-actions: Support mixing "conjunction" and "note" actions.
It doesn't make sense to mix "conjunction" actions with most other kinds of actions. That's because flows with "conjunction" actions aren't ever actually executed, so any actions mixed up with them would never do anything useful. "note" actions are a little different because they never do anything useful anyway: they are just there to allow a controller to annotate flows. It makes as much sense to annotate a flow with "conjunction" actions as it does to annotate any other flow, so this commit makes this possible. Requested-by: Soner Sevinc <sevincs@vmware.com> Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Andy Zhou <azhou@nicira.com>
This commit is contained in:
@@ -5737,9 +5737,10 @@ ofpacts_verify(const struct ofpact ofpacts[], size_t ofpacts_len,
|
||||
|
||||
if (a->type == OFPACT_CONJUNCTION) {
|
||||
OFPACT_FOR_EACH (a, ofpacts, ofpacts_len) {
|
||||
if (a->type != OFPACT_CONJUNCTION) {
|
||||
VLOG_WARN("when conjunction action is present, it must be "
|
||||
"the only kind of action used (saw '%s' action)",
|
||||
if (a->type != OFPACT_CONJUNCTION && a->type != OFPACT_NOTE) {
|
||||
VLOG_WARN("\"conjunction\" actions may be used along with "
|
||||
"\"note\" but not any other kind of action "
|
||||
"(such as the \"%s\" action used here)",
|
||||
ofpact_name(a->type));
|
||||
return OFPERR_NXBAC_BAD_CONJUNCTION;
|
||||
}
|
||||
|
Reference in New Issue
Block a user