1.\" $NetBSD: drm.4,v 1.7 2009/05/12 08:16:46 wiz Exp $ 2.\" 3.\" Copyright (c) 2007 Thomas Klausner 4.\" All rights reserved. 5.\" 6.\" Redistribution and use in source and binary forms, with or without 7.\" modification, are permitted provided that the following conditions 8.\" are met: 9.\" 1. Redistributions of source code must retain the above copyright 10.\" notice, this list of conditions and the following disclaimer. 11.\" 2. Redistributions in binary form must reproduce the above copyright 12.\" notice, this list of conditions and the following disclaimer in the 13.\" documentation and/or other materials provided with the distribution. 14.\" 15.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 16.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES 17.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 18.\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, 19.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 20.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 21.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 22.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 23.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 24.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 25.\" 26.Dd January 11, 2012 27.Dt DRM 4 28.Os 29.Sh NAME 30.Nm drm 31.Nd Direct Rendering Manager (DRI kernel support) 32.Sh SYNOPSIS 33.Cd device drm 34.Cd device i915drm 35.Cd device mach64drm 36.Cd device mgadrm 37.Cd device r128drm 38.Cd device radeondrm 39.Cd device savagedrm 40.Cd device sisdrm 41.Cd device tdfxdrm 42.\".Cd device viadrm 43.Pp 44.Cd options DRM_DEBUG 45.\".Cd options DRM_LINUX 46.Sh DESCRIPTION 47The 48.Tn Direct Rendering Manager 49is part of the 50.Tn Direct Rendering Infrastructure 51(see 52.Pa http://dri.freedesktop.org/ ) 53for supporting video acceleration. 54For older chipsets it's used for 3d acceleration only, but newer chipsets 55may require 56.Nm 57for 2d acceleration (XVideo, exa(4)) as well. 58.Pp 59The 60.Nm 61drivers provide support for the following chipsets: 62.Pp 63.Bl -tag -width XsavagedrmXXX -offset indent -compact 64.It i915drm 65Intel i915, i945, i965, G3x, G4x 66.It mach64drm 67Mach64 (3D Rage Pro, Rage) 68.It mgadrm 69Matrox G[24]00, G[45]50 70.It r128drm 71ATI Rage 128 72.It radeondrm 73ATI Radeon 74.It savagedrm 75S3 Savage 76.It sisdrm 77SiS 78.It tdfxdrm 793dfx (Voodoo) 80.\".It viadrm 81.\"VIA 82.El 83.Pp 84To make use of the driver: 85.Pp 86.Bl -bullet -compact 87.It 88The kernel must include 89.Xr agp 4 90.It 91.Xr Xorg 1 , 92MesaLib and the video driver to be used must be compiled with DRI support 93.It 94DRI must be enabled in the 95.Xr xorg.conf 5 96configuration file: 97.Bd -literal 98Section "DRI" 99 Group "wheel" 100 Mode 0660 101EndSection 102.Ed 103.El 104.Pp 105In order to use two graphics cards (an on-board and another 106AGP/PCI/PCIe card) with DRI, a 107.Pa /dev/dri/card1 108link to 109.Pa /dev/dri/card0 110has to be created using 111.Xr devfsctl 8 . 112.Pp 113If 114.Xr Xorg 1 115acceleration fails to initialize with a 116.Dq contigmalloc_map: failed size... 117error in dmesg, the reserve of memory for DMA ran out early and should 118be increased to a sufficiently high value by setting the 119.Va vm.dma_reserved 120loader tunable. 121A read only 122.Xr sysctl 8 123variable of the same name is provided for obtaining its current value. 124.Pp 125Debugging output can be enabled and disabled by setting the 126.Xr sysctl 8 127node 128.Ar hw.dri.0.debug . 129.Sh SEE ALSO 130.Xr Xorg 1 , 131.Xr agp 4 , 132.\".Xr exa 4 , 133.Xr xorg.conf 5 134.Sh HISTORY 135DRM was first available for Linux. 136Subsequently Eric Anholt ported the DRM kernel modules to 137.Fx . 138.Sh CAVEATS 139Disable AIGLX if necessary 140.Pq Pa xorg.conf : 141.Bd -literal -offset indent 142Section "ServerFlags" 143 Option "AIGLX" "off" 144EndSection 145 146Section "Extensions" 147 Option "Composite" "Disable" 148EndSection 149.Ed 150.Pp 151.Cd options DRM_DEBUG 152can slow DRI down a lot, disable it once 153.Nm 154works. 155