2003-09-09 22:53:42

by Stephen Hemminger

[permalink] [raw]
Subject: [PATCH] warning from agpart backend

Get rid of warning about unused function if agp is built as a module.

diff -Nru a/drivers/char/agp/backend.c b/drivers/char/agp/backend.c
--- a/drivers/char/agp/backend.c Tue Sep 9 15:50:51 2003
+++ b/drivers/char/agp/backend.c Tue Sep 9 15:50:51 2003
@@ -318,7 +318,8 @@
{
}

-static __init int agp_setup(char *s)
+#ifndef MODULE
+static int __init agp_setup(char *s)
{
if (!strcmp(s,"off"))
agp_off = 1;
@@ -327,6 +328,7 @@
return 1;
}
__setup("agp=", agp_setup);
+#endif

MODULE_AUTHOR("Dave Jones <[email protected]>");
MODULE_DESCRIPTION("AGP GART driver");