1. Feb 01, 2021
  2. Jan 26, 2021
  3. Jan 21, 2021
  4. Jan 15, 2021
    • Dave Airlie's avatar
      Merge tag 'drm-intel-gt-next-2021-01-14' of... · fb5cfcaa
      Dave Airlie authored
      Merge tag 'drm-intel-gt-next-2021-01-14' of git://anongit.freedesktop.org/drm/drm-intel
      
       into drm-next
      
      UAPI Changes:
      - Deprecate I915_PMU_LAST and optimize state tracking (Tvrtko)
      
        Avoid relying on last item ABI marker in i915_drm.h, add a
        comment to mark as deprecated.
      
      Cross-subsystem Changes:
      
      Core Changes:
      
      Driver Changes:
      
      - Restore clear residuals security mitigations for Ivybridge and
        Baytrail (Chris)
      - Close #1858: Allow sysadmin to choose applied GPU security mitigations
        through i915.mitigations=... similar to CPU (Chris)
      - Fix for #2024: GPU hangs on HSW GT1 (Chris)
      - Fix for #2707: Driver hang when editing UVs in Blender (Chris, Ville)
      - Fix for #2797: False positive GuC loading error message (Chris)
      - Fix for #2859: Missing GuC firmware for older Cometlakes (Chris)
      - Lessen probability of GPU hang due to DMAR faults [reason 7,
        next page table ptr is invalid] on Tigerlake (Chris)
      - Fix REVID macros for TGL to fetch correct stepping (Aditya)
      - Limit frequency drop to RPe on parking (Chris, Edward)
      - Limit W/A 1406941453 to TGL, RKL and DG1 (Swathi)
      - Make W/A 22010271021 permanent on DG1 (Lucas)
      - Implement W/A 16011163337 to prevent a HS/DS hang on DG1 (Swathi)
      - Only disable preemption on gen8 render engines (Chris)
      - Disable arbitration around Braswell's PDP updates (Chris)
      - Disable arbitration on no-preempt requests (Chris)
      - Check for arbitration after writing start seqno before busywaiting (Chris)
      - Retain default context state across shrinking (Venkata, CQ)
      - Fix mismatch between misplaced vma check and vma insert for 32-bit
        addressing userspaces (Chris, CQ)
      - Propagate error for vmap() failure instead kernel NULL deref (Chris)
      - Propagate error from cancelled submit due to context closure
        immediately (Chris)
      - Fix RCU race on HWSP tracking per request (Chris)
      - Clear CMD parser shadow and GPU reloc batches (Matt A)
      
      - Populate logical context during first pin (Maarten)
      - Optimistically prune dma-resv from the shrinker (Chris)
      - Fix for virtual engine ownership race (Chris)
      - Remove timeslice suppression to restore fairness for virtual engines (Chris)
      - Rearrange IVB/HSW workarounds properly between GT and engine (Chris)
      - Taint the reset mutex with the shrinker (Chris)
      - Replace direct submit with direct call to tasklet (Chris)
      - Multiple corrections to virtual engine dequeue and breadcrumbs code (Chris)
      - Avoid wakeref from potentially hard IRQ context in PMU (Tvrtko)
      - Use raw clock for RC6 time estimation in PMU (Tvrtko)
      - Differentiate OOM failures from invalid map types (Chris)
      - Fix Gen9 to have 64 MOCS entries similar to Gen11 (Chris)
      - Ignore repeated attempts to suspend request flow across reset (Chris)
      - Remove livelock from "do_idle_maps" VT-d W/A (Chris)
      - Cancel the preemption timeout early in case engine reset fails (Chris)
      - Code flow optimization in the scheduling code (Chris)
      - Clear the execlists timers upon reset (Chris)
      - Drain the breadcrumbs just once (Chris, Matt A)
      - Track the overall GT awake/busy time (Chris)
      - Tweak submission tasklet flushing to avoid starvation (Chris)
      - Track timelines created using the HWSP to restore on resume (Chris)
      - Use cmpxchg64 for 32b compatilibity for active tracking (Chris)
      - Prefer recycling an idle GGTT fence to avoid GPU wait (Chris)
      
      - Restructure GT code organization for clearer split between GuC
        and execlists (Chris, Daniele, John, Matt A)
      - Remove GuC code that will remain unused by new interfaces (Matt B)
      - Restructure the CS timestamp clocks code to local to GT (Chris)
      - Fix error return paths in perf code (Zhang)
      - Replace idr_init() by idr_init_base() in perf (Deepak)
      - Fix shmem_pin_map error path (Colin)
      - Drop redundant free_work worker for GEM contexts (Chris, Mika)
      - Increase readability and understandability of intel_workarounds.c (Lucas)
      - Defer enabling the breadcrumb interrupt to after submission (Chris)
      - Deal with buddy alloc block sizes beyond 4G (Venkata, Chris)
      - Encode fence specific waitqueue behaviour into the wait.flags (Chris)
      - Don't cancel the breadcrumb interrupt shadow too early (Chris)
      - Cancel submitted requests upon context reset (Chris)
      - Use correct locks in GuC code (Tvrtko)
      - Prevent use of engine->wa_ctx after error (Chris, Matt R)
      
      - Fix build warning on 32-bit (Arnd)
      - Avoid memory leak if platform would have more than 16 W/A (Tvrtko)
      - Avoid unnecessary #if CONFIG_PM in PMU code (Chris, Tvrtko)
      - Improve debugging output (Chris, Tvrtko, Matt R)
      - Make file local variables static (Jani)
      - Avoid uint*_t types in i915 (Jani)
      - Selftest improvements (Chris, Matt A, Dan)
      - Documentation fixes (Chris, Jose)
      
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      # Conflicts:
      #	drivers/gpu/drm/i915/gt/intel_breadcrumbs.c
      #	drivers/gpu/drm/i915/gt/intel_breadcrumbs_types.h
      #	drivers/gpu/drm/i915/gt/intel_lrc.c
      #	drivers/gpu/drm/i915/gvt/mmio_context.h
      #	drivers/gpu/drm/i915/i915_drv.h
      From: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210114152232.GA21588@jlahtine-mobl.ger.corp.intel.com
      fb5cfcaa
    • Dave Airlie's avatar
      Merge tag 'drm-intel-next-2021-01-12' of git://anongit.freedesktop.org/drm/drm-intel into drm-next · dfa7c521
      Dave Airlie authored
      
      
      - PSR fixes and improvements for selective fetch (Jose)
      - GVT build fixed and cleanup (Jani)
      - RKL display fixes (Lee, Matt)
      - DSI fix (Hans)
      - Panel Power and Backlight fixes (Anshuman, Jani)
      - RPM fix (Chris)
      - Fix HTI port checking (Jose)
      - Clean-up in cursor code (Ville)
      - Once again, trying to use fast+narrow link on eDP (Ville)
      - DG1 display fix (Matt)
      
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      From: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210112175151.GA90999@intel.com
      dfa7c521
    • Dave Airlie's avatar
      Merge tag 'amd-drm-next-5.12-2021-01-08' of... · 2ce542e5
      Dave Airlie authored
      Merge tag 'amd-drm-next-5.12-2021-01-08' of https://gitlab.freedesktop.org/agd5f/linux into drm-next
      
      amd-drm-next-5.12-2021-01-08:
      
      amdgpu:
      - Rework IH ring handling on vega and navi
      - Rework HDP handling for vega and navi
      - swSMU documenation updates
      - Overdrive support for Sienna Cichlid and newer asics
      - swSMU updates for vangogh
      - swSMU updates for renoir
      - Enable FP16 on DCE8-11
      - Misc code cleanups and bug fixes
      
      radeon:
      - Fixes for platforms that can't access PCI resources correctly
      - Misc code cleanups
      
      From: Alex Deucher <alexdeucher@gmail.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210108221811.3868-1-alexander.deucher@amd.com
      
      
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      2ce542e5
  5. Jan 14, 2021
  6. Jan 13, 2021
  7. Jan 12, 2021
    • Chris Wilson's avatar
      drm/i915/gt: Perform an arbitration check before busywaiting · 49b20dbf
      Chris Wilson authored
      
      
      During igt_reset_nop_engine, it was observed that an unexpected failed
      engine reset lead to us busywaiting on the stop-ring semaphore (set
      during the reset preparations) on the first request afterwards. There was
      no explicit MI_ARB_CHECK in this sequence as the presumption was that
      the failed MI_SEMAPHORE_WAIT would itself act as an arbitration point.
      It did not in this circumstance, so force it.
      
      This patch is based on the assumption that the MI_SEMAPHORE_WAIT failure
      to arbitrate is a rare Tigerlake bug, similar to the lite-restore vs
      semaphore issues previously seen in the CS. The explicit MI_ARB_CHECK
      should always ensure that there is at least one arbitration point in the
      request before the MI_SEMAPHORE_WAIT to trigger the IDLE->ACTIVE event.
      Upon processing that event, we will clear the stop-ring flag and release
      the semaphore from its busywait.
      
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210112100759.32698-2-chris@chris-wilson.co.uk
      49b20dbf
    • Chris Wilson's avatar
      drm/i915/gt: Check for arbitration after writing start seqno · 1a51b50c
      Chris Wilson authored
      
      
      On the off chance that we need to arbitrate before launching the
      payload, perform the check after we signal the request is ready to
      start. Assuming instantaneous processing of the CS event, the request
      will then be treated as having started when we make the decisions as to
      how to process that CS event.
      
      v2: More commentary about the users of i915_request_started() as a
      reminder about why we are marking the initial breadcrumb.
      
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: default avatarTvrtko Ursulin <tvrtko.ursulin@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210112100759.32698-1-chris@chris-wilson.co.uk
      1a51b50c
    • Chris Wilson's avatar
      drm/i915/selftests: Allow huge_gem_object to kick the shrinker · 8c1f2127
      Chris Wilson authored
      
      
      A new fi-cml-dallium CI machine has 8G and apparently plenty free, yet
      fails some selftests with ENOMEM. The failures all seem to be from
      huge_gem_object which does not try very hard to allocate memory,
      skipping reclaim entirely. Let's try a bit harder and direct reclaim
      before failing.
      
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: default avatarMatthew Auld <matthew.auld@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210112020013.19464-1-chris@chris-wilson.co.uk
      8c1f2127
    • Chris Wilson's avatar
      drm/i915/gem: Remove stolen node before releasing the region · f7073fb9
      Chris Wilson authored
      If this stolen object holds the last reference to the region, we need to
      remove our drm_mm_node before freeing the region's drm_mm.
      
      <4> [431.679591] Memory manager not clean during takedown.
      <4> [431.679633] WARNING: CPU: 0 PID: 110 at drivers/gpu/drm/drm_mm.c:999 drm_mm_takedown+0x51/0x100
      <4> [431.679655] Modules linked in: i915 vgem btusb snd_hda_codec_hdmi btrtl btbcm btintel snd_hda_codec_realtek snd_hda_codec_generic ledtrig_audio bluetooth coretemp crct10dif_pclmul crc32_pclmul ghash_clmulni_intel ecdh_generic ecc r8169 realtek lpc_ich snd_intel_dspcfg snd_hda_codec snd_hwdep snd_hda_core snd_pcm pinctrl_cherryview prime_numbers [last unloaded: i915]
      <4> [431.679883] CPU: 0 PID: 110 Comm: kworker/u4:3 Tainted: G     U            5.11.0-rc3-CI-CI_DRM_9583+ #1
      <4> [431.679895] Hardware name:  /NUC5CPYB, BIOS PYBSWCEL.86A.0058.2016.1102.1842 11/02/2016
      <4> [431.679905] Workqueue: i915 __i915_gem_free_work [i915]
      <4> [431.680831] RIP: 0010:drm_mm_takedown+0x51/0x100
      <4> [431.680850] Code: 44 24 08 65 48 33 04 25 28 00 00 00 0f 85 b6 00 00 00 48 83 c4 10 5b 5d 41 5c c3 48 89 fb 48 c7 c7 c8 b7 38 82 e8 00 d6 37 00 <0f> 0b 48 8b 3d 96 d5 d1 00 ba 00 10 00 00 be c0 0c 00 00 e8 d7 64
      <4> [431.680862] RSP: 0018:ffffc90000ad7dc0 EFLAGS: 00010282
      <4> [431.680879] RAX: 0000000000000000 RBX: ffff8881109aa140 RCX: 0000000000000001
      <4> [431.680888] RDX: 0000000080000001 RSI: ffffffff8235a70f RDI: 00000000ffffffff
      <4> [431.680897] RBP: ffff8881109aa178 R08: 0000000000000001 R09: 0000000000000001
      <4> [431.680906] R10: 0000000025eaec48 R11: 00000000f5b271a7 R12: ffff88810a38ddc0
      <4> [431.680916] R13: 00000000ffffffff R14: ffffffff82861b70 R15: ffff88810b715538
      <4> [431.680925] FS:  0000000000000000(0000) GS:ffff88817b800000(0000) knlGS:0000000000000000
      <4> [431.680935] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      <4> [431.680945] CR2: 000056377cfd7c48 CR3: 00000001045de000 CR4: 00000000001006f0
      <4> [431.680954] Call Trace:
      <4> [431.680977]  __intel_memory_region_destroy+0x24/0x50 [i915]
      <4> [431.681340]  i915_gem_object_release_stolen+0x26/0x40 [i915]
      <4> [431.681637]  __i915_gem_free_objects.isra.21+0x1ef/0x3b0 [i915]
      <4> [431.681935]  process_one_work+0x270/0x5c0
      <4> [431.682022]  worker_thread+0x37/0x380
      <4> [431.682047]  ? process_one_work+0x5c0/0x5c0
      <4> [431.682062]  kthread+0x146/0x170
      <4> [431.682077]  ? kthread_park+0x80/0x80
      <4> [431.682098]  ret_from_fork+0x22/0x30
      <4> [431.682153] irq event stamp: 1872905
      <4> [431.682162] hardirqs last  enabled at (1872911): [<ffffffff8112bd9a>] console_unlock+0x49a/0x580
      <4> [431.682176] hardirqs last disabled at (1872916): [<ffffffff8112bd06>] console_unlock+0x406/0x580
      <4> [431.682187] softirqs last  enabled at (1872850): [<ffffffff81e00342>] __do_softirq+0x342/0x48e
      <4> [431.682201] softirqs last disabled at (1872845): [<ffffffff81c00f52>] asm_call_irq_on_stack+0x12/0x20
      <4> [431.682214] ---[ end trace 5d3bcd818e2e3816 ]---
      <3> [431.686188] [drm:drm_mm_takedown] *ERROR* node [0002d000 + 00004000]: inserted at
       drm_mm_insert_node_in_range+0x34a/0x5b0
       i915_gem_stolen_insert_node_in_range+0x7b/0xa0 [i915]
       _i915_gem_object_create_stolen+0x83/0xd0 [i915]
       i915_gem_object_create_region+0x61/0x140 [i915]
       intel_engine_create_ring+0x176/0x230 [i915]
      
      Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/2927
      
      
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: default avatarMatthew Auld <matthew.auld@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210112015000.16108-1-chris@chris-wilson.co.uk
      f7073fb9
    • Chris Wilson's avatar
      drm/i915: Allow the sysadmin to override security mitigations · f7452c7c
      Chris Wilson authored
      The clear-residuals mitigation is a relatively heavy hammer and under some
      circumstances the user may wish to forgo the context isolation in order
      to meet some performance requirement. Introduce a generic module
      parameter to allow selectively enabling/disabling different mitigations.
      
      To disable just the clear-residuals mitigation (on Ivybridge, Baytrail,
      or Haswell) use the module parameter: i915.mitigations=auto,!residuals
      
      Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/1858
      Fixes: 47f8253d
      
       ("drm/i915/gen7: Clear all EU/L3 residual contexts")
      Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
      Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Cc: Jon Bloomfield <jon.bloomfield@intel.com>
      Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
      Cc: stable@vger.kernel.org # v5.7
      Reviewed-by: default avatarJon Bloomfield <jon.bloomfield@intel.com>
      Reviewed-by: default avatarRodrigo Vivi <rodrigo.vivi@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20210111225220.3483-3-chris@chris-wilson.co.uk
      f7452c7c