X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fmatch.c;h=6d66ebaab5493b2a833b88347ee6c9939b01ae1b;hb=4e022ec09e14;hp=512253ec2e3c72d28b7913793012c0fd17786d9c;hpb=0ad90c845b7e82090a846fbe9f927e8d1c84cfc9;p=sliver-openvswitch.git diff --git a/lib/match.c b/lib/match.c index 512253ec2..6d66ebaab 100644 --- a/lib/match.c +++ b/lib/match.c @@ -271,10 +271,10 @@ match_set_tun_flags_masked(struct match *match, uint16_t flags, uint16_t mask) } void -match_set_in_port(struct match *match, uint16_t ofp_port) +match_set_in_port(struct match *match, ofp_port_t ofp_port) { - match->wc.masks.in_port = UINT16_MAX; - match->flow.in_port = ofp_port; + match->wc.masks.in_port.ofp_port = u16_to_ofp(UINT16_MAX); + match->flow.in_port.ofp_port = ofp_port; } void @@ -916,9 +916,9 @@ match_format(const struct match *match, struct ds *s, unsigned int priority) ntohll(f->metadata), ntohll(wc->masks.metadata)); break; } - if (wc->masks.in_port) { + if (wc->masks.in_port.ofp_port) { ds_put_cstr(s, "in_port="); - ofputil_format_port(f->in_port, s); + ofputil_format_port(f->in_port.ofp_port, s); ds_put_char(s, ','); } if (wc->masks.vlan_tci) {