Commit 5cde5fda authored by Yevhen Orlov's avatar Yevhen Orlov Committed by Zheng Zengkai
Browse files

net: marvell: prestera: fix incorrect return of port_find

stable inclusion
from stable-v5.10.89
commit 78e49d77e517c205e7c2c2f7a970468dd2f867b1
bugzilla: 186140 https://gitee.com/openeuler/kernel/issues/I4S8HA

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



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

[ Upstream commit 8b681bd7 ]

In case, when some ports is in list and we don't find requested - we
return last iterator state and not return NULL as expected.

Fixes: 501ef306 ("net: marvell: prestera: Add driver for Prestera family ASIC devices")
Signed-off-by: default avatarYevhen Orlov <yevhen.orlov@plvision.eu>
Link: https://lore.kernel.org/r/20211216170736.8851-1-yevhen.orlov@plvision.eu


Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarChen Jun <chenjun102@huawei.com>
Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
parent 8d0fc4f1
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment