On Thu, Feb 14, 2013 at 01:13:29PM -0800, Pravin Shelar wrote: > On Thu, Feb 14, 2013 at 11:50 AM, Ansis Atteka <aatt...@nicira.com> wrote: > > The new ovs-monitor-ipsec implementation will use skb marks in > > IPsec policies. This patch will configure datapath to use these > > skb marks for IPsec tunnel packets. > > > > Issue: 14870 > > Signed-off-by: Ansis Atteka <aatt...@nicira.com> > > --- > > lib/odp-util.c | 12 +++++++++--- > > lib/odp-util.h | 4 ++-- > > ofproto/ofproto-dpif.c | 11 +++++++---- > > ofproto/tunnel.c | 9 +++++++-- > > ofproto/tunnel.h | 5 ++++- > > 5 files changed, 29 insertions(+), 12 deletions(-) > > > > diff --git a/lib/odp-util.c b/lib/odp-util.c > > index 7e48981..755bdd6 100644 > > --- a/lib/odp-util.c > > +++ b/lib/odp-util.c > > @@ -2043,11 +2043,17 @@ odp_put_userspace_action(uint32_t pid, const union > > user_action_cookie *cookie, > > > > void > > odp_put_tunnel_action(const struct flow_tnl *tunnel, > > - struct ofpbuf *odp_actions) > > + struct ofpbuf *odp_actions, uint32_t skb_mark) > > { > > size_t offset = nl_msg_start_nested(odp_actions, OVS_ACTION_ATTR_SET); > > tun_key_to_attr(odp_actions, tunnel); > > nl_msg_end_nested(odp_actions, offset); > > + > > + if (skb_mark) { > > + offset = nl_msg_start_nested(odp_actions, OVS_ACTION_ATTR_SET); > > + nl_msg_put_u32(odp_actions, OVS_KEY_ATTR_SKB_MARK, skb_mark); > > + nl_msg_end_nested(odp_actions, offset); > > + } > > } > > > why not use one available in flow->skb_mark? So that existing set > skb-mark action will take care of generating action for you.
I agree, that's a better idea. (I personally forgot we had skb_mark in struct flow, maybe Ansis didn't realize.) _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev