Skip to content
Commit 494e8489 authored by Mahesh Bandewar's avatar Mahesh Bandewar Committed by David S. Miller
Browse files

ipvlan: Fix failure path in dev registration during link creation



When newlink creation fails at device-registration, the port->count
is decremented twice. Francesco Ruggeri (fruggeri@arista.com) found
this issue in Macvlan and the same exists in IPvlan driver too.

While fixing this issue I noticed another issue of missing unregister
in case of failure, so adding it to the fix which is similar to the
macvlan fix by Francesco in commit 30837960 ("macvlan: fix failure
during registration v3")

Reported-by: default avatarFrancesco Ruggeri <fruggeri@arista.com>
Signed-off-by: default avatarMahesh Bandewar <maheshb@google.com>
CC: Eric Dumazet <edumazet@google.com>
CC: Eric W. Biederman <ebiederm@xmission.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 222e4d0b
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment