[<prev] [next>] [day] [month] [year] [list]
Message-ID: <4bec4498-05a2-9ec5-8b91-7934d05ded68@web.de>
Date: Wed, 3 Jun 2020 18:48:31 +0200
From: Markus Elfring <Markus.Elfring@....de>
To: Chuhong Yuan <hslester96@...il.com>,
dri-devel@...ts.freedesktop.org, linux-fbdev@...r.kernel.org,
linux-geode@...ts.infradead.org
Cc: Andrew Morton <akpm@...l.org>,
Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>,
Adrian Bunk <bunk@...sta.de>,
Andres Salomon <dilinger@...ued.net>,
David Vrabel <dvrabel@...om.com>,
James Simmons <jsimmons@...radead.org>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] fbdev: geocode: Add the missed pci_disable_device() in
gx1fb_map_video_memory()
> Add the missed function call to fix the bug.
…
> +++ b/drivers/video/fbdev/geode/gx1fb_core.c
> @@ -208,29 +208,44 @@ static int gx1fb_map_video_memory(struct fb_info *info, struct pci_dev *dev)
…
> return 0;
> +
> +err:
> + pci_disable_device(dev);
> + return ret;
> }
…
I suggest to use more descriptive labels so that the exception handling
can be improved accordingly.
return 0;
+
+e_nomem:
+ ret = -ENOMEM;
+disable_device:
+ pci_disable_device(dev);
+ return ret;
}
Regards,
Markus
Powered by blists - more mailing lists