[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5a1d8121d85858653b646f8f73845627cb70198b.camel@imgtec.com>
Date: Thu, 30 Nov 2023 09:09:31 +0000
From: Frank Binns <Frank.Binns@...tec.com>
To: "dan.carpenter@...aro.org" <dan.carpenter@...aro.org>,
Sarah Walker <Sarah.Walker@...tec.com>
CC: "kernel-janitors@...r.kernel.org" <kernel-janitors@...r.kernel.org>,
"tzimmermann@...e.de" <tzimmermann@...e.de>,
Donald Robson <Donald.Robson@...tec.com>,
Matt Coster <Matt.Coster@...tec.com>,
"dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
"airlied@...il.com" <airlied@...il.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"maarten.lankhorst@...ux.intel.com"
<maarten.lankhorst@...ux.intel.com>,
"daniel@...ll.ch" <daniel@...ll.ch>,
"mripard@...nel.org" <mripard@...nel.org>
Subject: Re: [PATCH 2/2] drm/imagination: Fix IS_ERR() vs NULL bug in
pvr_request_firmware()
On Thu, 2023-11-30 at 10:27 +0300, Dan Carpenter wrote:
> The pvr_build_firmware_filename() function returns NULL on error. It
> doesn't return error pointers.
>
> Fixes: f99f5f3ea7ef ("drm/imagination: Add GPU ID parsing and firmware loading")
> Signed-off-by: Dan Carpenter <dan.carpenter@...aro.org>
Reviewed-by: Frank Binns <frank.binns@...tec.com>
> ---
> drivers/gpu/drm/imagination/pvr_device.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/imagination/pvr_device.c b/drivers/gpu/drm/imagination/pvr_device.c
> index e1dcc4e42087..5389aea7ff21 100644
> --- a/drivers/gpu/drm/imagination/pvr_device.c
> +++ b/drivers/gpu/drm/imagination/pvr_device.c
> @@ -286,8 +286,8 @@ pvr_request_firmware(struct pvr_device *pvr_dev)
>
> filename = pvr_build_firmware_filename(pvr_dev, "powervr/rogue",
> PVR_FW_VERSION_MAJOR);
> - if (IS_ERR(filename))
> - return PTR_ERR(filename);
> + if (!filename)
> + return -ENOMEM;
>
> /*
> * This function takes a copy of &filename, meaning we can free our
Powered by blists - more mailing lists