Maybe. Sometimes it's too hard to keep track of changes just by looking at the flow.
On Wed, Jan 24, 2018 at 08:18:12PM +0100, Alan Kayahan wrote: > Thanks for bearing with me so far Ben. I will post my experience in > creating a custom action and match step by step like some others have done > in the mailing list, both for hearing your input and for others to benefit. > > What if the action is creating a new header, an IPv6 extension header, in > the packet? My OVS action is pushing the L2+L3 headers in the packet > buffer, making enough room for say the fragmentation header, then appending > the header and readjusting the L4 offset. In this case, does it make sense > to immediately emit ODP action via "nl_msg_put_u16(ctx->odp_actions, > OVS_ACTION_ATTR_PUSH_EXTH, ofpact_get_PUSH_EXTH(a)->arg);" in > ofproto-dpif-xlate? > > > 2018-01-22 20:33 GMT+01:00 Ben Pfaff <b...@ovn.org>: > > > Actions that just set fields don't emit ODP actions to do that > > immediately because controllers often change fields multiple times > > between outputs, so that it would be wasteful to emit the changes > > multiple times. Instead, at the time of emitting an output (or other > > visible side effect), OVS emits all changes to fields in one group. > > > > On Sat, Jan 13, 2018 at 09:11:50AM +0100, Alan Kayahan wrote: > > > Indeed. My custom action works when I put nl_msg_put_flag(ctx->odp_ > > actions, > > > OVS_ACTION_ATTR_MY_ACTION); however none of the other cases follow this > > > pattern. They all set flow->xxx from the struct casted ofpact instead. > > > Since both setting ctx->odp_actions and flow->xxx works, I have the > > > following questions > > > > > > 1) Where do the actions defined in ctx->odp_actions get actuated? > > > 2) Where do the actions for the struct flow get actuated, and how does > > the > > > actuator know what OVS actions to actuate? > > > 3) Can we say that do_xlate_actions() is currently being used outside the > > > purpose that its name implies, because all it does is to set the fields > > of > > > the struct flow to those set in ofpact struct? > > > > > > Thanks > > > > > > 2018-01-12 18:36 GMT+01:00 Ben Pfaff <b...@ovn.org>: > > > > > > > On Fri, Jan 12, 2018 at 11:39:44AM +0100, Alan Kayahan wrote: > > > > > Hello, > > > > > > > > > > Per my understanding from /ovs-discuss/2015-May/037313.html, > > > > > ofproto-dpif-xlate translates OFP actions into Netlink format, which > > is > > > > > useful for datapath actions implemented in the kernel module. Does > > that > > > > > hold for OFP to DPDK datapath actions too? > > > > > > > > Yes. > > > > > > > > > I couldn't find a connection from ofproto-dpif-xlate to > > > > > odp_execute_actions. Where does the translation of ofpact structs > > into > > > > > OVS actions implemented in DPDK datapath take place? > > > > > > > > ofproto-dpif-xlate does the translation for both datapaths, in the same > > > > way. > > > > > > _______________________________________________ discuss mailing list disc...@openvswitch.org https://mail.openvswitch.org/mailman/listinfo/ovs-discuss