1. 09 May, 2024 1 commit
    • Shuicheng Lin's avatar
      drm/xe: Fix UBSAN shift-out-of-bounds failure · 205e5c4b
      Shuicheng Lin authored
      Here is the failure stack:
      [   12.988209] ------------[ cut here ]------------
      [   12.988216] UBSAN: shift-out-of-bounds in ./include/linux/log2.h:57:13
      [   12.988232] shift exponent 64 is too large for 64-bit type 'long unsigned int'
      [   12.988235] CPU: 4 PID: 1310 Comm: gnome-shell Tainted: G     U             6.9.0-rc6+prerelease1158+ #19
      [   12.988237] Hardware name: Intel Corporation Raptor Lake Client Platform/RPL-S ADP-S DDR5 UDIMM CRB, BIOS RPLSFWI1.R00.3301.A02.2208050712 08/05/2022
      [   12.988239] Call Trace:
      [   12.988240]  <TASK>
      [   12.988242]  dump_stack_lvl+0xd7/0xf0
      [   12.988248]  dump_stack+0x10/0x20
      [   12.988250]  ubsan_epilogue+0x9/0x40
      [   12.988253]  __ubsan_handle_shift_out_of_bounds+0x10e/0x170
      [   12.988260]  dma_resv_reserve_fences.cold+0x2b/0x48
      [   12.988262]  ? ww_mutex_lock_interruptible+0x3c/0x110
      [   12.988267]  drm_exec_prepare_obj+0x45/0x60 [drm_exec]
      [   12.988271]  ? vm_bind_ioctl_ops_execute+0x5b/0x740 [xe]
      [   12.988345]  vm_bind_ioctl_ops_execute+0x78/0x740 [xe]
      
      It is caused by the value 0 of parameter num_fences in function
      drm_exec_prepare_obj.  And lead to in function __rounddown_pow_of_two,
      "0 - 1" causes the shift-out-of-bounds.
      
      By design drm_exec_prepare_obj() should be called only when there are
      fences to be reserved. If num_fences is 0, calling drm_exec_lock_obj()
      is sufficient as was done in commit 9377de4c ("drm/xe/vm: Avoid
      reserving zero fences")
      
      Cc: Nirmoy Das <nirmoy.das@intel.com>
      Cc: Matthew Brost <matthew.brost@intel.com>
      Signed-off-by: default avatarShuicheng Lin <shuicheng.lin@intel.com>
      Reviewed-by: default avatarNirmoy Das <nirmoy.das@intel.com>
      Link: https://lore.kernel.org/all/24d4a9a9-c622-4f56-8672-21f4c6785476@amd.com
      Link: https://patchwork.freedesktop.org/patch/msgid/20240507130411.630361-1-shuicheng.lin@intel.comSigned-off-by: default avatarLucas De Marchi <lucas.demarchi@intel.com>
      205e5c4b
  2. 08 May, 2024 5 commits
  3. 07 May, 2024 7 commits
  4. 06 May, 2024 8 commits
  5. 03 May, 2024 6 commits
  6. 02 May, 2024 2 commits
  7. 01 May, 2024 2 commits
  8. 30 Apr, 2024 3 commits
    • Nirmoy Das's avatar
      drm/xe: Remove uninitialized end var from xe_gt_tlb_invalidation_range() · e29a7a34
      Nirmoy Das authored
      This fixes commit c4f18703 ("drm/xe: Add
      xe_gt_tlb_invalidation_range and convert PT layer to use this")
      which added the end variable as part of the function param.
      
      v2: Add fixes tag(Matt)
      
      Fixes: c4f18703 ("drm/xe: Add xe_gt_tlb_invalidation_range and convert PT layer to use this")
      Cc: Matthew Brost <matthew.brost@intel.com>
      Signed-off-by: default avatarNirmoy Das <nirmoy.das@intel.com>
      Reviewed-by: default avatarMatthew Brost <matthew.brost@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20240429203039.26918-1-nirmoy.das@intel.comSigned-off-by: default avatarLucas De Marchi <lucas.demarchi@intel.com>
      e29a7a34
    • Dave Airlie's avatar
      Merge tag 'amd-drm-next-6.10-2024-04-26' of... · 4a56c0ed
      Dave Airlie authored
      Merge tag 'amd-drm-next-6.10-2024-04-26' of https://gitlab.freedesktop.org/agd5f/linux into drm-next
      
      amd-drm-next-6.10-2024-04-26:
      
      amdgpu:
      - Misc code cleanups and refactors
      - Support setting reset method at runtime
      - Report OD status
      - SMU 14.0.1 fixes
      - SDMA 4.4.2 fixes
      - VPE fixes
      - MES fixes
      - Update BO eviction priorities
      - UMSCH fixes
      - Reset fixes
      - Freesync fixes
      - GFXIP 9.4.3 fixes
      - SDMA 5.2 fixes
      - MES UAF fix
      - RAS updates
      - Devcoredump updates for dumping IP state
      - DSC fixes
      - JPEG fix
      - Fix VRAM memory accounting
      - VCN 5.0 fixes
      - MES fixes
      - UMC 12.0 updates
      - Modify contiguous flags handling
      - Initial support for mapping kernel queues via MES
      
      amdkfd:
      - Fix rescheduling of restore worker
      - VRAM accounting for SVM migrations
      - mGPU fix
      - Enable SQ watchpoint for gfx10
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      From: Alex Deucher <alexander.deucher@amd.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20240426221245.1613332-1-alexander.deucher@amd.com
      4a56c0ed
    • Dave Airlie's avatar
      Merge tag 'drm-intel-gt-next-2024-04-26' of... · 68b89e23
      Dave Airlie authored
      Merge tag 'drm-intel-gt-next-2024-04-26' of https://anongit.freedesktop.org/git/drm/drm-intel into drm-next
      
      UAPI Changes:
      
      - drm/i915/guc: Use context hints for GT frequency
      
          Allow user to provide a low latency context hint. When set, KMD
          sends a hint to GuC which results in special handling for this
          context. SLPC will ramp the GT frequency aggressively every time
          it switches to this context. The down freq threshold will also be
          lower so GuC will ramp down the GT freq for this context more slowly.
          We also disable waitboost for this context as that will interfere with
          the strategy.
      
          We need to enable the use of SLPC Compute strategy during init, but
          it will apply only to contexts that set this bit during context
          creation.
      
          Userland can check whether this feature is supported using a new param-
          I915_PARAM_HAS_CONTEXT_FREQ_HINT. This flag is true for all guc submission
          enabled platforms as they use SLPC for frequency management.
      
          The Mesa usage model for this flag is here -
          https://gitlab.freedesktop.org/sushmave/mesa/-/commits/compute_hint
      
      - drm/i915/gt: Enable only one CCS for compute workload
      
          Enable only one CCS engine by default with all the compute sices
          allocated to it.
      
          While generating the list of UABI engines to be exposed to the
          user, exclude any additional CCS engines beyond the first
          instance
      
          ***
      
          NOTE: This W/A will make all DG2 SKUs appear like single CCS SKUs by
          default to mitigate a hardware bug. All the EUs will still remain
          usable, and all the userspace drivers have been confirmed to be able
          to dynamically detect the change in number of CCS engines and adjust.
      
          For the smaller percent of applications that get perf benefit from
          letting the userspace driver dispatch across all 4 CCS engines we will
          be introducing a sysfs control as a later patch to choose 4 CCS each
          with 25% EUs (or 50% if 2 CCS).
      
          NOTE: A regression has been reported at
      
          https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/10895
      
          However Andi has been triaging the issue and we're closing in a fix
          to the gap in the W/A implementation:
      
          https://lists.freedesktop.org/archives/intel-gfx/2024-April/348747.html
      
      Driver Changes:
      
      - Add new and fix to existing workarounds: Wa_14018575942 (MTL),
        Wa_16019325821 (Gen12.70), Wa_14019159160 (MTL), Wa_16015675438,
        Wa_14020495402 (Gen12.70) (Tejas, John, Lucas)
      - Fix UAF on destroy against retire race and remove two earlier
        partial fixes (Janusz)
      - Limit the reserved VM space to only the platforms that need it (Andi)
      - Reset queue_priority_hint on parking for execlist platforms (Chris)
      - Fix gt reset with GuC submission is disabled (Nirmoy)
      - Correct capture of EIR register on hang (John)
      
      - Remove usage of the deprecated ida_simple_xx() API
      - Refactor confusing __intel_gt_reset() (Nirmoy)
      - Fix the fix for GuC reset lock confusion (John)
      - Simplify/extend platform check for Wa_14018913170 (John)
      - Replace dev_priv with i915 (Andi)
      - Add and use gt_to_guc() wrapper (Andi)
      - Remove bogus null check (Rodrigo, Dan)
      
      . Selftest improvements (Janusz, Nirmoy, Daniele)
      Signed-off-by: default avatarDave Airlie <airlied@redhat.com>
      
      From: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/ZitVBTvZmityDi7D@jlahtine-mobl.ger.corp.intel.com
      68b89e23
  9. 29 Apr, 2024 3 commits
  10. 28 Apr, 2024 3 commits
    • Linus Torvalds's avatar
      Linux 6.9-rc6 · e67572cd
      Linus Torvalds authored
      e67572cd
    • Linus Torvalds's avatar
      Merge tag 'sched-urgent-2024-04-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · 245c8e81
      Linus Torvalds authored
      Pull scheduler fixes from Ingo Molnar:
      
       - Fix EEVDF corner cases
      
       - Fix two nohz_full= related bugs that can cause boot crashes
         and warnings
      
      * tag 'sched-urgent-2024-04-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        sched/isolation: Fix boot crash when maxcpus < first housekeeping CPU
        sched/isolation: Prevent boot crash when the boot CPU is nohz_full
        sched/eevdf: Prevent vlag from going out of bounds in reweight_eevdf()
        sched/eevdf: Fix miscalculation in reweight_entity() when se is not curr
        sched/eevdf: Always update V if se->on_rq when reweighting
      245c8e81
    • Linus Torvalds's avatar
      Merge tag 'x86-urgent-2024-04-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip · aec147c1
      Linus Torvalds authored
      Pull x86 fixes from Ingo Molnar:
      
       - Make the CPU_MITIGATIONS=n interaction with conflicting
         mitigation-enabling boot parameters a bit saner.
      
       - Re-enable CPU mitigations by default on non-x86
      
       - Fix TDX shared bit propagation on mprotect()
      
       - Fix potential show_regs() system hang when PKE initialization
         is not fully finished yet.
      
       - Add the 0x10-0x1f model IDs to the Zen5 range
      
       - Harden #VC instruction emulation some more
      
      * tag 'x86-urgent-2024-04-28' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
        cpu: Ignore "mitigations" kernel parameter if CPU_MITIGATIONS=n
        cpu: Re-enable CPU mitigations by default for !X86 architectures
        x86/tdx: Preserve shared bit on mprotect()
        x86/cpu: Fix check for RDPKRU in __show_regs()
        x86/CPU/AMD: Add models 0x10-0x1f to the Zen5 range
        x86/sev: Check for MWAITX and MONITORX opcodes in the #VC handler
      aec147c1