On 7/17/24 13:42, Wilson Peng via dev wrote: > From: Wilson Peng <[email protected]> > > NdisGetDataBuffer() is called without providing a buffer to copy packet > data in case it is not contiguous. So, it fails in some scenarios > where the packet is handled by the general network stack before OVS > and headers become split in multiple buffers. > > In the fix it will supply the stack buffer to copy packet data when > call NdisGetDataBuffer(). > > In the conntrack Action process, it will do OvsPartialCopyNBL firstly > with the size of layers l7offsets. If the header is split the header > will be merged to one continuous buffer. > > But IPV6 traffic is not handed in this case. > > Reported-at: https://github.com/openvswitch/ovs-issues/issues/323 > Signed-off-by: Wilson Peng <[email protected]> > --- > datapath-windows/ovsext/Actions.c | 7 +++++++ > datapath-windows/ovsext/BufferMgmt.c | 16 +++++++++++++--- > datapath-windows/ovsext/Conntrack.c | 4 +++- > datapath-windows/ovsext/IpFragment.c | 8 ++++++-- > 4 files changed, 29 insertions(+), 6 deletions(-)
Hi, Wilson. Thanks for the patch! Though I wonder why are we using NdisGetDataBuffer directly at all? We have helper functions OvsGetTcp or OvsGetPacketBytes and these should be able to handle non-contiguous memory. I tried to use them in my previous attempt to fix this issue here: https://patchwork.ozlabs.org/project/openvswitch/patch/[email protected]/ Though I definitely missed a few places and so the patch doesn't work in its current form. Best regards, Ilya Maximets. _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
