1. 07 8月, 2014 11 次提交
  2. 22 5月, 2014 1 次提交
  3. 21 5月, 2014 6 次提交
  4. 23 4月, 2014 4 次提交
  5. 22 4月, 2014 5 次提交
  6. 18 4月, 2014 1 次提交
  7. 20 1月, 2014 9 次提交
  8. 18 12月, 2013 2 次提交
  9. 06 11月, 2013 1 次提交
    • M
      drm: Push latency sensitive bits of vblank scanoutpos timestamping into kms drivers. · 8f6fce03
      Mario Kleiner 提交于
      A change in locking of some kms drivers (currently intel-kms) make
      the old approach too inaccurate and also incompatible with the
      PREEMPT_RT realtime kernel patchset.
      
      The driver->get_scanout_position() method of intel-kms now needs
      to aquire a spinlock, which clashes badly with the former
      preempt_disable() calls in the drm, and it also introduces larger
      delays and timing uncertainty on a contended lock than acceptable.
      
      This patch changes the prototype of driver->get_scanout_position()
      to require/allow kms drivers to perform the ktime_get() system time
      queries which go along with actual scanout position readout in a way
      that provides maximum precision and to return those timestamps to
      the drm. kms drivers implementations of get_scanout_position() are
      asked to implement timestamping and scanoutpos readout in a way
      that is as precise as possible and compatible with preempt_disable()
      on a PREMPT_RT kernel. A driver should follow this pattern in
      get_scanout_position() for precision and compatibility:
      
      spin_lock...(...);
      preempt_disable_rt(); // On a PREEMPT_RT kernel, otherwise omit.
      if (stime) *stime = ktime_get();
      ... Minimum amount of MMIO register reads to get scanout position ...
      ... no taking of locks allowed here! ...
      if (etime) *etime = ktime_get();
      preempt_enable_rt(); // On PREEMPT_RT kernel, otherwise omit.
      spin_unlock...(...);
      
      v2: Fix formatting of new multi-line code comments.
      Signed-off-by: NMario Kleiner <mario.kleiner.de@gmail.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Reviewed-by: NAlex Deucher <alexander.deucher@amd.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      8f6fce03