Xin Long <[email protected]> writes: > There are two nat functions are nearly the same in both OVS and > TC code, (ovs_)ct_nat_execute() and ovs_ct_nat/tcf_ct_act_nat(). > > This patch creates nf_nat_ovs.c under netfilter and moves them > there then exports nf_ct_nat() so that it can be shared by both > OVS and TC, and keeps the nat (type) check and nat flag update > in OVS and TC's own place, as these parts are different between > OVS and TC. > > Note that in OVS nat function it was using skb->protocol to get > the proto as it already skips vlans in key_extract(), while it > doesn't in TC, and TC has to call skb_protocol() to get proto. > So in nf_ct_nat_execute(), we keep using skb_protocol() which > works for both OVS and TC contrack. > > Signed-off-by: Xin Long <[email protected]> > ---
Acked-by: Aaron Conole <[email protected]> _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
