linux/drivers/gpu/drm
Chris Wilson 8325a09dd0 drm/i915: Bump the inactive LRU on set-to-GTT-domain
Currently, we only bump the inactive LRU of an object when we bind
into the GTT for a page-fault. As the object may be used many times
before its mapping is zapped, we do not mark it as active as
frequently as we should. Userspace should be calling set-to-GTT-domain
before each pointer deference (for synchronous access) and so is a
good place to mark the buffer as active.

Marking the buffer as recently used places it at the end of the
inactive eviction queue, though still before anything with outstanding
rendering. This reduces the likelihood of evicting a buffer that is
going to be used again by the CPU in the near future. This way we can
hopefully avoid to kick out upload buffers right before we use them on
the gpu.

Note that we need to check that the object is not active or pinned,
for otherwise we create havoc on the active/pinned lists, which also
use obj->mm_list.

The active lists are sorted by and evicted in last GPU rendering
order, access by the CPU to a still active buffer therefore does not
affect its eviction ordering. Pinned objects are currently excluded
from eviction, therefore the only list that we need to bump for GTT
access by the CPU is the inactive list.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
[danvet: Added further explanations to the commit message as discussed
on irc.]
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
2012-05-03 11:18:10 +02:00
..
exynos drm/exynos: fix to pointer manager member of struct exynos_drm_subdrv 2012-04-12 14:51:27 +09:00
gma500 gma500: Set the mapping mask 2012-04-27 09:24:36 +01:00
i2c drm: add convenience function to create an range property 2012-02-09 10:15:25 +00:00
i810 drm: drop setting vm_file to filp 2012-03-05 11:19:08 +00:00
i915 drm/i915: Bump the inactive LRU on set-to-GTT-domain 2012-05-03 11:18:10 +02:00
mga drm: move pci bus master enable into driver. 2012-02-16 18:31:07 +00:00
nouveau Revert "nouveau/bios: Fix tracking of BIOS image data" 2012-04-04 08:16:25 -07:00
r128 drm: move pci bus master enable into driver. 2012-02-16 18:31:07 +00:00
radeon Merge tag 'drm-intel-next-2012-04-23' of git://people.freedesktop.org/~danvet/drm-intel into drm-core-next 2012-05-02 09:22:29 +01:00
savage drm/savage: fix integer overflows in savage_bci_cmdbuf() 2012-04-10 10:22:51 +01:00
sis drm: move pci bus master enable into driver. 2012-02-16 18:31:07 +00:00
tdfx drm: Make the per-driver file_operations struct const 2011-11-11 11:14:47 +00:00
ttm Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2012-03-22 13:08:22 -07:00
udl mm, drm/udl: fixup vma flags on mmap 2012-04-02 11:08:17 +01:00
via drm: move pci bus master enable into driver. 2012-02-16 18:31:07 +00:00
vmwgfx Merge branch 'drm-next' of git://people.freedesktop.org/~airlied/linux 2012-03-22 13:08:22 -07:00
ati_pcigart.c gpu: Add export.h as required to drivers/gpu files. 2011-10-31 19:32:03 -04:00
drm_agpsupport.c
drm_auth.c drm: Fix authentication kernel crash 2012-01-25 09:27:45 +00:00
drm_buffer.c gpu: Add export.h as required to drivers/gpu files. 2011-10-31 19:32:03 -04:00
drm_bufs.c gpu: Add export.h as required to drivers/gpu files. 2011-10-31 19:32:03 -04:00
drm_cache.c Merge branch 'drm-intel-next' of git://people.freedesktop.org/~danvet/drm-intel into drm-core-next 2012-04-12 10:27:01 +01:00
drm_context.c drm: Unify and fix idr error handling 2012-04-24 09:50:20 +01:00
drm_crtc.c drm: Unify and fix idr error handling 2012-04-24 09:50:20 +01:00
drm_crtc_helper.c drm: Move drm_format_num_planes() to drm_crtc.c 2012-04-20 12:37:11 +01:00
drm_debugfs.c drm: serialize access to list of debugfs files 2011-11-11 11:05:19 +00:00
drm_dma.c gpu: Add export.h as required to drivers/gpu files. 2011-10-31 19:32:03 -04:00
drm_dp_i2c_helper.c
drm_drv.c drm: base prime/dma-buf support (v5) 2012-03-30 11:52:44 +01:00
drm_edid.c drm: Store vendor IDs directly in the EDID quirk structure 2012-04-27 08:25:13 +01:00
drm_edid_load.c drm/edid: fix collision between two patches breaking build 2012-04-30 07:26:16 +01:00
drm_edid_modes.h drm: replace open-coded ARRAY_SIZE with macro 2012-04-20 13:12:16 +01:00
drm_encoder_slave.c gpu: add module.h to drivers/gpu files as required. 2011-10-31 19:32:03 -04:00
drm_fb_helper.c drm/edid: Allow drm_mode_find_dmt to hunt for reduced-blanking modes 2012-04-20 12:57:03 +01:00
drm_fops.c drm: base prime/dma-buf support (v5) 2012-03-30 11:52:44 +01:00
drm_gem.c drm: Unify and fix idr error handling 2012-04-24 09:50:20 +01:00
drm_global.c
drm_hashtab.c gpu: Add export.h as required to drivers/gpu files. 2011-10-31 19:32:03 -04:00
drm_info.c
drm_ioc32.c drivers/gpu/drm/drm_ioc32.c: initialize all fields 2012-02-03 09:47:32 +00:00
drm_ioctl.c drm: add some caps for userspace to discover more info for dumb KMS driver (v2) 2012-02-16 18:35:11 +00:00
drm_irq.c drm: remove unused code 2012-02-29 10:18:29 +00:00
drm_lock.c drm: add missing exports for i810 driver. 2011-12-22 19:09:01 +00:00
drm_memory.c drm: remove unused code 2012-02-29 10:18:29 +00:00
drm_mm.c gpu: Add export.h as required to drivers/gpu files. 2011-10-31 19:32:03 -04:00
drm_modes.c drm: Add drm_mode_copy() 2012-03-15 09:52:51 +00:00
drm_pci.c drm: move pci bus master enable into driver. 2012-02-16 18:31:07 +00:00
drm_platform.c drm: cope with platformdev->id == -1 2012-03-07 14:03:40 +00:00
drm_prime.c drm: base prime/dma-buf support (v5) 2012-03-30 11:52:44 +01:00
drm_proc.c gpu: Add export.h as required to drivers/gpu files. 2011-10-31 19:32:03 -04:00
drm_scatter.c
drm_stub.c drm: Unify and fix idr error handling 2012-04-24 09:50:20 +01:00
drm_sysfs.c drm/sysfs: protect sysfs removal code against being run twice. 2012-03-15 13:35:31 +00:00
drm_trace.h
drm_trace_points.c
drm_usb.c drm: fix build with UDL if USB is a module 2012-03-16 09:28:03 +00:00
drm_vm.c drm: add core support for unplugging a device (v2) 2012-03-15 13:35:33 +00:00
Kconfig drm: base prime/dma-buf support (v5) 2012-03-30 11:52:44 +01:00
Makefile drm: base prime/dma-buf support (v5) 2012-03-30 11:52:44 +01:00
README.drm

************************************************************
* For the very latest on DRI development, please see:      *
*     http://dri.freedesktop.org/                          *
************************************************************

The Direct Rendering Manager (drm) is a device-independent kernel-level
device driver that provides support for the XFree86 Direct Rendering
Infrastructure (DRI).

The DRM supports the Direct Rendering Infrastructure (DRI) in four major
ways:

    1. The DRM provides synchronized access to the graphics hardware via
       the use of an optimized two-tiered lock.

    2. The DRM enforces the DRI security policy for access to the graphics
       hardware by only allowing authenticated X11 clients access to
       restricted regions of memory.

    3. The DRM provides a generic DMA engine, complete with multiple
       queues and the ability to detect the need for an OpenGL context
       switch.

    4. The DRM is extensible via the use of small device-specific modules
       that rely extensively on the API exported by the DRM module.


Documentation on the DRI is available from:
    http://dri.freedesktop.org/wiki/Documentation
    http://sourceforge.net/project/showfiles.php?group_id=387
    http://dri.sourceforge.net/doc/

For specific information about kernel-level support, see:

    The Direct Rendering Manager, Kernel Support for the Direct Rendering
    Infrastructure
    http://dri.sourceforge.net/doc/drm_low_level.html

    Hardware Locking for the Direct Rendering Infrastructure
    http://dri.sourceforge.net/doc/hardware_locking_low_level.html

    A Security Analysis of the Direct Rendering Infrastructure
    http://dri.sourceforge.net/doc/security_low_level.html