From 6362203b08e8ee61d52cacdaf5550aefa42e4c84 Mon Sep 17 00:00:00 2001
From: YAMAMOTO Takashi <yamamoto@valinux.co.jp>
Date: Wed, 30 Apr 2014 10:10:12 +0900
Subject: [PATCH] ofproto-dpif-xlate: Fix in_port=controller case for NORMAL
 action

The problem mentioned by Simon Horman in the following mail.
http://openvswitch.org/pipermail/dev/2014-April/039492.html

Cc: Simon Horman <horms@verge.net.au>
Acked-by: Ben Pfaff <blp@nicira.com>
Signed-off-by: YAMAMOTO Takashi <yamamoto@valinux.co.jp>
---
 ofproto/ofproto-dpif-xlate.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/ofproto/ofproto-dpif-xlate.c b/ofproto/ofproto-dpif-xlate.c
index e2ac9adbc..2c34aa8d2 100644
--- a/ofproto/ofproto-dpif-xlate.c
+++ b/ofproto/ofproto-dpif-xlate.c
@@ -971,9 +971,10 @@ lookup_input_bundle(const struct xbridge *xbridge, ofp_port_t in_port,
         return xport->xbundle;
     }
 
-    /* Special-case OFPP_NONE, which a controller may use as the ingress
-     * port for traffic that it is sourcing. */
-    if (in_port == OFPP_NONE) {
+    /* Special-case OFPP_NONE (OF1.0) and OFPP_CONTROLLER (OF1.1+),
+     * which a controller may use as the ingress port for traffic that
+     * it is sourcing. */
+    if (in_port == OFPP_CONTROLLER || in_port == OFPP_NONE) {
         return &ofpp_none_bundle;
     }
 
-- 
2.47.0