On Thu, Jun 14, 2012 at 10:44:03AM +0900, Simon Horman wrote: > On Thu, Jun 14, 2012 at 09:58:08AM +0900, Simon Horman wrote: > > On Tue, Jun 12, 2012 at 12:32:16AM -0700, Ben Pfaff wrote: > > > @@ -1232,22 +1232,23 @@ do_probe(int argc OVS_UNUSED, char *argv[]) > > > static void > > > do_packet_out(int argc, char *argv[]) > > > { > > > + enum ofputil_protocol protocol; > > > struct ofputil_packet_out po; > > > - struct ofpbuf actions; > > > + struct ofpbuf ofpacts; > > > struct vconn *vconn; > > > int i; > > > > > > - ofpbuf_init(&actions, sizeof(union ofp_action)); > > > - parse_ofp_actions(argv[3], &actions); > > > + ofpbuf_init(&ofpacts, 64); > > > + parse_ofpacts(argv[3], &ofpacts); > > > > > > po.buffer_id = UINT32_MAX; > > > po.in_port = (!strcasecmp(argv[2], "none") ? OFPP_NONE > > > : !strcasecmp(argv[2], "local") ? OFPP_LOCAL > > > : str_to_port_no(argv[1], argv[2])); > > > - po.actions = actions.data; > > > - po.n_actions = actions.size / sizeof(union ofp_action); > > > + po.ofpacts = ofpacts.data; > > > + po.ofpacts_len = ofpacts.size; > > > > > > - open_vconn(argv[1], &vconn); > > > + protocol = open_vconn(argv[1], &vconn); > > > for (i = 4; i < argc; i++) { > > > struct ofpbuf *packet, *opo; > > > const char *error_msg; > > > > GCC tells me that protocol is set by not used in do_packet_out(). > > Perhaps it could be removed? > > Actually, scratch that. > > I think that protocol will need to be passed to ofputil_encode_packet_out() > which is called inside the for loop above. > > Actually, I have a local change to add protocol to do_packet_out() > for that reason. I had forgotten about that.
To make the tree make maximum sense at all bisection points, I decided to remove 'protocol' here. We can easily reintroduce it later at the point it is needed. Thanks, Ben. _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev