Here are the newest drivers for SM: http://www.anheng.com.cn/loongson2f/squeeze/xserver-xorg-video-siliconmotion/
The work to do is more than patching or compiling some parts of the GNU/Linux system.
A Xorg developer said me:
email@example.com wrote: Apart from minor bugs that are already largely solved, Yeelong video driver suffers from performance issues related to video decoding. The main problem, as I understand it, appears to be that the LynxEM chipset can handle only packed YUV while most of the time frames are given as planar YUV (I'm not experienced with video decoding but I assume it's due to YUV components being encoded separately). So the video driver have to pack the data it receives from the Xv client in order for the chipset to perform its YUV->RGB on-the-fly conversion. The current smi driver does this by calling Xv helper function for this job, which is dog slow and deprive mplayer of needed CPU horsepower. Noticing this bottleneck, Lemote devs added a faster conversion routine using MMX loongson assembler right into smi driver. As far as I know all the patchs around that makes mplayed videos fast are based on this ugly hack. So, since the paid professionals were not given appropriate time to fix the slowness issue the proper way, we the unpaid amateurs will have to work on it on our spare time :-) Of course SMI driver must keep calling Xv generic conversion function. But patching Xv with architecture specific assembly is not much better. Xv should instead use a library that offers this kind of image processing functions optimised for the running architecture. This library already exist, is called libpixman and is in fact already used by some other parts of X11. Unfortunately YUV conversion functions are not currently supported by libpixman, although some work is being done in this direction. Finishing this work, adding support for loongson MMX instructions and then patch Xv to use libpixman would be the perfect solution to our problem. I was about to try this path when I discovered that libpixman project is also considering another radically different evolution : to replace all architecture specific pieces of code by a more generic JIT compiler. Of course I quickly dropped the idea of patching YUV + loongson into pixman and embraced the JIT thing instead. Why hack for two weeks when you could be hacking for six months ?
And starting THIS project. This can be the way to get a really good performance of the video card, as far as his “proof of concept” appears to show.
So, the efforts that has been tried this far are the following ones:
For apply most of the patches it is needed to recompile xserver-xorg and recompile the driver to have all working properly. This is mostly insane to do in the current metad version, because the current distro xorg server version is more than old and it is not upgradeable, unless we wait for the next Debian Stable Release…
The closest approach to this was using the LOONUX repos. it brings a little more best performance, but it does not solve some others problem. MPLAYER crashes installing it in this way, giving a segfault error.
We are starting to work in a GNU/Linux From Scratch, to probe the sourcecode available without getting in trouble with binary versions and just sit waiting for the slow uptating time of Debian Stable distribution. it will be useful to probe also others programs like NetworkManager and the rest of the needs of FSF for the Yeelong Endorsement.
This has be done until now:
In the gNewSense-dev mailing list, Daniel Clark give some advices: