linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] - video/tdfxfb.c warning fix.
@ 2004-04-30 18:04 Luiz Fernando N. Capitulino
  2004-05-01  4:35 ` Andrew Morton
  0 siblings, 1 reply; 8+ messages in thread
From: Luiz Fernando N. Capitulino @ 2004-04-30 18:04 UTC (permalink / raw)
  To: Andrew Morton; +Cc: James Simmons, linux-fbdev-devel


 Hi Andrew,

 This patch fixes this warning:

 drivers/video/tdfxfb.c:1005: warning: `tdfxfb_cursor' defined but not
 used

 and make the acceleration function selectable (like hgafb
and tridentfb):


 drivers/video/Kconfig  |    8 ++++++++
 drivers/video/tdfxfb.c |    8 +++++++-
 2 files changed, 15 insertions(+), 1 deletion(-)


diff -X dontdiff -Nparu a/drivers/video/Kconfig a~/drivers/video/Kconfig
--- a/drivers/video/Kconfig	2004-04-26 15:25:52.000000000 -0300
+++ a~/drivers/video/Kconfig	2004-04-27 18:15:23.000000000 -0300
@@ -751,6 +751,14 @@ config FB_3DFX
 	  To compile this driver as a module, choose M here: the
 	  module will be called tdfxfb.
 
+config FB_3DFX_ACCEL
+	bool "3Dfx Banshee/Voodoo3 Acceleration functions (EXPERIMENTAL)"
+	depends on FB_3DFX && EXPERIMENTAL
+	---help---
+	This will compile the 3Dfx Banshee/Voodoo3 frame buffer device
+	with acceleration functions.
+
+
 config FB_VOODOO1
 	tristate "3Dfx Voodoo Graphics (sst1) support"
 	depends on FB && PCI
diff -X dontdiff -Nparu a/drivers/video/tdfxfb.c a~/drivers/video/tdfxfb.c
--- a/drivers/video/tdfxfb.c	2004-03-11 14:20:50.000000000 -0300
+++ a~/drivers/video/tdfxfb.c	2004-04-27 19:35:22.000000000 -0300
@@ -166,7 +166,11 @@ static int tdfxfb_pan_display(struct fb_
 static void tdfxfb_fillrect(struct fb_info *info, const struct fb_fillrect *rect);
 static void tdfxfb_copyarea(struct fb_info *info, const struct fb_copyarea *area);  
 static void tdfxfb_imageblit(struct fb_info *info, const struct fb_image *image); 
+#ifdef CONFIG_FB_3DFX_ACCEL
 static int tdfxfb_cursor(struct fb_info *info, struct fb_cursor *cursor);
+#else /* !CONFIG_FB_3DFX_ACCEL */
+#define tdfxfb_cursor soft_cursor
+#endif /* CONFIG_FB_3DFX_ACCEL */
 static int banshee_wait_idle(struct fb_info *info);
 
 static struct fb_ops tdfxfb_ops = {
@@ -180,7 +184,7 @@ static struct fb_ops tdfxfb_ops = {
 	.fb_copyarea	= tdfxfb_copyarea,
 	.fb_imageblit	= tdfxfb_imageblit,
 	.fb_sync	= banshee_wait_idle,
-	.fb_cursor	= soft_cursor,
+	.fb_cursor	= tdfxfb_cursor,
 };
 
 /*
@@ -1001,6 +1005,7 @@ static void tdfxfb_imageblit(struct fb_i
 	banshee_wait_idle(info);
 }
 
+#ifdef CONFIG_FB_3DFX_ACCEL
 static int tdfxfb_cursor(struct fb_info *info, struct fb_cursor *cursor)
 {
 	struct tdfx_par *par = (struct tdfx_par *) info->par;
@@ -1137,6 +1142,7 @@ static int tdfxfb_cursor(struct fb_info 
 	spin_unlock_irqrestore(&par->DAClock, flags);
 	return 0;
 }
+#endif /* CONFIG_FB_3DFX_ACCEL */
 
 /**
  *      tdfxfb_probe - Device Initializiation

-- 
Luiz Fernando N. Capitulino
<http://www.telecentros.sp.gov.br>


-------------------------------------------------------
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g. 
Take an Oracle 10g class now, and we'll give you the exam FREE. 
http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2004-05-03 16:10 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-04-30 18:04 [PATCH] - video/tdfxfb.c warning fix Luiz Fernando N. Capitulino
2004-05-01  4:35 ` Andrew Morton
2004-05-01 18:47   ` Geert Uytterhoeven
2004-05-01 19:08     ` Andrew Morton
2004-05-01 19:09       ` Andrew Morton
2004-05-01 19:17         ` Geert Uytterhoeven
2004-05-01 19:16       ` Geert Uytterhoeven
2004-05-03 16:09         ` Luiz Fernando N. Capitulino

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).