forked from Minki/linux
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: 069ee21a82
("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
This commit is contained in:
parent
9258964865
commit
fe6c6a4af2
@ -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");
|
||||
|
Loading…
Reference in New Issue
Block a user