]> git.proxmox.com Git - mirror_ovs.git/commitdiff
ofproto: Fix NXAST_REG_MOVE with NXM_NX_TUN_ID as destination.
authorBen Pfaff <blp@nicira.com>
Wed, 19 Jan 2011 22:53:16 +0000 (14:53 -0800)
committerBen Pfaff <blp@nicira.com>
Wed, 19 Jan 2011 22:53:16 +0000 (14:53 -0800)
The documentation claimed this worked but it wasn't actually implemented.

ofproto/ofproto.c

index df5850f19d94473927311495b445f8d7ea2b9d25..3084c09e9bb3c2b376a2dcffda25269913e69377 100644 (file)
@@ -2863,12 +2863,16 @@ xlate_reg_move_action(struct action_xlate_ctx *ctx,
                       const struct nx_action_reg_move *narm)
 {
     ovs_be16 old_tci = ctx->flow.vlan_tci;
+    ovs_be64 old_tun = ctx->flow.tun_id;
 
     nxm_execute_reg_move(narm, &ctx->flow);
 
     if (ctx->flow.vlan_tci != old_tci) {
         xlate_set_dl_tci(ctx);
     }
+    if (ctx->flow.tun_id != old_tun) {
+        nl_msg_put_be64(ctx->odp_actions, ODPAT_SET_TUNNEL, ctx->flow.tun_id);
+    }
 }
 
 static void