Re: [PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-08 Thread Eric Dumazet
On Thu, 2016-06-09 at 09:43 +0800, Su Xuemin wrote: > On Wed 2016-06-08 at 08:43 -0700, Eric Dumazet wrote: > > I am not convinced this is the right way to fix the issue. > > > > Fact that you did not change udp4_lib_lookup2() is telling me something. > > > > > > 1) If host has 100 different

Re: [PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-08 Thread Eric Dumazet
On Thu, 2016-06-09 at 09:43 +0800, Su Xuemin wrote: > On Wed 2016-06-08 at 08:43 -0700, Eric Dumazet wrote: > > I am not convinced this is the right way to fix the issue. > > > > Fact that you did not change udp4_lib_lookup2() is telling me something. > > > > > > 1) If host has 100 different

Re: [PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-08 Thread Su Xuemin
On Wed 2016-06-08 at 08:43 -0700, Eric Dumazet wrote: > I am not convinced this is the right way to fix the issue. > > Fact that you did not change udp4_lib_lookup2() is telling me something. > > > 1) If host has 100 different IP, and 10 sockets bound to 0.0.0.0:53 > 2) If we receive datagrams

Re: [PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-08 Thread Su Xuemin
On Wed 2016-06-08 at 08:43 -0700, Eric Dumazet wrote: > I am not convinced this is the right way to fix the issue. > > Fact that you did not change udp4_lib_lookup2() is telling me something. > > > 1) If host has 100 different IP, and 10 sockets bound to 0.0.0.0:53 > 2) If we receive datagrams

Re: [PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-08 Thread Eric Dumazet
On Wed, 2016-06-08 at 11:40 +0800, Su Xuemin wrote: > From: "Su, Xuemin" > > There is a corner case in which udp packets belonging to a same > flow are hashed to different socket when hslot->count changes from 10 > to 11: > It's the same case for IPv6, and this patch

Re: [PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-08 Thread Eric Dumazet
On Wed, 2016-06-08 at 11:40 +0800, Su Xuemin wrote: > From: "Su, Xuemin" > > There is a corner case in which udp packets belonging to a same > flow are hashed to different socket when hslot->count changes from 10 > to 11: > It's the same case for IPv6, and this patch also fixes that. > >

[PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-07 Thread Su Xuemin
From: "Su, Xuemin" There is a corner case in which udp packets belonging to a same flow are hashed to different socket when hslot->count changes from 10 to 11: 1) When hslot->count <= 10, __udp_lib_lookup() searches udp_table->hash, and always passes 'daddr' to

[PATCH v2] udp reuseport: fix packet of same flow hashed to different socket

2016-06-07 Thread Su Xuemin
From: "Su, Xuemin" There is a corner case in which udp packets belonging to a same flow are hashed to different socket when hslot->count changes from 10 to 11: 1) When hslot->count <= 10, __udp_lib_lookup() searches udp_table->hash, and always passes 'daddr' to udp_ehashfn(). 2) When