summaryrefslogtreecommitdiff
path: root/drivers/video/fbdev/aty
diff options
context:
space:
mode:
authorDinghao Liu <dinghao.liu@zju.edu.cn>2020-08-25 09:29:00 +0300
committerBartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>2020-09-08 14:33:26 +0300
commitfe6c6a4af2be8c15bac77f7ea160f947c04840d1 (patch)
tree3e8c627f6139e8180613bf037a0658294dc592bd /drivers/video/fbdev/aty
parent925896486522e5f3f9cac1ea5c3a659247cca223 (diff)
downloadlinux-fe6c6a4af2be8c15bac77f7ea160f947c04840d1.tar.xz
video: fbdev: radeon: Fix memleak in radeonfb_pci_register
When radeon_kick_out_firmware_fb() fails, info should be freed just like the subsequent error paths. Fixes: 069ee21a82344 ("fbdev: Fix loading of module radeonfb on PowerMac") Signed-off-by: Dinghao Liu <dinghao.liu@zju.edu.cn> Reviewed-by: Mathieu Malaterre <malat@debian.org> Cc: Kangjie Lu <kjlu@umn.edu> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com> Link: https://patchwork.freedesktop.org/patch/msgid/20200825062900.11210-1-dinghao.liu@zju.edu.cn
Diffstat (limited to 'drivers/video/fbdev/aty')
-rw-r--r--drivers/video/fbdev/aty/radeon_base.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/video/fbdev/aty/radeon_base.c b/drivers/video/fbdev/aty/radeon_base.c
index 3fe509cb9b87..13bd2bd5c043 100644
--- a/drivers/video/fbdev/aty/radeon_base.c
+++ b/drivers/video/fbdev/aty/radeon_base.c
@@ -2307,7 +2307,7 @@ static int radeonfb_pci_register(struct pci_dev *pdev,
ret = radeon_kick_out_firmware_fb(pdev);
if (ret)
- return ret;
+ goto err_release_fb;
/* request the mem regions */
ret = pci_request_region(pdev, 0, "radeonfb framebuffer");