lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20190711164619.GT7234@tuxbook-pro>
Date:   Thu, 11 Jul 2019 09:46:19 -0700
From:   Bjorn Andersson <bjorn.andersson@...aro.org>
To:     Brian Masney <masneyb@...tation.org>
Cc:     robdclark@...il.com, sean@...rly.run, airlied@...ux.ie,
        daniel@...ll.ch, linux-arm-msm@...r.kernel.org,
        dri-devel@...ts.freedesktop.org, freedreno@...ts.freedesktop.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH] drm/msm/phy/dsi_phy: silence -EPROBE_DEFER warnings

On Sat 06 Jul 04:11 PDT 2019, Brian Masney wrote:

> The following errors show up when booting the Nexus 5:
> 
> msm_dsi_phy fd922a00.dsi-phy: [drm:dsi_phy_driver_probe] *ERROR*
>  dsi_phy_regulator_init: failed to init regulator, ret=-517
> msm_dsi_phy fd922a00.dsi-phy: [drm:dsi_phy_driver_probe] *ERROR*
>  dsi_phy_driver_probe: failed to init regulator
> 
> dsi_phy_regulator_init() already logs the error, so no need to log
> the same error a second time in dsi_phy_driver_probe(). This patch
> also changes dsi_phy_regulator_init() to not log the error if the
> error code is -EPROBE_DEFER to reduce noise in dmesg.
> 
> Signed-off-by: Brian Masney <masneyb@...tation.org>
> ---
>  drivers/gpu/drm/msm/dsi/phy/dsi_phy.c | 11 ++++++-----
>  1 file changed, 6 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
> index 4097eca1b3ef..d0e1cc6728dc 100644
> --- a/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
> +++ b/drivers/gpu/drm/msm/dsi/phy/dsi_phy.c
> @@ -396,8 +396,11 @@ static int dsi_phy_regulator_init(struct msm_dsi_phy *phy)
>  
>  	ret = devm_regulator_bulk_get(dev, num, s);
>  	if (ret < 0) {
> -		DRM_DEV_ERROR(dev, "%s: failed to init regulator, ret=%d\n",
> -						__func__, ret);
> +		if (ret != -EPROBE_DEFER)
> +			DRM_DEV_ERROR(dev,
> +				      "%s: failed to init regulator, ret=%d\n",
> +				      __func__, ret);

Some {} wouldn't hurt here, but not a big deal.

Reviewed-by: Bjorn Andersson <bjorn.andersson@...aro.org>

> +
>  		return ret;
>  	}
>  
> @@ -584,10 +587,8 @@ static int dsi_phy_driver_probe(struct platform_device *pdev)
>  	}
>  
>  	ret = dsi_phy_regulator_init(phy);
> -	if (ret) {
> -		DRM_DEV_ERROR(dev, "%s: failed to init regulator\n", __func__);
> +	if (ret)
>  		goto fail;
> -	}
>  
>  	phy->ahb_clk = msm_clk_get(pdev, "iface");
>  	if (IS_ERR(phy->ahb_clk)) {
> -- 
> 2.20.1
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ