Commit 042c5b0d authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] fbdev: video/hgafb.c warning fix

From: "Luiz Fernando N. Capitulino" <lcapitulino@prefeitura.sp.gov.br>

Make HGA acceleration functions selectable in kernel config, fix these
warnings:

drivers/video/hgafb.c:452: warning: `hgafb_fillrect' defined but not used
drivers/video/hgafb.c:472: warning: `hgafb_copyarea' defined but not used
drivers/video/hgafb.c:502: warning: `hgafb_imageblit' defined but not used
parent a75e8fb8
...@@ -308,6 +308,14 @@ config FB_HGA ...@@ -308,6 +308,14 @@ config FB_HGA
As this card technology is 15 years old, most people will answer N As this card technology is 15 years old, most people will answer N
here. here.
config FB_HGA_ACCEL
bool "Hercules mono Acceleration functions (EXPERIMENTAL)"
depends on FB_HGA && EXPERIMENTAL
---help---
This will compile the Hercules mono graphics with
acceleration functions.
config VIDEO_SELECT config VIDEO_SELECT
bool bool
depends on FB && X86 depends on FB && X86
......
...@@ -448,6 +448,10 @@ static int hgafb_blank(int blank_mode, struct fb_info *info) ...@@ -448,6 +448,10 @@ static int hgafb_blank(int blank_mode, struct fb_info *info)
return 0; return 0;
} }
/*
* Accel functions
*/
#ifdef CONFIG_FB_HGA_ACCEL
static void hgafb_fillrect(struct fb_info *info, const struct fb_fillrect *rect) static void hgafb_fillrect(struct fb_info *info, const struct fb_fillrect *rect)
{ {
u_int rows, y; u_int rows, y;
...@@ -510,6 +514,11 @@ static void hgafb_imageblit(struct fb_info *info, const struct fb_image *image) ...@@ -510,6 +514,11 @@ static void hgafb_imageblit(struct fb_info *info, const struct fb_image *image)
*dest = d; *dest = d;
} }
} }
#else /* !CONFIG_FB_HGA_ACCEL */
#define hgafb_fillrect cfb_fillrect
#define hgafb_copyarea cfb_copyarea
#define hgafb_imageblit cfb_imageblit
#endif /* CONFIG_FB_HGA_ACCEL */
static struct fb_ops hgafb_ops = { static struct fb_ops hgafb_ops = {
...@@ -519,9 +528,9 @@ static struct fb_ops hgafb_ops = { ...@@ -519,9 +528,9 @@ static struct fb_ops hgafb_ops = {
.fb_setcolreg = hgafb_setcolreg, .fb_setcolreg = hgafb_setcolreg,
.fb_pan_display = hgafb_pan_display, .fb_pan_display = hgafb_pan_display,
.fb_blank = hgafb_blank, .fb_blank = hgafb_blank,
.fb_fillrect = cfb_fillrect, //hgafb_fillrect, .fb_fillrect = hgafb_fillrect,
.fb_copyarea = cfb_copyarea, //hgafb_copyarea, .fb_copyarea = hgafb_copyarea,
.fb_imageblit = cfb_imageblit,//hgafb_imageblit, .fb_imageblit = hgafb_imageblit,
}; };
/* ------------------------------------------------------------------------- * /* ------------------------------------------------------------------------- *
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment