stream-ssl: Force CA cert file to be read when it appears during bootstrap.
[openvswitch] / lib / nx-match.c
index abc3b210a9238a0ac468e6bb40d427f65e65b7fd..f5d62de2f0349a3cadc0cc59016a4a9c88552037 100644 (file)
@@ -176,9 +176,6 @@ parse_nxm_entry(struct cls_rule *rule, const struct nxm_field *f,
         /* Metadata. */
     case NFI_NXM_OF_IN_PORT:
         flow->in_port = ntohs(get_unaligned_be16(value));
-        if (flow->in_port == OFPP_LOCAL) {
-            flow->in_port = ODPP_LOCAL;
-        }
         return 0;
 
         /* Ethernet header. */
@@ -198,10 +195,12 @@ parse_nxm_entry(struct cls_rule *rule, const struct nxm_field *f,
         } else if (eth_addr_equals(mask, eth_mcast_1)) {
             wc->wildcards &= ~FWW_ETH_MCAST;
             flow->dl_dst[0] = *(uint8_t *) value & 0x01;
+            return 0;
         } else if (eth_addr_equals(mask, eth_mcast_0)) {
             wc->wildcards &= ~FWW_DL_DST;
             memcpy(flow->dl_dst, value, ETH_ADDR_LEN);
             flow->dl_dst[0] &= 0xfe;
+            return 0;
         } else if (eth_addr_equals(mask, eth_all_0s)) {
             return 0;
         } else if (eth_addr_equals(mask, eth_all_1s)) {
@@ -678,7 +677,7 @@ nxm_put_eth(struct ofpbuf *b, uint32_t header,
 
 static void
 nxm_put_eth_dst(struct ofpbuf *b,
-                uint32_t wc, const uint8_t value[ETH_ADDR_LEN])
+                flow_wildcards_t wc, const uint8_t value[ETH_ADDR_LEN])
 {
     switch (wc & (FWW_DL_DST | FWW_ETH_MCAST)) {
     case FWW_DL_DST | FWW_ETH_MCAST:
@@ -737,9 +736,6 @@ nx_put_match(struct ofpbuf *b, const struct cls_rule *cr)
     /* Metadata. */
     if (!(wc & FWW_IN_PORT)) {
         uint16_t in_port = flow->in_port;
-        if (in_port == ODPP_LOCAL) {
-            in_port = OFPP_LOCAL;
-        }
         nxm_put_16(b, NXM_OF_IN_PORT, htons(in_port));
     }
 
@@ -1270,7 +1266,7 @@ nxm_read_field(const struct nxm_field *src, const struct flow *flow)
 {
     switch (src->index) {
     case NFI_NXM_OF_IN_PORT:
-        return flow->in_port == ODPP_LOCAL ? OFPP_LOCAL : flow->in_port;
+        return flow->in_port;
 
     case NFI_NXM_OF_ETH_DST:
         return eth_addr_to_uint64(flow->dl_dst);