Skip to content

Commit cbfb9c7

Browse files
Chen Nihdeller
authored andcommitted
fbdev: au1100fb: Check return value of clk_enable() in .resume()
Check the return value of clk_enable() in au1100fb_drv_resume() and return the error on failure. This ensures the system is aware of the resume failure and can track its state accurately. Signed-off-by: Chen Ni <nichen@iscas.ac.cn> Acked-by: Uwe Kleine-König <u.kleine-koenig@baylibre.com> Signed-off-by: Helge Deller <deller@gmx.de>
1 parent 8e9bf8b commit cbfb9c7

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

drivers/video/fbdev/au1100fb.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -567,13 +567,16 @@ int au1100fb_drv_suspend(struct platform_device *dev, pm_message_t state)
567567
int au1100fb_drv_resume(struct platform_device *dev)
568568
{
569569
struct au1100fb_device *fbdev = platform_get_drvdata(dev);
570+
int ret;
570571

571572
if (!fbdev)
572573
return 0;
573574

574575
memcpy(fbdev->regs, &fbregs, sizeof(struct au1100fb_regs));
575576

576-
clk_enable(fbdev->lcdclk);
577+
ret = clk_enable(fbdev->lcdclk);
578+
if (ret)
579+
return ret;
577580

578581
/* Unblank the LCD */
579582
au1100fb_fb_blank(VESA_NO_BLANKING, &fbdev->info);

0 commit comments

Comments
 (0)