Hi Jason, Jason Woofenden <jason@jasonwoof.com> (30/01/2011): > Here is my report on how I got the siliconmotion driver to run: […] many thanks, that looks quite promising. I'll try and look into it in the next days/weeks, feel free to poke me if you see no action on this bug in a while. Néstor, Tzafrir, see Jason's full report at: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=594684#25 (I've added them back in Cc, the BTS doesn't do that automatically.) > 1) I mirrored the sarea patch at: > http://jasonwoof.com/downloads/01_mips-sarea.diff because the link > above seemed dead. I believe it's the same patch though. I'm attaching it to this mail. Having the patches in the BTS is usually a safe way to have them accessible no matter what happens to external websites. KiBi.
diff -urN xorg-server-1.3.0.orig/hw/xfree86/dri/sarea.h xorg-server-1.1.1/hw/xfree86/dri/sarea.h
--- xorg-server-1.3.0.orig/hw/xfree86/dri/sarea.h 2006-07-06 02:31:40.000000000 +0800
+++ xorg-server-1.3.0/hw/xfree86/dri/sarea.h 2007-10-30 14:23:47.000000000 +0800
@@ -44,6 +44,8 @@
/* SAREA area needs to be at least a page */
#if defined(__alpha__)
#define SAREA_MAX 0x2000
+#elif defined(__mips__)
+#define SAREA_MAX 0x4000
#elif defined(__ia64__)
#define SAREA_MAX 0x10000 /* 64kB */
#else
diff --git a/hw/xfree86/os-support/linux/lnx_video.c b/hw/xfree86/os-support/linux/lnx_video.c
index 688106a..1552860 100644
--- a/hw/xfree86/os-support/linux/lnx_video.c
+++ b/hw/xfree86/os-support/linux/lnx_video.c
@@ -505,9 +505,10 @@ _X_EXPORT volatile unsigned char *ioBase = NULL;
_X_EXPORT Bool
xf86EnableIO(void)
{
-#if defined(__powerpc__)
+#if defined(__powerpc__) || defined(__mips__)
int fd;
unsigned int ioBase_phys;
+ extern unsigned int IOPortBase;
#endif
if (ExtendedEnabled)
@@ -532,7 +533,22 @@ xf86EnableIO(void)
#endif
}
close(fd);
-#elif !defined(__mc68000__) && !defined(__sparc__) && !defined(__mips__) && !defined(__sh__) && !defined(__hppa__) && !defined(__s390__) && !defined(__arm__) && !defined(__m32r__)
+#elif defined(__mips__)
+ fd = open("/dev/mem", O_RDWR);
+ IOPortBase = (volatile unsigned char *)mmap(0, 0x20000,
+ PROT_READ | PROT_WRITE, MAP_SHARED, fd,
+ 0x1fd00000);
+ if (IOPortBase == MAP_FAILED) {
+ xf86Msg(X_WARNING,
+ "xf86EnableIOPorts: Failed to map iobase (%s)\n",
+ strerror(errno));
+ return FALSE;
+ }
+ close(fd);
+ xf86Msg(X_WARNING,
+ "xf86EnableIOPorts: map iobase (%x)\n",
+ IOPortBase);
+#elif !defined(__mc68000__) && !defined(__sparc__) && !defined(__sh__) && !defined(__hppa__) && !defined(__s390__) && !defined(__arm__) && !defined(__m32r__)
if (ioperm(0, 1024, 1) || iopl(3)) {
if (errno == ENODEV)
ErrorF("xf86EnableIOPorts: no I/O ports found\n");
Attachment:
signature.asc
Description: Digital signature