Skip to content

Commit

Permalink
[PATCH] i810fb: Honor the return value of pci_enable_device
Browse files Browse the repository at this point in the history
Check the return value of pci_enable_device().

Signed-off-by: Antonino Daplas <adaplas@pol.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Antonino A. Daplas authored and Linus Torvalds committed Oct 3, 2006
1 parent 7b566b1 commit 9237ed0
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion drivers/video/i810/i810_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -1602,7 +1602,10 @@ static int i810fb_resume(struct pci_dev *dev)
acquire_console_sem();
pci_set_power_state(dev, PCI_D0);
pci_restore_state(dev);
pci_enable_device(dev);

if (pci_enable_device(dev))
goto fail;

pci_set_master(dev);
agp_bind_memory(par->i810_gtt.i810_fb_memory,
par->fb.offset);
Expand All @@ -1611,6 +1614,7 @@ static int i810fb_resume(struct pci_dev *dev)
i810fb_set_par(info);
fb_set_suspend (info, 0);
info->fbops->fb_blank(VESA_NO_BLANKING, info);
fail:
release_console_sem();
return 0;
}
Expand Down

0 comments on commit 9237ed0

Please sign in to comment.