1. 09 7月, 2014 5 次提交
  2. 08 7月, 2014 30 次提交
  3. 07 7月, 2014 5 次提交
    • V
      drm/i915: Unpin last_context at reset · 4bfad3dd
      Ville Syrjälä 提交于
      We're forgetting to unpin the last_context from the ggtt at GPU reset
      time. This leads to the vma pin_count leaking at every reset if the
      last context wasn't the ring default context. Further use of the same
      context will trigger the pin_count check in i915_gem_object_pin() and
      userspace will be faced with EBUSY as a result.
      
      This plaques kms_flip rather badly since it performs lots of resets,
      and every fd has its own default context these days.
      
      Fix the problem by properly unpinning the last context at reset.
      
      This regression seems to back to
      
      commit acce9ffa
      Author: Ben Widawsky <ben@bwidawsk.net>
      Date:   Fri Dec 6 14:11:03 2013 -0800
      
         drm/i915: Better reset handling for contexts
      
      Testcase: igt/gem_ctx_exec/reset-pin-leak
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      4bfad3dd
    • D
      drm/i915: rework digital port IRQ handling (v2) · 13cf5504
      Dave Airlie 提交于
      The digital ports from Ironlake and up have the ability to distinguish
      between long and short HPD pulses. Displayport 1.1 only uses the short
      form to request link retraining usually, so we haven't really needed
      support for it until now.
      
      However with DP 1.2 MST we need to handle the short irqs on their
      own outside the modesetting locking the long hpd's involve. This
      patch adds the framework to distinguish between short/long to the
      current code base, to lay the basis for future DP 1.2 MST work.
      
      This should mean we get better bisectability in case of regression
      due to the new irq handling.
      
      v2: add GM45 support (untested, due to lack of hw)
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      Reviewed-by: NTodd Previte <tprevite@gmail.com>
      [danvet: Fix conflicts in i915_irq.c with Oscar Mateo's irq handling
      race fixes and a trivial one in intel_drv.h with the psr code.]
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      13cf5504
    • I
      drm/i915: gmch: fix stuck primary plane due to memory self-refresh mode · 564ed191
      Imre Deak 提交于
      Blanking/unblanking the console in a loop on an Asus T100 sometimes
      leaves the console blank. After some digging I found that applying
      
      commit 61bc95c1
      Author: Egbert Eich <eich@suse.com>
      Date:   Mon Mar 4 09:24:38 2013 -0500
      
          DRM/i915: On G45 enable cursor plane briefly after enabling the display plane.
      
      fixed VLV too.
      
      In my case the problem seemed to happen already during the previous crtc
      disabling and went away if I disabled self-refresh mode before disabling
      the primary plane.
      
      The root cause for this is that updates from the shadow to live plane
      control register are blocked at vblank time if the memory self-refresh
      mode (aka max-fifo mode on VLV) is active at that moment. The controller
      checks at frame start time if the CPU is in C0 and the self-refresh mode
      enable bit is set and if so activates self-reresh mode, otherwise
      deactivates it. So to make sure that the plane truly gets disabled before
      pipe-off we have to:
      
      1. disable memory self-refresh mode
      2. disable plane
      3. wait for vblank
      4. disable pipe
      5. wait for pipe-off
      
      v2:
      - add explanation for the root cause from HW team (Cesar Mancini et al)
      - remove note about the CPU C7S state, in my latest tests disabling it
        alone didn't make a difference
      - add vblank between disabling plane and pipe (Ville)
      - apply the same workaround for all gmch platforms (Ville)
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NVijay Purushothaman <vijay.a.purushothaman@intel.com>
      Reviewed-by: Deepak S<deepak.s@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      564ed191
    • I
      drm/i915: gmch: set SR WMs to valid values before enabling them · 9858425c
      Imre Deak 提交于
      Atm it's possible that we enable the memory self-refresh mode before the
      watermark levels used by this mode are programmed with valid values. So
      move the enabling after we programmed the WM levels.
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NVijay Purushothaman <vijay.a.purushothaman@intel.com>
      Reviewed-by: Deepak S<deepak.s@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      9858425c
    • I
      drm/i915: gmch: factor out intel_set_memory_cxsr · 5209b1f4
      Imre Deak 提交于
      This functionality will be also needed by an upcoming patch, so factor
      it out. As a bonus this also makes things a bit more uniform across
      platforms. Note that this also changes the register read-modify-write
      to a simple write during disabling. This is what we do during enabling
      anyway and according to the spec all the relevant bits are reserved-MBZ
      or reserved with a 0 default value.
      
      v2:
      - unchanged
      v3:
      - fix missing cxsr disabling on pineview (Deepak)
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NDeepak S <deepak.s@linux.intel.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      5209b1f4