aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/video/sm501fb.c
diff options
context:
space:
mode:
authorBen Dooks <ben-linux@fluff.org>2007-10-16 04:28:38 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-16 12:43:14 -0400
commitf22e521f2992031fdedb661f2a647cafd2e45fa1 (patch)
tree6af6f07174460932adab8368c92a7cbd4911b7bf /drivers/video/sm501fb.c
parentc1f303bb21a63ed11edfb790e5701ab0ded62eff (diff)
sm501fb: Call fb suspend function during suspend and resume
Call the fb_set_suspend() over suspend and resume. Signed-off-by: Antonino Daplas <adaplas@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/video/sm501fb.c')
-rw-r--r--drivers/video/sm501fb.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/video/sm501fb.c b/drivers/video/sm501fb.c
index fc0cdc830360..d97edd7a6e41 100644
--- a/drivers/video/sm501fb.c
+++ b/drivers/video/sm501fb.c
@@ -28,6 +28,7 @@
28#include <linux/wait.h> 28#include <linux/wait.h>
29#include <linux/platform_device.h> 29#include <linux/platform_device.h>
30#include <linux/clk.h> 30#include <linux/clk.h>
31#include <linux/console.h>
31 32
32#include <asm/io.h> 33#include <asm/io.h>
33#include <asm/uaccess.h> 34#include <asm/uaccess.h>
@@ -1697,6 +1698,10 @@ static int sm501fb_suspend_fb(struct sm501fb_info *info,
1697 /* blank the relevant interface to ensure unit power minimised */ 1698 /* blank the relevant interface to ensure unit power minimised */
1698 (par->ops.fb_blank)(FB_BLANK_POWERDOWN, fbi); 1699 (par->ops.fb_blank)(FB_BLANK_POWERDOWN, fbi);
1699 1700
1701 acquire_console_sem();
1702 fb_set_suspend(fbi, 1);
1703 release_console_sem();
1704
1700 return 0; 1705 return 0;
1701 1706
1702 err_nocursor: 1707 err_nocursor:
@@ -1732,6 +1737,10 @@ static void sm501fb_resume_fb(struct sm501fb_info *info,
1732 memcpy_toio(par->cursor.k_addr, par->store_cursor, 1737 memcpy_toio(par->cursor.k_addr, par->store_cursor,
1733 par->cursor.size); 1738 par->cursor.size);
1734 1739
1740 acquire_console_sem();
1741 fb_set_suspend(fbi, 0);
1742 release_console_sem();
1743
1735 vfree(par->store_fb); 1744 vfree(par->store_fb);
1736 vfree(par->store_cursor); 1745 vfree(par->store_cursor);
1737} 1746}