Re: Linux 2.2.18pre13, drm without agp

From: Peter Osterlund (peter.osterlund@mailbox.swipnet.se)
Date: Sun Oct 01 2000 - 05:18:25 EST


Alan Cox <alan@lxorguk.ukuu.org.uk> writes:

> 2.2.18pre2 (versus 2.2.17pre20)
>
> o AGP driver backport (XFree86, Precision
> DRM driver backport Insight, XiG, HJ Lu,
> VA Linux,
> and others)

I have a Voodoo3 2000 PCI card, but when I activate DRM without AGP,

        # CONFIG_AGP is not set
        CONFIG_DRM=y
        CONFIG_DRM_TDFX=y

the linker complains about an undefined reference to agp_enable. The
following patch works for me, but I don't know if it is the correct
solution. (Even if it is, other drm drivers probably need similar
patches.)

This problem does not exist in 2.4.0-test8.

Here is the patch:

--- linux-2.2.18pre13/drivers/char/drm/tdfx_drv.c~ Sun Oct 1 10:46:36 2000
+++ linux-2.2.18pre13/drivers/char/drm/tdfx_drv.c Sun Oct 1 11:38:25 2000
@@ -34,12 +34,14 @@
 #include "drmP.h"
 #include "tdfx_drv.h"
 
+#if defined(CONFIG_AGP) || defined(CONFIG_AGP_MODULE)
 #include <linux/agp_backend.h>
 
 static __attribute__((unused)) void unused(void)
 {
        agp_enable(0);
 }
+#endif
 
 #define TDFX_NAME "tdfx"
 #define TDFX_DESC "3dfx Banshee/Voodoo3+"

-- 
Peter Österlund          Email:     peter.osterlund@mailbox.swipnet.se
Sköndalsvägen 35                    f90-pos@nada.kth.se
S-128 66 Sköndal         Home page: http://home1.swipnet.se/~w-15919
Sweden                   Phone:     +46 8 942647

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Oct 07 2000 - 21:00:07 EST