diff options
author | Antonino A. Daplas <adaplas@gmail.com> | 2007-05-09 05:35:32 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-09 15:30:57 -0400 |
commit | 5a87ede94595f58934000e26e8b13398e63868b5 (patch) | |
tree | e97b7e505753c8243ec10c008e9ff39e61c92d09 /drivers/video/svgalib.c | |
parent | 681e14730c73cc2c71af282c001de6bc71c22f00 (diff) |
svgalib: move fb_get_caps to svgalib
Move fb_get_caps() method to svgalib.c as svga_get_caps() so it can be used by
s3fb, arkfb and vt8623fb.
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/svgalib.c')
-rw-r--r-- | drivers/video/svgalib.c | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/drivers/video/svgalib.c b/drivers/video/svgalib.c index 079cdc911e48..25df928d37d8 100644 --- a/drivers/video/svgalib.c +++ b/drivers/video/svgalib.c | |||
@@ -347,6 +347,23 @@ int svga_get_tilemax(struct fb_info *info) | |||
347 | return 256; | 347 | return 256; |
348 | } | 348 | } |
349 | 349 | ||
350 | /* Get capabilities of accelerator based on the mode */ | ||
351 | |||
352 | void svga_get_caps(struct fb_info *info, struct fb_blit_caps *caps, | ||
353 | struct fb_var_screeninfo *var) | ||
354 | { | ||
355 | if (var->bits_per_pixel == 0) { | ||
356 | /* can only support 256 8x16 bitmap */ | ||
357 | caps->x = 1 << (8 - 1); | ||
358 | caps->y = 1 << (16 - 1); | ||
359 | caps->len = 256; | ||
360 | } else { | ||
361 | caps->x = (var->bits_per_pixel == 4) ? 1 << (8 - 1) : ~(u32)0; | ||
362 | caps->y = ~(u32)0; | ||
363 | caps->len = ~(u32)0; | ||
364 | } | ||
365 | } | ||
366 | EXPORT_SYMBOL(svga_get_caps); | ||
350 | 367 | ||
351 | /* ------------------------------------------------------------------------- */ | 368 | /* ------------------------------------------------------------------------- */ |
352 | 369 | ||