Commit f350b0ce authored by Dan Carpenter's avatar Dan Carpenter Committed by openeuler-sync-bot
Browse files

net/mlx5: E-Switch, Fix an Oops in error handling code

stable inclusion
from stable-v5.10.177
commit 5eadc80328298ef7beaaf0cd96791667d3b485ca
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I88YNP

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=5eadc80328298ef7beaaf0cd96791667d3b485ca



--------------------------------

[ Upstream commit 640fcdbc ]

The error handling dereferences "vport".  There is nothing we can do if
it is an error pointer except returning the error code.

Fixes: 133dcfc5 ("net/mlx5: E-Switch, Alloc and free unique metadata for match")
Signed-off-by: default avatarDan Carpenter <error27@gmail.com>
Reviewed-by: default avatarRoi Dayan <roid@nvidia.com>
Signed-off-by: default avatarSaeed Mahameed <saeedm@nvidia.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarsanglipeng <sanglipeng1@jd.com>
(cherry picked from commit 4b18311f)
parent 49be10a9
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment