1. 05 6月, 2018 2 次提交
  2. 04 6月, 2018 1 次提交
  3. 01 6月, 2018 1 次提交
  4. 31 5月, 2018 1 次提交
  5. 24 5月, 2018 3 次提交
    • D
      drm/i915/psr: Nuke PSR support for VLV and CHV · ce3508fd
      Dhinakaran Pandiyan 提交于
      PSR hardware and hence the driver code for VLV and CHV deviates a lot from
      their DDI counterparts. While the feature has been disabled for a long time
      now, retaining support for these platforms is a maintenance burden. There
      have been multiple refactoring commits to just keep the existing code for
      these platforms in line with the rest. There are known issues that need to
      be fixed to enable PSR on these platforms, and there is no PSR capable
      platform in CI to ensure the code does not break again if we get around to
      fixing the existing issues. On account of all these reasons, let's nuke
      this code for now and bring it back if a need arises in the future.
      
      Cc: Jani Nikula <jani.nikula@intel.com>
      Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Acked-by: NJani Nikula <jani.nikula@intel.com>
      Acked-by: NRodrigo Vivi <rodrigo.vivi@intel.com>
      Reviewed-by: NJosé Roberto de Souza <jose.souza@intel.com>
      Signed-off-by: NDhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180511230059.19387-1-dhinakaran.pandiyan@intel.com
      ce3508fd
    • V
      drm/i915/psr: vbt change for psr · 77312ae8
      Vathsala Nagaraju 提交于
      For psr block #9, the vbt description has moved to options [0-3] for
      TP1,TP2,TP3 Wakeup time from decimal value without any change to vbt
      structure. Since spec does not  mention from which VBT version this
      change was added to vbt.bsf file, we cannot depend on bdb->version check
      to change for all the platforms.
      
      There is RCR inplace for GOP team to  provide the version number
      to make generic change. Since Kabylake with bdb version 209 is having this
      change, limiting this change to gen9_bc and version 209+ to unblock google.
      
      Tested on skl(bdb version 203,without options) and
      kabylake(bdb version 209,212) having new options.
      
      bspec 20131
      
      v2: (Jani and Rodrigo)
          move the 165 version check to intel_bios.c
      v3: Jani
          Move the abstraction to intel_bios.
      v4: Jani
          Rename tp*_wakeup_time to have "us" suffix.
          For values outside range[0-3],default to max 2500us.
          Old decimal value was wake up time in multiples of 100us.
      v5: Jani and Rodrigo
          Handle option 2 in default condition.
          Print oustide range value.
          For negetive values default to 2500us.
      v6: Jani
          Handle default first and then fall through for case 2.
      v7: Rodrigo
          Apply this change for IS_GEN9_BC and vbt version > 209
      v8: Puthik
          Add new function vbt_psr_to_us.
      v9: Jani
          Change to v7 version as it's more readable.
          DK
          add comment /*fall through*/ after case2.
      
      Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Cc: Puthikorn Voravootivat <puthik@chromium.org>
      Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
      Cc: Jani Nikula <jani.nikula@intel.com>
      Cc: José Roberto de Souza <jose.souza@intel.com>
      Signed-off-by: NMaulik V Vaghela <maulik.v.vaghela@intel.com>
      Signed-off-by: NVathsala Nagaraju <vathsala.nagaraju@intel.com>
      Reviewed-by: NJani Nikula <jani.nikula@intel.com>
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/1526981243-2745-1-git-send-email-vathsala.nagaraju@intel.com
      77312ae8
    • Y
      drm/i915/cnl: Implement WaProgramMgsrForCorrectSliceSpecificMmioReads · 1e40d4ae
      Yunwei Zhang 提交于
      WaProgramMgsrForCorrectSliceSpecificMmioReads dictate that before any MMIO
      read into Slice/Subslice specific registers, MCR packet control
      register(0xFDC) needs to be programmed to point to any enabled
      slice/subslice pair. Otherwise, incorrect value will be returned.
      
      However, that means each subsequent MMIO read will be forwarded to a
      specific slice/subslice combination as read is unicast. This is OK since
      slice/subslice specific register values are consistent in almost all cases
      across slice/subslice. There are rare occasions such as INSTDONE that this
      value will be dependent on slice/subslice combo, in such cases, we need to
      program 0xFDC and recover this after. This is already covered by
      read_subslice_reg.
      
      Also, 0xFDC will lose its information after TDR/engine reset/power state
      change.
      
      References: HSD#1405586840, BSID#0575
      
      v2:
       - use fls() instead of find_last_bit() (Chris)
       - added INTEL_SSEU to extract sseu from device info. (Chris)
      v3:
       - rebase on latest tip
      v5:
       - Added references (Mika)
       - Change the ordered of passing arguments and etc. (Ursulin)
      v7:
       - Moved WA explanation Comments(Oscar)
       - Rebased.
      v8:
       - Renamed sanitize_mcr to calculate_s_ss_select. (Oscar)
       - calculate s/ss selector instead of whole mcr. (Oscar)
      v9:
       - Updated function name (Oscar)
       - Remove redundant variables (Oscar)
      v10:
       - Separate pre-GEN10 and GEN11 mask. (Oscar)
      
      Cc: Oscar Mateo <oscar.mateo@intel.com>
      Cc: Michel Thierry <michel.thierry@intel.com>
      Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Cc: Chris Wilson <chris@chris-wilson.co.uk>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
      Signed-off-by: NYunwei Zhang <yunwei.zhang@intel.com>
      Reviewed-by: NOscar Mateo <oscar.mateo@intel.com>
      Signed-off-by: NMika Kuoppala <mika.kuoppala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/1526683197-24656-1-git-send-email-yunwei.zhang@intel.com
      1e40d4ae
  6. 22 5月, 2018 2 次提交
  7. 18 5月, 2018 1 次提交
  8. 14 5月, 2018 1 次提交
  9. 11 5月, 2018 1 次提交
    • O
      drm/i915/icl: Introduce initial Icelake Workarounds · cc38cae7
      Oscar Mateo 提交于
      Inherit workarounds from previous platforms that are still valid for
      Icelake.
      
      v2: GEN7_ROW_CHICKEN2 is masked
      v3:
        - Since it has been fixed already in upstream, removed the TODO
          comment about WA_SET_BIT for WaInPlaceDecompressionHang.
        - Squashed with this patch:
            drm/i915/icl: add icelake_init_clock_gating()
          from Paulo Zanoni <paulo.r.zanoni@intel.com>
        - Squashed with this patch:
            drm/i915/icl: WaForceEnableNonCoherent
          from Oscar Mateo <oscar.mateo@intel.com>
        - WaPushConstantDereferenceHoldDisable is now Wa_1604370585 and
          applies to B0 as well.
        - WaPipeControlBefore3DStateSamplePattern WABB was being applied
          to ICL incorrectly.
      v4:
        - Wrap the commit message
        - s/dev_priv/p to please checkpatch
      v5: Rebased on top of the WA refactoring
      v6: Rebased on top of further whitelist registers refactoring (Michel)
      v7: Added WaRsForcewakeAddDelayForAck
      v8: s/ICL_HDC_CHICKEN0/ICL_HDC_MODE (Mika)
      v9:
        - C, not lisp (Chris)
        - WaIncreaseDefaultTLBEntries is the same for GEN > 9_LP (Tvrtko)
      Signed-off-by: NOscar Mateo <oscar.mateo@intel.com>
      Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Cc: Tomasz Lis <tomasz.lis@intel.com>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NMika Kuoppala <mika.kuoppala@linux.intel.com>
      Signed-off-by: NMika Kuoppala <mika.kuoppala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/1525814984-20039-2-git-send-email-oscar.mateo@intel.com
      cc38cae7
  10. 09 5月, 2018 1 次提交
  11. 04 5月, 2018 1 次提交
    • C
      drm/i915: Lazily unbind vma on close · 3365e226
      Chris Wilson 提交于
      When userspace is passing around swapbuffers using DRI, we frequently
      have to open and close the same object in the foreign address space.
      This shows itself as the same object being rebound at roughly 30fps
      (with a second object also being rebound at 30fps), which involves us
      having to rewrite the page tables and maintain the drm_mm range manager
      every time.
      
      However, since the object still exists and it is only the local handle
      that disappears, if we are lazy and do not unbind the VMA immediately
      when the local user closes the object but defer it until the GPU is
      idle, then we can reuse the same VMA binding. We still have to be
      careful to mark the handle and lookup tables as closed to maintain the
      uABI, just allowing the underlying VMA to be resurrected if the user is
      able to access the same object from the same context again.
      
      If the object itself is destroyed (neither userspace keeping a handle to
      it), the VMA will be reaped immediately as usual.
      
      In the future, this will be even more useful as instantiating a new VMA
      for use on the GPU will become heavier. A nuisance indeed, so nip it in
      the bud.
      
      v2: s/__i915_vma_final_close/i915_vma_destroy/ etc.
      v3: Leave a hint as to why we deferred the unbind on close.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180503195115.22309-1-chris@chris-wilson.co.uk
      3365e226
  12. 03 5月, 2018 2 次提交
    • C
      drm/i915: Split i915_gem_timeline into individual timelines · a89d1f92
      Chris Wilson 提交于
      We need to move to a more flexible timeline that doesn't assume one
      fence context per engine, and so allow for a single timeline to be used
      across a combination of engines. This means that preallocating a fence
      context per engine is now a hindrance, and so we want to introduce the
      singular timeline. From the code perspective, this has the notable
      advantage of clearing up a lot of mirky semantics and some clumsy
      pointer chasing.
      
      By splitting the timeline up into a single entity rather than an array
      of per-engine timelines, we can realise the goal of the previous patch
      of tracking the timeline alongside the ring.
      
      v2: Tweak wait_for_idle to stop the compiling thinking that ret may be
      uninitialised.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180502163839.3248-2-chris@chris-wilson.co.uk
      a89d1f92
    • C
      drm/i915: Move timeline from GTT to ring · 65fcb806
      Chris Wilson 提交于
      In the future, we want to move a request between engines. To achieve
      this, we first realise that we have two timelines in effect here. The
      first runs through the GTT is required for ordering vma access, which is
      tracked currently by engine. The second is implied by sequential
      execution of commands inside the ringbuffer. This timeline is one that
      maps to userspace's expectations when submitting requests (i.e. given the
      same context, batch A is executed before batch B). As the rings's
      timelines map to userspace and the GTT timeline an implementation
      detail, move the timeline from the GTT into the ring itself (per-context
      in logical-ring-contexts/execlists, or a global per-engine timeline for
      the shared ringbuffers in legacy submission.
      
      The two timelines are still assumed to be equivalent at the moment (no
      migrating requests between engines yet) and so we can simply move from
      one to the other without adding extra ordering.
      
      v2: Reinforce that one isn't allowed to mix the engine execution
      timeline with the client timeline from userspace (on the ring).
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
      Reviewed-by: NTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180502163839.3248-1-chris@chris-wilson.co.uk
      65fcb806
  13. 30 4月, 2018 3 次提交
  14. 28 4月, 2018 1 次提交
  15. 21 4月, 2018 2 次提交
  16. 19 4月, 2018 1 次提交
  17. 15 4月, 2018 1 次提交
    • C
      drm/i915: Check whitelist registers across resets · f4ecfbfc
      Chris Wilson 提交于
      Add a selftest to ensure that we restore the whitelisted registers after
      rewrite the registers everytime they might be scrubbed, e.g. module
      load, reset and resume. For the other volatile workaround registers, we
      export their presence via debugfs and check in igt/gem_workarounds.
      However, we don't export the whitelist and rather than do so, let's test
      them directly in the kernel.
      
      The test we use is to read the registers back from the CS (this helps us
      be sure that the registers will be valid for MI_LRI etc). In order to
      generate the expected list, we split intel_whitelist_workarounds_emit
      into two phases, the first to build the list and the second to apply.
      Inside the test, we only build the list and then check that list against
      the hw.
      
      v2: Filter out pre-gen8 as they do not have RING_NONPRIV.
      v3: Drop unused engine parameter, no plans to use it now or future.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Oscar Mateo <oscar.mateo@intel.com>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Reviewed-by: NOscar Mateo <oscar.mateo@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180414122754.569-1-chris@chris-wilson.co.uk
      f4ecfbfc
  18. 13 4月, 2018 1 次提交
  19. 09 4月, 2018 4 次提交
  20. 07 4月, 2018 2 次提交
    • C
      drm/i915: Pass the set of guilty engines to i915_reset() · d0667e9c
      Chris Wilson 提交于
      Currently, we rely on inspecting the hangcheck state from within the
      i915_reset() routines to determine which engines were guilty of the
      hang. This is problematic for cases where we want to run
      i915_handle_error() and call i915_reset() independently of hangcheck.
      Instead of relying on the indirect parameter passing, turn it into an
      explicit parameter providing the set of stalled engines which then are
      treated as guilty until proven innocent.
      
      While we are removing the implicit stalled parameter, also make the
      reason into an explicit parameter to i915_reset(). We still need a
      back-channel for i915_handle_error() to hand over the task to the locked
      waiter, but let's keep that its own channel rather than incriminate
      another.
      
      This leaves stalled/seqno as being private to hangcheck, with no more
      nefarious snooping by reset, be it whole-device or per-engine. \o/
      
      The only real issue now is that this makes it crystal clear that we
      don't actually do any testing of hangcheck per se in
      drv_selftest/live_hangcheck, merely of resets!
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Michel Thierry <michel.thierry@intel.com>
      Cc: Jeff McGee <jeff.mcgee@intel.com>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Reviewed-by: NMichel Thierry <michel.thierry@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180406220354.18911-2-chris@chris-wilson.co.uk
      d0667e9c
    • C
      drm/i915: Treat i915_reset_engine() as guilty until proven innocent · bba0869b
      Chris Wilson 提交于
      If we are resetting just one engine, we know it has stalled. So we can
      pass the stalled parameter directly to i915_gem_reset_engine(), which
      alleviates the necessity to poke at the generic engine->hangcheck.stalled
      magic variable, leaving that under control of hangcheck as its name
      implies. Other than simplifying by removing the indirect parameter along
      this path, this allows us to introduce new reset mechanisms that run
      independently of hangcheck.
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Michel Thierry <michel.thierry@intel.com>
      Cc: Jeff McGee <jeff.mcgee@intel.com>
      Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
      Reviewed-by: NMichel Thierry <michel.thierry@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180406220354.18911-1-chris@chris-wilson.co.uk
      bba0869b
  21. 31 3月, 2018 4 次提交
  22. 27 3月, 2018 1 次提交
    • I
      drm/i915: Fix hibernation with ACPI S0 target state · 300efa9e
      Imre Deak 提交于
      After
      
      commit dd9f31c7
      Author: Imre Deak <imre.deak@intel.com>
      Date:   Wed Aug 16 17:46:07 2017 +0300
      
          drm/i915/gen9+: Set same power state before hibernation image
          save/restore
      
      during hibernation/suspend the power domain functionality got disabled,
      after which resume could leave it incorrectly disabled if the ACPI
      target state was S0 during suspend and i915 was not loaded by the loader
      kernel.
      
      This was caused by not considering if we resumed from hibernation as the
      condition for power domains reiniting.
      
      Fix this by simply tracking if we suspended power domains during system
      suspend and reinit power domains accordingly during resume. This will
      result in reiniting power domains always when resuming from hibernation,
      regardless of the platform and whether or not i915 is loaded by the
      loader kernel.
      
      The reason we didn't catch this earlier is that the enabled/disabled
      state of power domains during PMSG_FREEZE/PMSG_QUIESCE is platform
      and kernel config dependent: on my SKL the target state is S4
      during PMSG_FREEZE and (with the driver loaded in the loader kernel)
      S0 during PMSG_QUIESCE. On the reporter's machine it's S0 during
      PMSG_FREEZE but (contrary to this) power domains are not initialized
      during PMSG_QUIESCE since i915 is not loaded in the loader kernel, or
      it's loaded but without the DMC firmware being available.
      
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105196
      Reported-and-tested-by: amn-bas@hotmail.com
      Fixes: dd9f31c7 ("drm/i915/gen9+: Set same power state before hibernation image save/restore")
      Cc: amn-bas@hotmail.com
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Cc: <stable@vger.kernel.org>
      Signed-off-by: NImre Deak <imre.deak@intel.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180322143642.26883-1-imre.deak@intel.com
      (cherry picked from commit 0f90603c)
      Signed-off-by: NJoonas Lahtinen <joonas.lahtinen@linux.intel.com>
      300efa9e
  23. 24 3月, 2018 3 次提交