firmware/sysfb: fix an error code in sysfb_init()
This error path accidentally returns success when it should preserve the
error code from sysfb_parent_dev().
Fixes: 4e754597d6
("firmware/sysfb: Create firmware device only for enabled PCI devices")
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Link: https://patchwork.freedesktop.org/patch/msgid/aaaa2e13-849b-41a0-8186-25f3d2a16f86@moroto.mountain
This commit is contained in:
parent
b0fda2fcb4
commit
9fa2679b7f
|
@ -127,8 +127,10 @@ static __init int sysfb_init(void)
|
|||
sysfb_apply_efi_quirks();
|
||||
|
||||
parent = sysfb_parent_dev(si);
|
||||
if (IS_ERR(parent))
|
||||
if (IS_ERR(parent)) {
|
||||
ret = PTR_ERR(parent);
|
||||
goto unlock_mutex;
|
||||
}
|
||||
|
||||
/* try to create a simple-framebuffer device */
|
||||
compatible = sysfb_parse_mode(si, &mode);
|
||||
|
|
Loading…
Reference in New Issue