[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <f99b8eb0-b758-7781-8bd8-bb1c95ecb8fa@codeaurora.org>
Date: Fri, 29 Mar 2019 12:27:07 +0530
From: Mukesh Ojha <mojha@...eaurora.org>
To: YueHaibing <yuehaibing@...wei.com>,
Tomi Valkeinen <tomi.valkeinen@...com>,
David Airlie <airlied@...ux.ie>,
Daniel Vetter <daniel@...ll.ch>,
Sean Paul <seanpaul@...omium.org>,
Peter Ujfalusi <peter.ujfalusi@...com>,
Matteo Croce <mcroce@...hat.com>,
Benoit Parrot <bparrot@...com>
Cc: dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org,
kernel-janitors@...r.kernel.org
Subject: Re: [PATCH -next] drm/omap: Use PTR_ERR_OR_ZERO in hdmi4_core_init()
On 3/29/2019 7:11 AM, YueHaibing wrote:
> Use PTR_ERR_OR_ZERO rather than if(IS_ERR(...)) + PTR_ERR
>
> Signed-off-by: YueHaibing <yuehaibing@...wei.com>
Reviewed-by: Mukesh Ojha <mojha@...eaurora.org>
-Mukesh
> ---
> drivers/gpu/drm/omapdrm/dss/hdmi4_core.c | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/gpu/drm/omapdrm/dss/hdmi4_core.c b/drivers/gpu/drm/omapdrm/dss/hdmi4_core.c
> index e384b95ad857..8287ade5ece0 100644
> --- a/drivers/gpu/drm/omapdrm/dss/hdmi4_core.c
> +++ b/drivers/gpu/drm/omapdrm/dss/hdmi4_core.c
> @@ -934,8 +934,5 @@ int hdmi4_core_init(struct platform_device *pdev, struct hdmi_core_data *core)
>
> res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "core");
> core->base = devm_ioremap_resource(&pdev->dev, res);
> - if (IS_ERR(core->base))
> - return PTR_ERR(core->base);
> -
> - return 0;
> + return PTR_ERR_OR_ZERO(core->base);
> }
>
>
>
>
>
Powered by blists - more mailing lists