1. 04 12月, 2009 1 次提交
  2. 18 11月, 2009 1 次提交
  3. 26 10月, 2009 1 次提交
  4. 19 6月, 2009 1 次提交
  5. 29 3月, 2009 1 次提交
  6. 16 3月, 2009 1 次提交
    • J
      Rationalize fasync return values · 60aa4924
      Jonathan Corbet 提交于
      Most fasync implementations do something like:
      
           return fasync_helper(...);
      
      But fasync_helper() will return a positive value at times - a feature used
      in at least one place.  Thus, a number of other drivers do:
      
           err = fasync_helper(...);
           if (err < 0)
                   return err;
           return 0;
      
      In the interests of consistency and more concise code, it makes sense to
      map positive return values onto zero where ->fasync() is called.
      
      Cc: Al Viro <viro@ZenIV.linux.org.uk>
      Signed-off-by: NJonathan Corbet <corbet@lwn.net>
      60aa4924
  7. 03 3月, 2009 1 次提交
  8. 20 2月, 2009 1 次提交
  9. 07 1月, 2009 1 次提交
  10. 29 12月, 2008 3 次提交
    • D
      DRM: add mode setting support · f453ba04
      Dave Airlie 提交于
      Add mode setting support to the DRM layer.
      
      This is a fairly big chunk of work that allows DRM drivers to provide
      full output control and configuration capabilities to userspace.  It was
      motivated by several factors:
        - the fb layer's APIs aren't suited for anything but simple
          configurations
        - coordination between the fb layer, DRM layer, and various userspace
          drivers is poor to non-existent (radeonfb excepted)
        - user level mode setting drivers makes displaying panic & oops
          messages more difficult
        - suspend/resume of graphics state is possible in many more
          configurations with kernel level support
      
      This commit just adds the core DRM part of the mode setting APIs.
      Driver specific commits using these new structure and APIs will follow.
      
      Co-authors: Jesse Barnes <jbarnes@virtuousgeek.org>, Jakob Bornecrantz <jakob@tungstengraphics.com>
      Contributors: Alan Hourihane <alanh@tungstengraphics.com>, Maarten Maathuis <madman2003@gmail.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NEric Anholt <eric@anholt.net>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      f453ba04
    • J
      drm: GEM mmap support · a2c0a97b
      Jesse Barnes 提交于
      Add core support for mapping of GEM objects.  Drivers should provide a
      vm_operations_struct if they want to support page faulting of objects.
      The code for handling GEM object offsets was taken from TTM, which was
      written by Thomas Hellström.
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NEric Anholt <eric@anholt.net>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      a2c0a97b
    • D
      drm: move to kref per-master structures. · 7c1c2871
      Dave Airlie 提交于
      This is step one towards having multiple masters sharing a drm
      device in order to get fast-user-switching to work.
      
      It splits out the information associated with the drm master
      into a separate kref counted structure, and allocates this when
      a master opens the device node. It also allows the current master
      to abdicate (say while VT switched), and a new master to take over
      the hardware.
      
      It moves the Intel and radeon drivers to using the sarea from
      within the new master structures.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      7c1c2871
  11. 02 11月, 2008 1 次提交
    • A
      saner FASYNC handling on file close · 233e70f4
      Al Viro 提交于
      As it is, all instances of ->release() for files that have ->fasync()
      need to remember to evict file from fasync lists; forgetting that
      creates a hole and we actually have a bunch that *does* forget.
      
      So let's keep our lives simple - let __fput() check FASYNC in
      file->f_flags and call ->fasync() there if it's been set.  And lose that
      crap in ->release() instances - leaving it there is still valid, but we
      don't have to bother anymore.
      Signed-off-by: NAl Viro <viro@zeniv.linux.org.uk>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      233e70f4
  12. 18 10月, 2008 2 次提交
  13. 14 7月, 2008 1 次提交
    • D
      drm: reorganise drm tree to be more future proof. · c0e09200
      Dave Airlie 提交于
      With the coming of kernel based modesetting and the memory manager stuff,
      the everything in one directory approach was getting very ugly and
      starting to be unmanageable.
      
      This restructures the drm along the lines of other kernel components.
      
      It creates a drivers/gpu/drm directory and moves the hw drivers into
      subdirectores. It moves the includes into an include/drm, and
      sets up the unifdef for the userspace headers we should be exporting.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      c0e09200
  14. 21 6月, 2008 1 次提交
  15. 07 5月, 2008 1 次提交
  16. 26 4月, 2008 2 次提交
  17. 17 3月, 2008 1 次提交
    • M
      drm: Fix race that can lockup the kernel · 9df5808c
      Mike Isely 提交于
      The i915_vblank_swap() function schedules an automatic buffer swap
      upon receipt of the vertical sync interrupt.  Such an operation is
      lengthy so it can't be allowed to happen in normal interrupt context,
      thus the DRM implements this by scheduling the work in a kernel
      softirq-scheduled tasklet.  In order for the buffer swap to work
      safely, the DRM's central lock must be taken, via a call to
      drm_lock_take() located in drivers/char/drm/drm_irq.c within the
      function drm_locked_tasklet_func().  The lock-taking logic uses a
      non-interrupt-blocking spinlock to implement the manipulations needed
      to take the lock.  This semantic would be safe if all attempts to use
      the spinlock only happen from process context.  However this buffer
      swap happens from softirq context which is really a form of interrupt
      context.  Thus we have an unsafe situation, in that
      drm_locked_tasklet_func() can block on a spinlock already taken by a
      thread in process context which will never get scheduled again because
      of the blocked softirq tasklet.  This wedges the kernel hard.
      
      To trigger this bug, run a dual-head cloned mode configuration which
      uses the i915 drm, then execute an opengl application which
      synchronizes buffer swaps against the vertical sync interrupt.  In my
      testing, a lockup always results after running anywhere from 5 minutes
      to an hour and a half.  I believe dual-head is needed to really
      trigger the problem because then the vertical sync interrupt handling
      is no longer predictable (due to being interrupt-sourced from two
      different heads running at different speeds).  This raises the
      probability of the tasklet trying to run while the userspace DRI is
      doing things to the GPU (and manipulating the DRM lock).
      
      The fix is to change the relevant spinlock semantics to be the
      interrupt-blocking form.  After this change I am no longer able to
      trigger the lockup; the longest test run so far was 20 hours (test
      stopped after that point).
      
      Note: I have examined the places where this spinlock is being
      employed; all are reasonably short bounded sequences and should be
      suitable for interrupts being blocked without impacting overall kernel
      interrupt response latency.
      Signed-off-by: NMike Isely <isely@pobox.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      9df5808c
  18. 20 10月, 2007 1 次提交
  19. 15 10月, 2007 2 次提交
  20. 11 7月, 2007 4 次提交
  21. 23 3月, 2007 1 次提交
    • T
      drm: fix driver deadlock with AIGLX and reclaim_buffers_locked · 040ac320
      Thomas Hellstrom 提交于
      Bugzilla Bug #9457
      
      Add refcounting of user waiters to the DRM hardware lock, so that we can use
      DRM_LOCK_CONT flag more conservatively.
      
      Also add a kernel waiter refcount that if nonzero transfers the lock for the
      kernel context when it is released. This is useful when waiting for idle and can be used for very simple fence object driver implementations for the new memory manager
      Signed-off-by: NDave Airlie <airlied@linux.ie>
      040ac320
  22. 19 3月, 2007 1 次提交
  23. 11 3月, 2007 1 次提交
  24. 22 9月, 2006 3 次提交
  25. 29 3月, 2006 1 次提交
  26. 02 2月, 2006 1 次提交
  27. 02 1月, 2006 1 次提交
  28. 11 11月, 2005 1 次提交
  29. 10 11月, 2005 2 次提交
    • D
      drm: remove drm_init.c it is no longer needed · 3f9df54d
      Dave Airlie 提交于
      Move drm_cpu_valid into drm_fops.c
      Signed-off-by: NDave Airlie <airlied@linux.ie>
      3f9df54d
    • D
      drm: rename driver hooks more understandably · 22eae947
      Dave Airlie 提交于
      Rename the driver hooks in the DRM to something a little more understandable:
      preinit         ->      load
      postinit        ->      (removed)
      presetup        ->      firstopen
      postsetup       ->      (removed)
      open_helper     ->      open
      prerelease      ->      preclose
      free_filp_priv  ->      postclose
      pretakedown     ->      lastclose
      postcleanup     ->      unload
      release         ->      reclaim_buffers_locked
      version         ->      (removed)
      
      postinit and version were replaced with generic code in the Linux DRM (drivers
      now set their version numbers and description in the driver structure, like on
      BSD).  postsetup wasn't used at all.  Fixes the savage hooks for
      initializing and tearing down mappings at the right times.  Testing involved at
      least starting X, running glxgears, killing glxgears, exiting X, and repeating.
      
      Tested on:      FreeBSD (g200, g400, r200, r128)
                      Linux (r200, savage4)
      
      From: Eric Anholt <anholt@freebsd.org>
      Signed-off-by: NDave Airlie <airlied@linux.ie>
      22eae947