On 12 April 2016 at 11:10, William Tu <u9012...@gmail.com> wrote: > Hi Joe, > >> There is no need to truncate packet immediately. We can keep the >> >> > truncate len in skb_ovs_cb and use it to truncate packet right before >> > seeing it over port or to user-space up-call. >> >> So, if you have a packet with length 100, then do the following actions: >> >> truncate(64),output(1),truncate(100),output(2), then port 1 will see >> the truncated packet but port 2 will see the full (100 bytes of) >> packet? > > > Yes, when seeing a truncate(64) action, we set len=64 in skb_ovs_cb, and it > is until output(1) then we do the real truncate, clear the len. > So the next truncate(100) will start over with a new packet and output(2) > should see the full packet.
Ah okay, so the following would also forward a 64B packet to port 1 and 100B packet to port 2 in this situation: truncate(64),output(1),output(2) _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev