[PATCH 1/1] phy: fsl-imx8mq-usb: add dev_err_probe if getting vbus failed

Vinod Koul vkoul at kernel.org
Fri Aug 11 01:20:52 PDT 2023


On 01-08-23, 10:48, Alexander Stein wrote:
> This adds an error message if getting vbus failed for some reason,
> -EPROBE_DEFER is handled appropriately as well and adds a nice
> information to debugfs.

Fails to apply on phy/next

> 
> Signed-off-by: Alexander Stein <alexander.stein at ew.tq-group.com>
> ---
>  drivers/phy/freescale/phy-fsl-imx8mq-usb.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/phy/freescale/phy-fsl-imx8mq-usb.c b/drivers/phy/freescale/phy-fsl-imx8mq-usb.c
> index c1a57541fbb3..3af007b8e77f 100644
> --- a/drivers/phy/freescale/phy-fsl-imx8mq-usb.c
> +++ b/drivers/phy/freescale/phy-fsl-imx8mq-usb.c
> @@ -399,7 +399,7 @@ static int imx8mq_usb_phy_probe(struct platform_device *pdev)
>  	if (PTR_ERR(imx_phy->vbus) == -ENODEV)
>  		imx_phy->vbus = NULL;
>  	else if (IS_ERR(imx_phy->vbus))
> -		return PTR_ERR(imx_phy->vbus);
> +		return dev_err_probe(dev, PTR_ERR(imx_phy->vbus), "failed to get vbus\n");
>  
>  	phy_set_drvdata(imx_phy->phy, imx_phy);
>  
> -- 
> 2.34.1

-- 
~Vinod



More information about the linux-phy mailing list