1. 03 5月, 2016 2 次提交
  2. 28 4月, 2016 1 次提交
  3. 24 4月, 2016 1 次提交
  4. 14 4月, 2016 1 次提交
  5. 13 4月, 2016 2 次提交
  6. 07 4月, 2016 2 次提交
  7. 06 4月, 2016 2 次提交
  8. 31 3月, 2016 1 次提交
    • J
      drm/i915: Refer to GGTT {,VM} consistently · 72e96d64
      Joonas Lahtinen 提交于
      Refer to the GGTT VM consistently as "ggtt->base" instead of just "ggtt",
      "vm" or indirectly through other variables like "dev_priv->ggtt.base"
      to avoid confusion with the i915_ggtt object itself and PPGTT VMs.
      
      Refer to the GGTT as "ggtt" instead of indirectly through chaining.
      
      As a bonus gets rid of the long-standing i915_obj_to_ggtt vs.
      i915_gem_obj_to_ggtt conflict, due to removal of i915_obj_to_ggtt!
      
      v2:
      - Added some more after grepping sources with Chris
      
      v3:
      - Refer to GGTT VM through ggtt->base consistently instead of ggtt_vm
        (Chris)
      
      v4:
      - Convert all dev_priv->ggtt->foo accesses to ggtt->foo.
      
      v5:
      - Make patch checker happy
      
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NJoonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      72e96d64
  9. 24 3月, 2016 1 次提交
  10. 18 3月, 2016 1 次提交
  11. 17 3月, 2016 1 次提交
  12. 16 3月, 2016 3 次提交
    • T
      drm/i915: More intel_engine_cs renaming · 666796da
      Tvrtko Ursulin 提交于
      Some trivial ones, first pass done with Coccinelle:
      
      @@
      @@
      (
      - I915_NUM_RINGS
      + I915_NUM_ENGINES
      |
      - intel_ring_flag
      + intel_engine_flag
      |
      - for_each_ring
      + for_each_engine
      |
      - i915_gem_request_get_ring
      + i915_gem_request_get_engine
      |
      - intel_ring_idle
      + intel_engine_idle
      |
      - i915_gem_reset_ring_status
      + i915_gem_reset_engine_status
      |
      - i915_gem_reset_ring_cleanup
      + i915_gem_reset_engine_cleanup
      |
      - init_ring_lists
      + init_engine_lists
      )
      
      But that didn't fully work so I cleaned it up with:
      
      for f in *.[hc]; do sed -i -e s/I915_NUM_RINGS/I915_NUM_ENGINES/ $f; done
      for f in *.[hc]; do sed -i -e s/i915_gem_request_get_ring/i915_gem_request_get_engine/ $f; done
      for f in *.[hc]; do sed -i -e s/intel_ring_flag/intel_engine_flag/ $f; done
      for f in *.[hc]; do sed -i -e s/intel_ring_idle/intel_engine_idle/ $f; done
      for f in *.[hc]; do sed -i -e s/init_ring_lists/init_engine_lists/ $f; done
      for f in *.[hc]; do sed -i -e s/i915_gem_reset_ring_cleanup/i915_gem_reset_engine_cleanup/ $f; done
      for f in *.[hc]; do sed -i -e s/i915_gem_reset_ring_status/i915_gem_reset_engine_status/ $f; done
      
      v2: Rebase.
      Signed-off-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      666796da
    • T
      drm/i915: Rename intel_engine_cs struct members · 4a570db5
      Tvrtko Ursulin 提交于
      below and a couple manual fixups.
      
      @@
      identifier I, J;
      @@
      struct I {
      ...
      - struct intel_engine_cs *J;
      + struct intel_engine_cs *engine;
      ...
      }
      @@
      identifier I, J;
      @@
      struct I {
      ...
      - struct intel_engine_cs J;
      + struct intel_engine_cs engine;
      ...
      }
      @@
      struct drm_i915_private *d;
      @@
      (
      - d->ring
      + d->engine
      )
      @@
      struct i915_execbuffer_params *p;
      @@
      (
      - p->ring
      + p->engine
      )
      @@
      struct intel_ringbuffer *r;
      @@
      (
      - r->ring
      + r->engine
      )
      @@
      struct drm_i915_gem_request *req;
      @@
      (
      - req->ring
      + req->engine
      )
      
      v2: Script missed the tracepoint code - fixed up by hand.
      Signed-off-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      4a570db5
    • T
      drm/i915: Rename local struct intel_engine_cs variables · e2f80391
      Tvrtko Ursulin 提交于
      Done by the Coccinelle script below plus a manual
      intervention to GEN8_RING_SEMAPHORE_INIT.
      
      @@
      expression E;
      @@
      - struct intel_engine_cs *ring = E;
      + struct intel_engine_cs *engine = E;
      <+...
      - ring
      + engine
      ...+>
      @@
      @@
      - struct intel_engine_cs *ring;
      + struct intel_engine_cs *engine;
      <+...
      - ring
      + engine
      ...+>
      Signed-off-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NChris Wilson <chris@chris-wilson.co.uk>
      e2f80391
  13. 09 3月, 2016 1 次提交
    • M
      drm/i915: Only use sanitized values for ILK watermarks · 71f0a626
      Maarten Lankhorst 提交于
      The raw watermark values are needed when planes are not part of the state,
      but this introduced a regression and possibly an overflow when merging
      the watermarks because invalid values may end up used. Solve this by calculating
      raw watermarks for all levels, and only setting non-zero values when the level
      is valid.
      
      Fixes the SNB warning:
         WARNING: CPU: 1 PID: 25405 at drivers/gpu/drm/i915/intel_pm.c:2580 ilk_program_watermarks+0x7b2/0x9d0 [i915]()
         WARN_ON(wm_lp != 1)
         Modules linked in: i915 drm_kms_helper drm bluetooth fuse iTCO_wdt iTCO_vendor_support syscopyarea sysfillrect sysimgblt fb_sys_fops tpm_tis mei_me e1000e snd_hda_codec_hdmi pcspkr tpm mei i2c_i801 lpc_ich snd_hda_codec snd_hda_core
         CPU: 1 PID: 25405 Comm: kms_universal_p Tainted: G     U  W       4.5.0-rc6apollolake+ #462
         Hardware name:                  /DH67GD, BIOS BLH6710H.86A.0160.2012.1204.1156 12/04/2012
          0000000000000000 ffff88009d42b918 ffffffff8143cfab ffff88009d42b960
          ffffffffa0363580 ffff88009d42b950 ffffffff81082746 ffff8800b9a24928
          ffff88009d42ba00 ffff88009d4a0000 0000000000000000 ffff88009d42ba6c
         Call Trace:
          [<ffffffff8143cfab>] dump_stack+0x4d/0x72
          [<ffffffff81082746>] warn_slowpath_common+0x86/0xc0
          [<ffffffff810827cc>] warn_slowpath_fmt+0x4c/0x50
          [<ffffffffa0292862>] ilk_program_watermarks+0x7b2/0x9d0 [i915]
          [<ffffffffa0292cb7>] ilk_initial_watermarks+0x107/0x120 [i915]
          [<ffffffffa02feffa>] intel_pre_plane_update+0x12a/0x190 [i915]
          [<ffffffffa02ffb36>] intel_atomic_commit+0x546/0xd50 [i915]
          [<ffffffffa012c9e7>] drm_atomic_commit+0x37/0x60 [drm]
          [<ffffffffa0217361>] drm_atomic_helper_disable_plane+0xb1/0xf0 [drm_kms_helper]
          [<ffffffffa011cdb4>] __setplane_internal+0x184/0x280 [drm]
          [<ffffffffa012b57a>] ? drm_modeset_lock_all_ctx+0x9a/0xb0 [drm]
          [<ffffffffa012010f>] drm_mode_setplane+0x13f/0x1c0 [drm]
          [<ffffffffa0111b52>] drm_ioctl+0x142/0x590 [drm]
          [<ffffffffa011ffd0>] ? drm_plane_check_pixel_format+0x50/0x50 [drm]
          [<ffffffff811f2744>] ? mntput+0x24/0x40
          [<ffffffff811d28d4>] ? __fput+0x194/0x200
          [<ffffffffa012dec3>] drm_compat_ioctl+0x33/0x40 [drm]
          [<ffffffffa029e1c2>] i915_compat_ioctl+0x32/0x40 [i915]
          [<ffffffff81228d72>] compat_SyS_ioctl+0xc2/0x330
          [<ffffffff810021d5>] ? exit_to_usermode_loop+0x95/0xb0
          [<ffffffff81002d2e>] do_fast_syscall_32+0x9e/0x210
          [<ffffffff8197faf2>] entry_SYSENTER_compat+0x52/0x70
      
      Cc: Matt Roper <matthew.d.roper@intel.com>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Testcase: kms_universal_plane
      Fixes: d81f04c5 ("drm/i915: Allow preservation of watermarks, v2.")
      Signed-off-by: NMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Link: http://patchwork.freedesktop.org/patch/msgid/56DEA1FC.8080703@linux.intel.comReviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      71f0a626
  14. 03 3月, 2016 3 次提交
  15. 01 3月, 2016 2 次提交
    • E
      drm/i915: remove left over dead code · c3454d57
      Eric Engestrom 提交于
      ae80152d ("drm/i915: Rewrite VLV/CHV
      watermark code") removed everything that would have used those vars.
      Signed-off-by: NEric Engestrom <eric.engestrom@imgtec.com>
      Signed-off-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Link: http://patchwork.freedesktop.org/patch/msgid/1456763047-28828-1-git-send-email-eric.engestrom@imgtec.com
      c3454d57
    • M
      drm/i915: Add two-stage ILK-style watermark programming (v11) · ed4a6a7c
      Matt Roper 提交于
      In addition to calculating final watermarks, let's also pre-calculate a
      set of intermediate watermark values at atomic check time.  These
      intermediate watermarks are a combination of the watermarks for the old
      state and the new state; they should satisfy the requirements of both
      states which means they can be programmed immediately when we commit the
      atomic state (without waiting for a vblank).  Once the vblank does
      happen, we can then re-program watermarks to the more optimal final
      value.
      
      v2: Significant rebasing/rewriting.
      
      v3:
       - Move 'need_postvbl_update' flag to CRTC state (Daniel)
       - Don't forget to check intermediate watermark values for validity
         (Maarten)
       - Don't due async watermark optimization; just do it at the end of the
         atomic transaction, after waiting for vblanks.  We do want it to be
         async eventually, but adding that now will cause more trouble for
         Maarten's in-progress work.  (Maarten)
       - Don't allocate space in crtc_state for intermediate watermarks on
         platforms that don't need it (gen9+).
       - Move WaCxSRDisabledForSpriteScaling:ivb into intel_begin_crtc_commit
         now that ilk_update_wm is gone.
      
      v4:
       - Add a wm_mutex to cover updates to intel_crtc->active and the
         need_postvbl_update flag.  Since we don't have async yet it isn't
         terribly important yet, but might as well add it now.
       - Change interface to program watermarks.  Platforms will now expose
         .initial_watermarks() and .optimize_watermarks() functions to do
         watermark programming.  These should lock wm_mutex, copy the
         appropriate state values into intel_crtc->active, and then call
         the internal program watermarks function.
      
      v5:
       - Skip intermediate watermark calculation/check during initial hardware
         readout since we don't trust the existing HW values (and don't have
         valid values of our own yet).
       - Don't try to call .optimize_watermarks() on platforms that don't have
         atomic watermarks yet.  (Maarten)
      
      v6:
       - Rebase
      
      v7:
       - Further rebase
      
      v8:
       - A few minor indentation and line length fixes
      
      v9:
       - Yet another rebase since Maarten's patches reworked a bunch of the
         code (wm_pre, wm_post, etc.) that this was previously based on.
      
      v10:
       - Move wm_mutex to dev_priv to protect against racing commits against
         disjoint CRTC sets. (Maarten)
       - Drop unnecessary clearing of cstate->wm.need_postvbl_update (Maarten)
      
      v11:
       - Now that we've moved to atomic watermark updates, make sure we call
         the proper function to program watermarks in
         {ironlake,haswell}_crtc_enable(); the failure to do so on the
         previous patch iteration led to us not actually programming the
         watermarks before turning on the CRTC, which was the cause of the
         underruns that the CI system was seeing.
       - Fix inverted logic for determining when to optimize watermarks.  We
         were needlessly optimizing when the intermediate/optimal values were
         the same (harmless), but not actually optimizing when they differed
         (also harmless, but wasteful from a power/bandwidth perspective).
      
      Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Signed-off-by: NMatt Roper <matthew.d.roper@intel.com>
      Reviewed-by: NMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Link: http://patchwork.freedesktop.org/patch/msgid/1456276813-5689-1-git-send-email-matthew.d.roper@intel.com
      ed4a6a7c
  16. 22 2月, 2016 1 次提交
  17. 18 2月, 2016 1 次提交
  18. 16 2月, 2016 2 次提交
  19. 09 2月, 2016 1 次提交
  20. 06 2月, 2016 1 次提交
    • S
      drm/i915/bxt: Check BIOS RC6 setup before enabling RC6 · 274008e8
      Sagar Arun Kamble 提交于
      RC6 setup is shared between BIOS and Driver. BIOS sets up subset of RC6
      setup registers. If those are not setup Driver should not enable RC6.
      For implementing this, driver can check RC_CTRL0 and RC_CTRL1 values
      to know if BIOS has enabled HW/SW RC6.
      This will also enable user to control RC6 using BIOS settings alone.
      RC6 related instability can be avoided by disabling via BIOS settings
      till driver fixes it.
      
      v2: Had placed logic in gen8 function by mistake. Fixed it.
      Ensuring RPM is not enabled in case BIOS disabled RC6.
      
      v3: Need to disable RPM if RC6 is disabled due to BIOS settings. (Daniel)
      Runtime PM enabling happens before gen9_enable_rc6.
      Moved the updation of enable_rc6 parameter in intel_uncore_sanitize.
      
      v4: Added elaborate check for BIOS RC6 setup. Prepared check_pctx for bxt.
          (Imre)
      
      v5: Caching reserved stolen base and size in the driver private data.
          Reorganized RC6 setup check. Moved from gen9_enable_rc6 to
          intel_uncore_sanitize. (Imre)
      
      v6: Rebasing on the patch submitted by Imre that moves gem_init_stolen
          earlier in the load.
      
      v7: Removed PWRCTX_MAXCNT_VCSUNIT1 check as it applies to SKL. (Imre)
      
      v8: Fixed formatting and checkpatch issues. Fixed functional issue where
          RC6 ctx size check was missing. (Imre)
      
      Cc: Imre Deak <imre.deak@intel.com>
      Signed-off-by: NSagar Arun Kamble <sagar.a.kamble@intel.com>
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Link: http://patchwork.freedesktop.org/patch/msgid/1454697809-22113-1-git-send-email-sagar.a.kamble@intel.com
      274008e8
  21. 03 2月, 2016 2 次提交
  22. 29 1月, 2016 1 次提交
  23. 20 1月, 2016 3 次提交
  24. 15 1月, 2016 2 次提交
  25. 14 1月, 2016 1 次提交
  26. 07 1月, 2016 1 次提交
    • M
      drm/i915: Add two-stage ILK-style watermark programming (v10) · 396e33ae
      Matt Roper 提交于
      In addition to calculating final watermarks, let's also pre-calculate a
      set of intermediate watermark values at atomic check time.  These
      intermediate watermarks are a combination of the watermarks for the old
      state and the new state; they should satisfy the requirements of both
      states which means they can be programmed immediately when we commit the
      atomic state (without waiting for a vblank).  Once the vblank does
      happen, we can then re-program watermarks to the more optimal final
      value.
      
      v2: Significant rebasing/rewriting.
      
      v3:
       - Move 'need_postvbl_update' flag to CRTC state (Daniel)
       - Don't forget to check intermediate watermark values for validity
         (Maarten)
       - Don't due async watermark optimization; just do it at the end of the
         atomic transaction, after waiting for vblanks.  We do want it to be
         async eventually, but adding that now will cause more trouble for
         Maarten's in-progress work.  (Maarten)
       - Don't allocate space in crtc_state for intermediate watermarks on
         platforms that don't need it (gen9+).
       - Move WaCxSRDisabledForSpriteScaling:ivb into intel_begin_crtc_commit
         now that ilk_update_wm is gone.
      
      v4:
       - Add a wm_mutex to cover updates to intel_crtc->active and the
         need_postvbl_update flag.  Since we don't have async yet it isn't
         terribly important yet, but might as well add it now.
       - Change interface to program watermarks.  Platforms will now expose
         .initial_watermarks() and .optimize_watermarks() functions to do
         watermark programming.  These should lock wm_mutex, copy the
         appropriate state values into intel_crtc->active, and then call
         the internal program watermarks function.
      
      v5:
       - Skip intermediate watermark calculation/check during initial hardware
         readout since we don't trust the existing HW values (and don't have
         valid values of our own yet).
       - Don't try to call .optimize_watermarks() on platforms that don't have
         atomic watermarks yet.  (Maarten)
      
      v6:
       - Rebase
      
      v7:
       - Further rebase
      
      v8:
       - A few minor indentation and line length fixes
      
      v9:
       - Yet another rebase since Maarten's patches reworked a bunch of the
         code (wm_pre, wm_post, etc.) that this was previously based on.
      
      v10:
       - Move wm_mutex to dev_priv to protect against racing commits against
         disjoint CRTC sets. (Maarten)
       - Drop unnecessary clearing of cstate->wm.need_postvbl_update (Maarten)
      
      Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Signed-off-by: NMatt Roper <matthew.d.roper@intel.com>
      Link: http://patchwork.freedesktop.org/patch/msgid/1452108870-24204-1-git-send-email-matthew.d.roper@intel.comSigned-off-by: NMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      396e33ae