2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 14:25:26 +00:00

ofp-util: Support OFPP_LOCAL in enqueue actions.

According to the specification the enqueue action should refer to
"a valid physical port", or OFPP_IN_PORT.  It would be strange to
attach a queueing discipline to the local port, but I see no reason
to restrict it.
This commit is contained in:
Ethan Jackson
2011-11-18 19:00:34 -08:00
parent 5fe0ec3dfc
commit 82172632ad
2 changed files with 12 additions and 1 deletions

View File

@@ -2211,7 +2211,8 @@ validate_actions(const union ofp_action *actions, size_t n_actions,
case OFPUTIL_OFPAT_ENQUEUE:
port = ntohs(((const struct ofp_action_enqueue *) a)->port);
if (port >= max_ports && port != OFPP_IN_PORT) {
if (port >= max_ports && port != OFPP_IN_PORT
&& port != OFPP_LOCAL) {
error = ofp_mkerr(OFPET_BAD_ACTION, OFPBAC_BAD_OUT_PORT);
}
break;