diff options
Diffstat (limited to 'drivers/video/vt8500lcdfb.c')
-rw-r--r-- | drivers/video/vt8500lcdfb.c | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/drivers/video/vt8500lcdfb.c b/drivers/video/vt8500lcdfb.c index 7617f12e4fd7..0e120d67eb65 100644 --- a/drivers/video/vt8500lcdfb.c +++ b/drivers/video/vt8500lcdfb.c | |||
@@ -215,6 +215,33 @@ static int vt8500lcd_pan_display(struct fb_var_screeninfo *var, | |||
215 | return 0; | 215 | return 0; |
216 | } | 216 | } |
217 | 217 | ||
218 | /* | ||
219 | * vt8500lcd_blank(): | ||
220 | * Blank the display by setting all palette values to zero. Note, | ||
221 | * True Color modes do not really use the palette, so this will not | ||
222 | * blank the display in all modes. | ||
223 | */ | ||
224 | static int vt8500lcd_blank(int blank, struct fb_info *info) | ||
225 | { | ||
226 | int i; | ||
227 | |||
228 | switch (blank) { | ||
229 | case FB_BLANK_POWERDOWN: | ||
230 | case FB_BLANK_VSYNC_SUSPEND: | ||
231 | case FB_BLANK_HSYNC_SUSPEND: | ||
232 | case FB_BLANK_NORMAL: | ||
233 | if (info->fix.visual == FB_VISUAL_PSEUDOCOLOR || | ||
234 | info->fix.visual == FB_VISUAL_STATIC_PSEUDOCOLOR) | ||
235 | for (i = 0; i < 256; i++) | ||
236 | vt8500lcd_setcolreg(i, 0, 0, 0, 0, info); | ||
237 | case FB_BLANK_UNBLANK: | ||
238 | if (info->fix.visual == FB_VISUAL_PSEUDOCOLOR || | ||
239 | info->fix.visual == FB_VISUAL_STATIC_PSEUDOCOLOR) | ||
240 | fb_set_cmap(&info->cmap, info); | ||
241 | } | ||
242 | return 0; | ||
243 | } | ||
244 | |||
218 | static struct fb_ops vt8500lcd_ops = { | 245 | static struct fb_ops vt8500lcd_ops = { |
219 | .owner = THIS_MODULE, | 246 | .owner = THIS_MODULE, |
220 | .fb_set_par = vt8500lcd_set_par, | 247 | .fb_set_par = vt8500lcd_set_par, |
@@ -225,6 +252,7 @@ static struct fb_ops vt8500lcd_ops = { | |||
225 | .fb_sync = wmt_ge_sync, | 252 | .fb_sync = wmt_ge_sync, |
226 | .fb_ioctl = vt8500lcd_ioctl, | 253 | .fb_ioctl = vt8500lcd_ioctl, |
227 | .fb_pan_display = vt8500lcd_pan_display, | 254 | .fb_pan_display = vt8500lcd_pan_display, |
255 | .fb_blank = vt8500lcd_blank, | ||
228 | }; | 256 | }; |
229 | 257 | ||
230 | static irqreturn_t vt8500lcd_handle_irq(int irq, void *dev_id) | 258 | static irqreturn_t vt8500lcd_handle_irq(int irq, void *dev_id) |