Hello guys,
Finally, I found a way to activate the kms support on my laptop. Unfortunatelly this works right now only on FreeBSD9.0 and only some part works as expected.
Here I am right now: the video card seems to be correctly initialized, but a lot of artifacts (random pixels) are shown in the top part of the screen. Also, the mouse clicks doesn't seems to work.
I'll post the tutorial with what I've done in order to obtain kms support. If you want to test for yourself, then follow the next steps:
1. Install the FreeBSD dvd standard version, only the system base (without X, ports, or something else, just a basic install)
2. Log in as root and type:
portsnap fetch extract
3. Install the portsmaster and the subversion:
cd /usr/ports/ports-mgmt/portmaster
make install clean
cd /usr/ports/devel/subversion
make install clean
4. type:
portmaster -a
then install the cvsup tool:
cd /usr/ports/net/cvsup-without-gui
make install clean
5. make a txt file called sources9.txt with this content:
*default host=cvsup.FreeBSD.org
*default prefix=/usr
*default base=/var/db
*default release=cvs tag=RELENG_9
*default delete use-rel-suffix compress
src-all
6. do this in order to get the all source code:
csup sources9.txt
7. edit manually (with vi or ee) the /usr/src/sys/dev/drm/i915_suspend.c file and modify it so that "$FreeBSD: blah[...]blah$" becomes "$FreeBSD$"
or call this command to automatically do that:
sed -i -e 's/FreeBSD: src.*Exp /FreeBSD/' /usr/src/sys/dev/drm/i915_suspend.c
8. cd to /root and get the kms patch form the tsatsenko website:
From /root directory, type this:
fetch
http://tsatsenko.ru/files/all.13.5-stable-9.patch
**note: I used this patch wich is the newest one, buy maybe the artifacts problem cames from it - I don't know, I'll try with older patches because some people with videocards like me doesn't report that kind of problem (screen artifacts).
9. apply that patch to the kernel with:
patch -d /usr/src </root/all.13.5-stable-9.patch
**note: pray to God not to have *.rej files after applying the patch, because that case the kernel will not compile**
10. go to /usr/src directory and type:
make buildworld && make buildkernel && make installkernel
(reboot)
11. go to /usr/src directory and type:
make installworld
(reboot)
12. edit the /etc/make.conf file and add the following lines:
WITH_NEW_XORG="YES"
WITH_KMS="YES"
**note: if you don't have this file, you can create it with:
touch /etc/make.conf
13. install xorg
cd /usr/ports/x11/xorg
make install clean
(reboot)
14. get the xorgmerge script with:
fetch
http://people.freebsd.org/~miwi/xorg/xorgmerge
15. get the 7_5_2 X version from svn. Go to /root and type:
svn co
https://trillian.chruetertee.ch/svn/...ags/xorg_7_5_2
16. edit xorgmerge script with ee or vi and set the KDEDIR variable value to your xorg_7_5_2 path:
KDEDIR="/root/xorg_7_5_2"
17. call the script:
sh xorgmerge
18. call this to rebuild everything:
portmaster -Raf
19. edit /boot/loader.conf and add this:
drm_load="YES"
20. edit /etc/rc.conf and add this:
dbus_enable="YES"
hald_enable="YES"
(reboot)
21. from /root type this:
Xorg -configure
cp xorg.conf.new /etc/xorg.conf
22. add your favourite DE to .xinitrc file:
echo exec /usr/local/bin/twm > ~/.xinitrc
**Note: if you don't set any DE to start, you've got a blank screen when you startx.
23. startx
**Note:
All this process will take several hours. If you plan to do that, make all this stuff in a weekend day or take a vacation day (as me)
Anyway, I'll dig into this and then, if I can set correctly my video card I'll see if I can make the same thing for PC-BSD.
I'll keep in touch with my progress.
Cheers,
phpwolf