···66#77config DRM88 tristate "Direct Rendering Manager (XFree86 4.1.0 and higher DRI support)"99- depends on AGP || AGP=n99+ depends on (AGP || AGP=n) && PCI1010 help1111 Kernel-level support for the Direct Rendering Infrastructure (DRI)1212 introduced in XFree86 4.0. If you say Y here, you need to select
+22-2
drivers/char/drm/i915_dma.c
···11/* i915_dma.c -- DMA support for the I915 -*- linux-c -*-22 */33/**************************************************************************44- * 44+ *55 * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.66 * All Rights Reserved.77- * 77+ *88+ * Permission is hereby granted, free of charge, to any person obtaining a99+ * copy of this software and associated documentation files (the1010+ * "Software"), to deal in the Software without restriction, including1111+ * without limitation the rights to use, copy, modify, merge, publish,1212+ * distribute, sub license, and/or sell copies of the Software, and to1313+ * permit persons to whom the Software is furnished to do so, subject to1414+ * the following conditions:1515+ *1616+ * The above copyright notice and this permission notice (including the1717+ * next paragraph) shall be included in all copies or substantial portions1818+ * of the Software.1919+ *2020+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS2121+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF2222+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.2323+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR2424+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,2525+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE2626+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.2727+ *828 **************************************************************************/9291030#include "drmP.h"
+27
drivers/char/drm/i915_drm.h
···11+/**************************************************************************22+ *33+ * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.44+ * All Rights Reserved.55+ *66+ * Permission is hereby granted, free of charge, to any person obtaining a77+ * copy of this software and associated documentation files (the88+ * "Software"), to deal in the Software without restriction, including99+ * without limitation the rights to use, copy, modify, merge, publish,1010+ * distribute, sub license, and/or sell copies of the Software, and to1111+ * permit persons to whom the Software is furnished to do so, subject to1212+ * the following conditions:1313+ *1414+ * The above copyright notice and this permission notice (including the1515+ * next paragraph) shall be included in all copies or substantial portions1616+ * of the Software.1717+ *1818+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS1919+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF2020+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.2121+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR2222+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,2323+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE2424+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.2525+ *2626+ **************************************************************************/2727+128#ifndef _I915_DRM_H_229#define _I915_DRM_H_330
+22-3
drivers/char/drm/i915_drv.c
···11/* i915_drv.c -- i830,i845,i855,i865,i915 driver -*- linux-c -*-22 */33-43/**************************************************************************55- * 44+ *65 * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.76 * All Rights Reserved.88- * 77+ *88+ * Permission is hereby granted, free of charge, to any person obtaining a99+ * copy of this software and associated documentation files (the1010+ * "Software"), to deal in the Software without restriction, including1111+ * without limitation the rights to use, copy, modify, merge, publish,1212+ * distribute, sub license, and/or sell copies of the Software, and to1313+ * permit persons to whom the Software is furnished to do so, subject to1414+ * the following conditions:1515+ *1616+ * The above copyright notice and this permission notice (including the1717+ * next paragraph) shall be included in all copies or substantial portions1818+ * of the Software.1919+ *2020+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS2121+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF2222+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.2323+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR2424+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,2525+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE2626+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.2727+ *928 **************************************************************************/10291130#include "drmP.h"
+22-2
drivers/char/drm/i915_drv.h
···11/* i915_drv.h -- Private header for the I915 driver -*- linux-c -*-22 */33/**************************************************************************44- * 44+ *55 * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.66 * All Rights Reserved.77- * 77+ *88+ * Permission is hereby granted, free of charge, to any person obtaining a99+ * copy of this software and associated documentation files (the1010+ * "Software"), to deal in the Software without restriction, including1111+ * without limitation the rights to use, copy, modify, merge, publish,1212+ * distribute, sub license, and/or sell copies of the Software, and to1313+ * permit persons to whom the Software is furnished to do so, subject to1414+ * the following conditions:1515+ *1616+ * The above copyright notice and this permission notice (including the1717+ * next paragraph) shall be included in all copies or substantial portions1818+ * of the Software.1919+ *2020+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS2121+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF2222+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.2323+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR2424+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,2525+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE2626+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.2727+ *828 **************************************************************************/9291030#ifndef _I915_DRV_H_
+22-2
drivers/char/drm/i915_irq.c
···11/* i915_dma.c -- DMA support for the I915 -*- linux-c -*-22 */33/**************************************************************************44- * 44+ *55 * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.66 * All Rights Reserved.77- * 77+ *88+ * Permission is hereby granted, free of charge, to any person obtaining a99+ * copy of this software and associated documentation files (the1010+ * "Software"), to deal in the Software without restriction, including1111+ * without limitation the rights to use, copy, modify, merge, publish,1212+ * distribute, sub license, and/or sell copies of the Software, and to1313+ * permit persons to whom the Software is furnished to do so, subject to1414+ * the following conditions:1515+ *1616+ * The above copyright notice and this permission notice (including the1717+ * next paragraph) shall be included in all copies or substantial portions1818+ * of the Software.1919+ *2020+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS2121+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF2222+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.2323+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR2424+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,2525+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE2626+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.2727+ *828 **************************************************************************/9291030#include "drmP.h"
+22-2
drivers/char/drm/i915_mem.c
···11/* i915_mem.c -- Simple agp/fb memory manager for i915 -*- linux-c -*-22 */33/**************************************************************************44- * 44+ *55 * Copyright 2003 Tungsten Graphics, Inc., Cedar Park, Texas.66 * All Rights Reserved.77- * 77+ *88+ * Permission is hereby granted, free of charge, to any person obtaining a99+ * copy of this software and associated documentation files (the1010+ * "Software"), to deal in the Software without restriction, including1111+ * without limitation the rights to use, copy, modify, merge, publish,1212+ * distribute, sub license, and/or sell copies of the Software, and to1313+ * permit persons to whom the Software is furnished to do so, subject to1414+ * the following conditions:1515+ *1616+ * The above copyright notice and this permission notice (including the1717+ * next paragraph) shall be included in all copies or substantial portions1818+ * of the Software.1919+ *2020+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS2121+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF2222+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.2323+ * IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR2424+ * ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,2525+ * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE2626+ * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.2727+ *828 **************************************************************************/9291030#include "drmP.h"
+13-14
drivers/char/drm/radeon_irq.c
···3535#include "radeon_drm.h"3636#include "radeon_drv.h"37373838+static __inline__ u32 radeon_acknowledge_irqs(drm_radeon_private_t *dev_priv, u32 mask)3939+{4040+ u32 irqs = RADEON_READ(RADEON_GEN_INT_STATUS) & mask;4141+ if (irqs)4242+ RADEON_WRITE(RADEON_GEN_INT_STATUS, irqs);4343+ return irqs;4444+}4545+3846/* Interrupts - Used for device synchronization and flushing in the3947 * following circumstances:4048 *···7163 /* Only consider the bits we're interested in - others could be used7264 * outside the DRM7365 */7474- stat = RADEON_READ(RADEON_GEN_INT_STATUS)7575- & (RADEON_SW_INT_TEST | RADEON_CRTC_VBLANK_STAT);6666+ stat = radeon_acknowledge_irqs(dev_priv, (RADEON_SW_INT_TEST_ACK | 6767+ RADEON_CRTC_VBLANK_STAT));7668 if (!stat)7769 return IRQ_NONE;7870···8880 drm_vbl_send_signals( dev );8981 }90829191- /* Acknowledge interrupts we handle */9292- RADEON_WRITE(RADEON_GEN_INT_STATUS, stat);9383 return IRQ_HANDLED;9494-}9595-9696-static __inline__ void radeon_acknowledge_irqs(drm_radeon_private_t *dev_priv)9797-{9898- u32 tmp = RADEON_READ( RADEON_GEN_INT_STATUS )9999- & (RADEON_SW_INT_TEST_ACK | RADEON_CRTC_VBLANK_STAT);100100- if (tmp)101101- RADEON_WRITE( RADEON_GEN_INT_STATUS, tmp );10284}1038510486static int radeon_emit_irq(drm_device_t *dev)···139141 return DRM_ERR(EINVAL);140142 }141143142142- radeon_acknowledge_irqs( dev_priv );144144+ radeon_acknowledge_irqs(dev_priv, RADEON_CRTC_VBLANK_STAT);143145144146 dev_priv->stats.boxes |= RADEON_BOX_WAIT_IDLE;145147···217219 RADEON_WRITE( RADEON_GEN_INT_CNTL, 0 );218220219221 /* Clear bits if they're already high */220220- radeon_acknowledge_irqs( dev_priv );222222+ radeon_acknowledge_irqs(dev_priv, (RADEON_SW_INT_TEST_ACK |223223+ RADEON_CRTC_VBLANK_STAT));221224}222225223226void radeon_driver_irq_postinstall( drm_device_t *dev ) {