Re: [PATCH net 1/2] vxlan: fix hlist corruption

2017-07-03 Thread Waiman Long
On 07/03/2017 04:23 AM, Jiri Benc wrote: > On Sun, 2 Jul 2017 16:06:10 -0400, Waiman Long wrote: >> I didn't see any init code for hlist4 and hlist6. Is vxlan_dev going to >> be *zalloc'ed so that they are guaranteed to be NULL? If not, you may >> need to add init code as not both hlists will be

Re: [PATCH net 1/2] vxlan: fix hlist corruption

2017-07-03 Thread Jiri Benc
On Sun, 2 Jul 2017 16:06:10 -0400, Waiman Long wrote: > I didn't see any init code for hlist4 and hlist6. Is vxlan_dev going to > be *zalloc'ed so that they are guaranteed to be NULL? If not, you may > need to add init code as not both hlists will be hashed and so one of > them may contain

Re: [PATCH net 1/2] vxlan: fix hlist corruption

2017-07-02 Thread Waiman Long
On 07/02/2017 01:00 PM, Jiri Benc wrote: > It's not a good idea to add the same hlist_node to two different hash lists. > This leads to various hard to debug memory corruptions. > > Fixes: b1be00a6c39f ("vxlan: support both IPv4 and IPv6 sockets in a single > vxlan device") > Signed-off-by: Jiri

[PATCH net 1/2] vxlan: fix hlist corruption

2017-07-02 Thread Jiri Benc
It's not a good idea to add the same hlist_node to two different hash lists. This leads to various hard to debug memory corruptions. Fixes: b1be00a6c39f ("vxlan: support both IPv4 and IPv6 sockets in a single vxlan device") Signed-off-by: Jiri Benc --- drivers/net/vxlan.c |