Rewrite IP ToS/DSCP: Add IP ToS/DSCP field rewrite feature
This commit is contained in:
1 parent
b008eb8126
commit
680f63b514
11 files changed
+506
-220
No files matched your search
@@ -263,6 +263,10 @@ ofp_print_action(struct ds *string, const struct ofp_action_header *ah,
|
||||
sizeof(struct ofp_action_nw_addr),
|
||||
sizeof(struct ofp_action_nw_addr),
|
||||
},
|
||||
[OFPAT_SET_NW_TOS] = {
|
||||
sizeof(struct ofp_action_nw_tos),
|
||||
sizeof(struct ofp_action_nw_tos),
|
||||
},
|
||||
[OFPAT_SET_TP_SRC] = {
|
||||
sizeof(struct ofp_action_tp_port),
|
||||
sizeof(struct ofp_action_tp_port),
|
||||
@@ -363,6 +367,12 @@ ofp_print_action(struct ds *string, const struct ofp_action_header *ah,
|
||||
break;
|
||||
}
|
||||
|
||||
case OFPAT_SET_NW_TOS: {
|
||||
struct ofp_action_nw_tos *nt = (struct ofp_action_nw_tos *)ah;
|
||||
ds_put_format(string, "mod_ip_tos:%d", nt->nw_tos);
|
||||
break;
|
||||
}
|
||||
|
||||
case OFPAT_SET_TP_SRC: {
|
||||
struct ofp_action_tp_port *ta = (struct ofp_action_tp_port *)ah;
|
||||
ds_put_format(string, "mod_tp_src:%d", ntohs(ta->tp_port));
|
||||
|
||||
Reference in new issue
Block a user