Commit c0e7716b authored by Dan Carpenter's avatar Dan Carpenter Committed by sanglipeng
Browse files

phy: stm32: fix an error code in probe

stable inclusion
from stable-v5.10.155
commit 72ea2fc29962f3bb16eba80a2f0c88ffa6bb9e08
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I7M5F4

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



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

[ Upstream commit ca1c7362 ]

If "index > usbphyc->nphys" is true then this returns success but it
should return -EINVAL.

Fixes: 94c358da ("phy: stm32: add support for STM32 USB PHY Controller (USBPHYC)")
Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Reviewed-by: default avatarAmelie Delaunay <amelie.delaunay@foss.st.com>
Link: https://lore.kernel.org/r/Y0kq8j6S+5nDdMpr@kili


Signed-off-by: default avatarVinod Koul <vkoul@kernel.org>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarsanglipeng <sanglipeng1@jd.com>
parent f52de635
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment