summaryrefslogtreecommitdiff
path: root/net/ipv4/ip_fragment.c
diff options
context:
space:
mode:
authorShalom Toledo <shalomt@mellanox.com>2018-10-29 17:26:16 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-11-04 16:50:53 +0300
commitb5ce2a238a8b4f1ee0a5a23b4d7e6929d6733bb2 (patch)
tree46cf40e42c3bc01be15fcb2fe7945962558096de /net/ipv4/ip_fragment.c
parenta731a1e85d708fbe0d69809a00d9b3d67a672843 (diff)
downloadlinux-b5ce2a238a8b4f1ee0a5a23b4d7e6929d6733bb2.tar.xz
mlxsw: core: Fix devlink unregister flow
[ Upstream commit a22712a962912faf257e857ab6857f56a93cfb34 ] After a failed reload, the driver is still registered to devlink, its devlink instance is still allocated and the 'reload_fail' flag is set. Then, in the next reload try, the driver's allocated devlink instance will be freed without unregistering from devlink and its components (e.g, resources). This scenario can cause a use-after-free if the user tries to execute command via devlink user-space tool. Fix by not freeing the devlink instance during reload (failed or not). Fixes: 24cc68ad6c46 ("mlxsw: core: Add support for reload") Signed-off-by: Shalom Toledo <shalomt@mellanox.com> Reviewed-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Ido Schimmel <idosch@mellanox.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/ipv4/ip_fragment.c')
0 files changed, 0 insertions, 0 deletions