On Wed, Aug 08, 2012 at 05:04:01PM -0700, Ben Pfaff wrote: > On Wed, Aug 08, 2012 at 06:49:45AM +0900, Simon Horman wrote: > > Signed-off-by: Simon Horman <ho...@verge.net.au> > > > + bad_in_port_err = OFPERR_OFPBMC_BAD_VALUE; > > Oh, I see, I misunderstood that there *was* a reasonable error code in > other versions of OpenFlow. Sorry about that.
Sorry for the confusion. > > I applied the following incremental to your patch which, I think, > makes 9+10 the same as 9+10 as you sent, just with bits moved between > the patches: Looks good. I think the only difference in my code was to set bad_in_port_err on the line it is declared on, just in case it isn't set. I believe that is what lead to the confusion. > diff --git a/lib/ofp-util.c b/lib/ofp-util.c > index 1139bb1..6b92dcd 100644 > --- a/lib/ofp-util.c > +++ b/lib/ofp-util.c > @@ -2149,6 +2149,7 @@ ofputil_decode_packet_out(struct ofputil_packet_out *po, > const struct ofp_header *oh, > struct ofpbuf *ofpacts) > { > + enum ofperr bad_in_port_err; > enum ofpraw raw; > struct ofpbuf b; > > @@ -2183,6 +2184,8 @@ ofputil_decode_packet_out(struct ofputil_packet_out *po, > if (error) { > return error; > } > + > + bad_in_port_err = OFPERR_NXBRC_BAD_IN_PORT; > } else { > NOT_REACHED(); > } > @@ -2191,7 +2194,7 @@ ofputil_decode_packet_out(struct ofputil_packet_out *po, > && po->in_port != OFPP_NONE && po->in_port != OFPP_CONTROLLER) { > VLOG_WARN_RL(&bad_ofmsg_rl, "packet-out has bad input port %#"PRIx16, > po->in_port); > - return OFPERR_NXBRC_BAD_IN_PORT; > + return bad_in_port_err; > } > > po->ofpacts = ofpacts->data; > _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev