Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
intel_gpu [2012/05/17 23:19] – Typo. SergeyOsokinintel_gpu [2013/03/27 18:15] (current) – Remove no-longer-relevant items, now that this is in HEAD EdMaste
Line 1: Line 1:
-The WIP patches are available at http://people.freebsd.org/~kib/drm/ . Patches are against latest HEAD. +NOTE: All enabling patches were committed to HEAD as of r235859 and to RELENG_9 as of r236969.
-You need all.X.patch, where X is the max.+
  
 **What is this ?** The required kernel-mode support to run the recent usermode ddx and mesa drivers for Intel GPUs. Initial goal is to have gen4-gen6 **What is this ?** The required kernel-mode support to run the recent usermode ddx and mesa drivers for Intel GPUs. Initial goal is to have gen4-gen6
Line 10: Line 9:
 Large parts of the code were taken from the Intel GPU driver in the Linux kernel, which is licensed under the BSD-like Intel opensource license. Large parts of the code were taken from the Intel GPU driver in the Linux kernel, which is licensed under the BSD-like Intel opensource license.
 The i2c bus access code is converted to our iic(4) framework, which need an eye from newbus and iic gurus. The i2c bus access code is converted to our iic(4) framework, which need an eye from newbus and iic gurus.
 +agp_i810(4) has been reworked to add required generic support for the Intel GTT.
  
-agp_i810(4) has been reworked to add required generic support for the Intel GTT. See [[AGP_Testing|AGP_Testing]] for the status of testing of the new agp driver. +Required usermode components are available in the ports tree, you need to add WITH_NEW_XORG=true and WITH_KMS=true to /etc/make.conf.
-If you have a card that is not yet listed as reported, and can confirm that patched agp driver works with it, please drop me a note.+
  
-To use the driver, you will need either+Or, for the latest development versions of the usermode stack, get
   - dri2proto from git head, git:%%//%%anongit.freedesktop.org/xorg/proto/dri2proto   - dri2proto from git head, git:%%//%%anongit.freedesktop.org/xorg/proto/dri2proto
   - glproto from git head, git:%%//%%anongit.freedesktop.org/xorg/proto/glproto   - glproto from git head, git:%%//%%anongit.freedesktop.org/xorg/proto/glproto
-  - libdrm from git head, git:%%//%%anongit.freedesktop.org/mesa/drm. You need to apply the hack http://people.freebsd.org/~kib/drm/libdrm.1.patch to get KMS. +  - libdrm from git head, git:%%//%%anongit.freedesktop.org/mesa/drm. You need to apply the patch http://people.freebsd.org/~kib/drm/libdrm.2.patch to get KMS. 
-  - intel ddx driver from git head, git:%%//%%anongit.freedesktop.org/xorg/driver/xf86-video-intel **Update**. Due to Xorg server in ports being quite old, you have to stay at the revision ab10008. +  - intel ddx driver from git head, git:%%//%%anongit.freedesktop.org/xorg/driver/xf86-video-intel 
-  - (required for Ironlake and Sandybridge) Mesa from git head, git:%%//%%anongit.freedesktop.org/mesa/mesa. I configured the library as+  - Mesa from git head, git:%%//%%anongit.freedesktop.org/mesa/mesa. I configured the library as
  
 <code> <code>
-CFLAGS=-I/usr/local/include LDFLAGS=-L/usr/local/lib FLEX=/usr/local/bin/flex BISON=/usr/local/bin/bison ./configure --enable-dri --disable-xlib-glx --with-dri-drivers=i915,i965,swrast --disable-gallium-llvm --disable-gallium-egl --with-gallium-drivers=""+CFLAGS=-I/usr/local/include LDFLAGS=-L/usr/local/lib FLEX=/usr/local/bin/flex BISON=/usr/local/bin/bison ./configure --enable-dri --disable-xlib-glx --with-dri-drivers=i915,i965,swrast --disable-gallium-llvm --disable-gallium-egl --with-gallium-drivers="" --enable-texture-float
 </code> </code>
  
 Obviously, you need to have textproc/flex and devel/bison installed, flex from the base would not work. Obviously, you need to have textproc/flex and devel/bison installed, flex from the base would not work.
-or 
-  * the xorg-dev ports tree, see http://miwi.wp.lando.cc/2011/02/cft-xorg-7-5-miwi1-freebsd-edition/ 
  
-I got a report that radeon driver works after the patch application. +Since the syscons is not integrated with KMS, screen goes blank after i915kms is loaded. 
-Other non-Intel DRI drivers are probably rotten due to core drm changes. +Use ''%%startx%%'' to let ddx driver load the right kernel module. 
-Committable version of the patch will fork the drm core.+Set ''%%sysctl hw.dri.debug=0%%'' to reduce verbosity of the driver at runtime.
  
-Also, you must have the serial console to catch debugging output and panics.+You must have the serial console to catch debugging output and panics.
 GEM does useful tracing during the operation that is required to analyze the GEM does useful tracing during the operation that is required to analyze the
 actions causing the problems. See ktr(4), GEM uses KTR_DEV event mask. actions causing the problems. See ktr(4), GEM uses KTR_DEV event mask.
Line 54: Line 51:
  
 ==== FAQ (yes, I already tired of some questions) ==== ==== FAQ (yes, I already tired of some questions) ====
- 
-  - I have the problem .... 
- 
-Do not mail me in private. Use mailing lists, x11@ is probably right one. 
  
   - Do you plan to port TTM ?   - Do you plan to port TTM ?
  
-Not in the scope of this project. After the project is finished, I might look at TTM and execution managers for non-Intel cards, +Not in the scope of this project, but see [[AMD_GPU]]
-in particular, ATI/AMD. +
-Apparently, KMS bits are not much interesting to me. +
- +
-  - I want to test ! +
- +
-Great. Why do you think that I need to know about it ? +
-Bug fixes and reviews are welcome. +
- +
-  - Which version of source to apply patch to ? +
- +
-Latest head. At least until the VM changes are put into svn. Stable/8 support is not planned. See the revision above for the src/ version +
-against which the patch was generated.+
  
   - Does KMS work will ease the future porting of the KMS code for non-Intel drivers ?   - Does KMS work will ease the future porting of the KMS code for non-Intel drivers ?
Line 98: Line 79:
 This way, it is easier for me to test the driver. Eventually, this will be changed. This way, it is easier for me to test the driver. Eventually, this will be changed.
  
-  - I get a reject in i915_suspend.c. +  - The system panics upon "kldunload i915kms"
- +
-The cause is that you use subversion-freebsd, which causes $%%FreeBSD%%$ tag expansion in the checkout. Manually edit the i915_suspend.c before +
-applying the patch, to undo the expanded $%%FreeBSD%%$ tag into it short form. +
- +
-  - I get a reject in i915_mem.c. +
- +
-Remove this file, also remove i915_mem.c.rej, i915_mem.c.orig. +
- +
-  - I get kernel compilation error with all.14.9.patch on RELENG_9. +
- +
-You should also get following patch for additional VM functions here: http://people.freebsd.org/~osa/drm/all.14.9.vm.patch +
- +
-  - I can't run X with latest all.15.0.patch.+
  
-You should use latest version (at least 2.19.0) of xf86-intel-video from https://trillian.chruetertee.ch/svn/ports/branches/xorg-dev, +At present the module cannot be unloaded.  See http://lists.freebsd.org/pipermail/freebsd-current/2012-June/034563.html for details.
-revision 494.+
  
  • intel_gpu.1337296793.txt.gz
  • Last modified: 2012/05/17 23:19
  • by SergeyOsokin