netdev-linux: Fix pairing of rtnetlink register and unregister calls.
[openvswitch] / lib / ofp-print.c
index a49c3854c23a5224f528037a41ffdb2d549a525e..2d9e02657d7dd6f034bff7340a97930cb12649d2 100644 (file)
@@ -215,6 +215,7 @@ nx_action_len(enum nx_action_subtype subtype)
     case NXAST_REG_MOVE: return sizeof(struct nx_action_reg_move);
     case NXAST_REG_LOAD: return sizeof(struct nx_action_reg_load);
     case NXAST_NOTE: return -1;
+    case NXAST_SET_TUNNEL64: return sizeof(struct nx_action_set_tunnel64);
     default: return -1;
     }
 }
@@ -233,6 +234,7 @@ ofp_print_nx_action(struct ds *string, const struct nx_action_header *nah)
     }
 
     if (subtype <= TYPE_MAXIMUM(enum nx_action_subtype)) {
+        const struct nx_action_set_tunnel64 *nast64;
         const struct nx_action_set_tunnel *nast;
         const struct nx_action_set_queue *nasq;
         const struct nx_action_resubmit *nar;
@@ -278,6 +280,12 @@ ofp_print_nx_action(struct ds *string, const struct nx_action_header *nah)
             nxm_format_reg_load(load, string);
             return;
 
+        case NXAST_SET_TUNNEL64:
+            nast64 = (struct nx_action_set_tunnel64 *) nah;
+            ds_put_format(string, "set_tunnel64:%#"PRIx64,
+                          ntohll(nast64->tun_id));
+            return;
+
         case NXAST_SNAT__OBSOLETE:
         default:
             break;
@@ -1221,6 +1229,8 @@ ofp_print_nxst_flow_reply(struct ds *string, const struct ofp_header *oh)
         int match_len;
         int error;
 
+        ds_put_char(string, '\n');
+
         fs = ofpbuf_try_pull(&b, sizeof *fs);
         if (!fs) {
             ds_put_format(string, " ***%td leftover bytes at end***", b.size);
@@ -1276,7 +1286,6 @@ ofp_print_nxst_flow_reply(struct ds *string, const struct ofp_header *oh)
         ds_put_char(string, ' ');
         ofp_print_actions(string, (const struct ofp_action_header *) actions,
                           n_actions * sizeof *actions);
-        ds_put_char(string, '\n');
      }
 }