tech-x11 archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Updated drm code



Hello,

updated drm kernel code for NetBSD-current is available from

http://maailma.homeip.net/netbsd/nbsddrm.tgz

It matches freedesktop mesa/drm commit
85b9f737db0d2a845e4d7e2bbf9ad12ff9e2227c from 20090522, plus
all the radeon changes from r6xx-r7xx-support branch. So in
theory new Radeons should get some acceleration with this.


In order to use this, you will also need to apply this patch:

http://maailma.homeip.net/netbsd/nbsddrm.patch

then replace contents of src/sys/external/bsd/drm/dist with the
contents of the tar, define DRM_EXTERNAL in your kernel config
and go.


Big caveats apply

 - The nbsddrm.patch removes check for negative offsets
   from mmap()! Use with caution!

   I did this, because I didn't want to redo the addr2handle
   hacks that exist in current NetBSD drm code.

 - I have only converted i915drm and radeondrm drivers to
   new code. However, changes to _drv.c files are quite small
   and mechanical, so they should be easy to do for other drivers.

 - I have tested succesfully only on i945GM. X works nicely with this,
   so the new code is not a complete bust.

 - Another card I tested is Radeon HD3870 (unsupported previously).

   The card does attach with the new code, and X does start up,
   but display is garbled. I'm not sure whether this particular
   card is even supposed to work or not with the experimental
   r6xx support.

   When killed, X does shutdown cleanly, and I get text console
   back, so even this is not a *complete* bust.

   I'm using modular-xorg-server 1.6.1.901 (thanks to hasso@),
   libdrm-2.4.11 and xf86-video-ati 6.12.2.


Note that I didn't do any real work here: I mostly just mechanically
brought back the necessary #ifdefs that were removed by FreeBSD devs
from stock drm code. So kudos to the people who did the initial porting
of drm code to NetBSD.


I'm making this code available since I don't have any more time
to spend on it. I hope some NetBSD dev will clean this up, people
will test it, and NetBSD could then be updated to fresh drm code.


Home | Main Index | Thread Index | Old Index