Linux 7.2 Released
Linux 7.2 Released
Linux 7.2 was tagged and released this week, on the regular schedule.
This cycle was one of the busiest ever, only been beaten by 6.7. This is considered the “new normal”, given that the last 3 or 4 cycles had been pretty busy, especially regarding fixes. There’s some interesting achievements this cycle, like cache-aware scheduling, improvements on MGLRU, the concept of sub-schedulers for sched_ext (a good introduction on the topic by LWN), automatic creation of multi-size transparent hugepages (also a good intro on LWN ) and more - check the LWN articles (part 1 and part 2) for the full picture.
Igalia as usual had a good share of contributions, mainly the DRM scheduler fair policy, which had a regression reported at the 11th hour (see below), hence is present as opt-in. Other than that, we landed very nifty runtime power management for GPUs in the Raspberry Pi 4 and 5, improvements in sched_ext, futex, and general bugfixing. Let’s review the highlights!
Igalia Changelog
DRM scheduler fair policy
For this release cycle we planned to land and enable the DRM scheduler fair policy which brings significant improvements in scenarios where multiple clients are sharing the GPU, and also when a light interactive client competes for the GPU with a demanding one. Unfortunately, due a last-minute regression report during the 7.2-rc7 week, the default policy will remain the old first-in/first-out (FIFO) scheduler. As the fix for the fair policy regression is already known and early testing looks promising, we are hopeful it will get re-enabled in a next kernel release.
sched_ext
We improved sched-ext observability to simplify debugging. When a custom sched-ext scheduler hits a runtime error – such as failing to schedule a task for over 30 seconds – the kernel ejects it and reverts to the default scheduler. To help diagnose these failures, the kernel dumps the status of each CPU. However, especially on high-core systems, these dumps can be truncated due to buffer size limits between kernel space and user space. We mitigated this by prioritizing the exit CPU (the CPU that triggered the error) so it is dumped first, while also surfacing its CPU ID directly to BPF schedulers and userspace tools.
Power Management to Raspberry Pi GPUs and more
In this release, we landed support for Runtime Power Management on the Raspberry Pi 4 and 5 GPUs.
Until now, the V3D driver had a very simple power model: the GPU clock was enabled during probe and remained enabled for the entire lifetime of the driver. Although this approach was simple and functional, it meant that an idle GPU would still consume power even when it was not actively executing jobs.
With Runtime PM, the GPU is powered only when it is actually processing work, and its clock can be disabled while the GPU is idle. This reduces power consumption when the Raspberry Pi is not using the GPU. We wrote a blog post about this feature with more details and some power measurements.
We also fixed two long-standing bugs in the Raspberry Pi 3 GPU driver that had been affecting RetroPie users for years, causing random GPU hangs and complete system crashes. The problems were traced to how the kernel handled tile memory when the GPU ran out of space while processing a frame. Our fixes ensure that each graphics job only writes to its own memory area and that reused memory is properly cleared before being used again, preventing stale or corrupted data from reaching the GPU. With these fixes, RetroPie users should no longer experience the crashes that could occur while navigating the menus.
Finally, we landed several fixes for GPU resets on Raspberry Pi 4 and 5, making the reset process more reliable and consistent.
Futex tests and documentation
We continue to work to improve and maintain futex(), an important system call used by all types of workloads to create synchronization mechanisms. In this cycle, we helped to design and land a solution for a 14 year old bug that has been affecting the robust list mechanism with data corruption in some edge cases.
General bugfixing
We have fixed a long-standing issue in the ueagle-atm driver, which could hit a race condition between kernfs create and remove operations during device probe and disconnect, through the request_firmware API, and generated several bug reports in syzbot over the years.
We helped to improve the correctness of the inline-assembly implementation of memcmp() used during x86 boot, preventing subtle potential bugs due to compiler optimization and instruction reordering.
Towards full HDMI 2.1 support
Part of the HDMI 2.1 Fixed Rate Link (FRL) support released in this version dates back to the work of Rodrigo Siqueira from Igalia during his time at AMD. This work implements the initial support that allows the amdgpu driver to communicate with HDMI 2.1 monitors (primarily the FRL implementation). This implementation was outside the main code for several years before being incorporated into the source code, with some parts kept virtually as originally written and others reworked throughout the process. At Igalia, we have experience with various DRM/KMS drivers, and this hands-on experience with HDMI 2.1 features complements the knowledge necessary for vendors to enable cutting-edge features to their own drivers.
Authored (82)
André Almeida
- Documentation: futex: Add a note about robust list race condition
- selftests: futex: Add tests for robust release operations
Changwoo Min
- sched_ext: Extract scx_dump_cpu() from scx_dump_state()
- sched_ext: Dump the exit CPU first
- sched_ext: Expose exit_cpu to BPF and userspace
Helen Koike
- fs/ntfs3: call _ntfs_bad_inode() when failing to rename
- tipc: fix infinite loop in __tipc_nl_compat_dumpit
John Harrison
Jose Maria Casanova Crespo
Mauricio Faria de Oliveira
- usb: atm: ueagle-atm: use dev_dbg() for ‘device found’ message
- usb: atm: ueagle-atm: remove function entry/exit debug messages
- usb: atm: ueagle-atm: wait for pre-firmware load in .disconnect()
- x86/boot: Add volatile, clobbers and zero-length test in memcmp()
Maíra Canal
- drm/vc4: Use devm_request_irq() for automatic cleanup
- drm/vc4: Clean-up UAPI header inclusion
- drm/v3d: Use devm_reset_control_get_optional_exclusive()
- drm/v3d: Allocate all resources before enabling the clock
- drm/v3d: Introduce Runtime Power Management
- drm/connector: Make drm_connector_attach_hdr_output_metadata_property() return void
- drm/v3d: Flush MMU TLB and cache during runtime resume
- drm/v3d: Clean caches before runtime suspend
- drm/v3d: Reject invalid indirect BO handle in indirect CSD setup
- drm/v3d: Reach the GMP through the hub registers on V3D 7.x
- drm/v3d: Idle AXI transactions before disabling the clock on suspend
- drm/vc4: Zero the tile state data array before each BIN job
- drm/v3d: Serialize the scheduler timeout handlers
Thadeu Lima de Souza Cascardo
Tvrtko Ursulin
- dma-fence: Fix potential tracepoint null pointer dereferences
- drm/sched: Disallow initializing entities with no schedulers
- drm/sched: Consolidate entity run queue management
- drm/sched: Move run queue related code into a separate file
- drm/sched: Add some scheduling quality unit tests
- drm/sched: Add some more scheduling quality unit tests
- drm/sched: Implement RR via FIFO
- drm/sched: Free all finished jobs at once
- drm/sched: Account entity GPU time
- drm/sched: Remove idle entity from tree
- drm/sched: Add fair scheduling policy
- drm/sched: Favour interactive clients slightly
- drm/sched: Switch default policy to fair
- drm/sched: Remove FIFO and RR and simplify to a single run queue
- drm/sched: Embed run queue singleton into the scheduler
- accel/amdxdna: Remove drm_sched_init_args->num_rqs usage
- accel/rocket: Remove drm_sched_init_args->num_rqs usage
- accel/ethosu: Remove drm_sched_init_args->num_rqs usage
- drm/amdgpu: Remove drm_sched_init_args->num_rqs usage
- drm/etnaviv: Remove drm_sched_init_args->num_rqs usage
- drm/imagination: Remove drm_sched_init_args->num_rqs usage
- drm/lima: Remove drm_sched_init_args->num_rqs usage
- drm/msm: Remove drm_sched_init_args->num_rqs usage
- drm/nouveau: Remove drm_sched_init_args->num_rqs usage
- drm/panfrost: Remove drm_sched_init_args->num_rqs usage
- drm/panthor: Remove drm_sched_init_args->num_rqs usage
- drm/sched: Remove drm_sched_init_args->num_rqs usage
- drm/v3d: Remove drm_sched_init_args->num_rqs usage
- drm/xe: Remove drm_sched_init_args->num_rqs usage
- drm/sched: Remove drm_sched_init_args->num_rqs
- drm/xe/xelp: Fix Wa_18022495364
- drm/xe: Use fb cached min alignment
- drm/xe: Assign queue name in time for drm_sched_init
- drm/sched: Fix clang build warning in kunit tests
- amd/amdkfd: Fix profiler lock init order
- drm/amdgpu: Fix context pstate override handling
- Revert “drm/sched: Remove drm_sched_init_args->num_rqs”
- Revert “drm/xe: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/v3d: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/sched: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/panthor: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/panfrost: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/nouveau: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/msm: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/lima: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/imagination: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/etnaviv: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/amdgpu: Remove drm_sched_init_args->num_rqs usage”
- Revert “accel/ethosu: Remove drm_sched_init_args->num_rqs usage”
- Revert “accel/rocket: Remove drm_sched_init_args->num_rqs usage”
- Revert “accel/amdxdna: Remove drm_sched_init_args->num_rqs usage”
- Revert “drm/sched: Embed run queue singleton into the scheduler”
- Revert “drm/sched: Remove FIFO and RR and simplify to a single run queue”
- Revert “drm/sched: Switch default policy to fair”
- drm/sched: Mark fair policy as experimental
Reviewed (74)
André Almeida
- futex: Move futex task related data into a struct
- futex: Provide UABI defines for robust list entry modifiers
- uaccess: Provide unsafe_atomic_store_release_user()
- x86: Select ARCH_MEMORY_ORDER_TSO
- futex: Cleanup UAPI defines
- futex: Add support for unlocking robust futexes
- futex: Add robust futex unlock IP range
- futex: Provide infrastructure to plug the non contended robust futex unlock race
- x86/vdso: Prepare for robust futex unlock support
- x86/vdso: Implement __vdso_futex_robust_try_unlock()
- mailmap: Update Maíra Canal’s email address
Changwoo Min
- sched_ext: Add ext_types.h for early subsystem-wide defs
- sched_ext: Rename ops_cpu_valid() to scx_cpu_valid() and expose it
- sched_ext: Move scx_exit(), scx_error() and friends to ext_internal.h
- sched_ext: Shift scx_kick_cpu() validity check to scx_bpf_kick_cpu()
- sched_ext: Relocate cpu_acquire/cpu_release to end of struct sched_ext_ops
- sched_ext: Make scx_enable() take scx_enable_cmd
- sched_ext: Add topological CPU IDs (cids)
- sched_ext: Add scx_bpf_cid_override() kfunc
- tools/sched_ext: Add struct_size() helpers to common.bpf.h
- sched_ext: Add cmask, a base-windowed bitmap over cid space
- sched_ext: Add cid-form kfunc wrappers alongside cpu-form
- sched_ext: Add bpf_sched_ext_ops_cid struct_ops type
- sched_ext: Forbid cpu-form kfuncs from cid-form schedulers
- tools/sched_ext: scx_qmap: Restart on hotplug instead of cpu_online/offline
- tools/sched_ext: scx_qmap: Add cmask-based idle tracking and cid-based idle pick
- tools/sched_ext: scx_qmap: Port to cid-form struct_ops
- sched_ext: Require cid-form struct_ops for sub-sched support
Christian Gmeiner
Iago Toral Quiroga
- drm/v3d: Flush MMU TLB and cache during runtime resume
- drm/v3d: Clean caches before runtime suspend
- drm/v3d: Reject invalid indirect BO handle in indirect CSD setup
- drm/v3d: Reach the GMP through the hub registers on V3D 7.x
- drm/v3d: Idle AXI transactions before disabling the clock on suspend
- drm/vc4: Supply the overflow slot size in BPOS, not the whole bin BO size
- drm/vc4: Zero the tile state data array before each BIN job
- drm/v3d: Serialize the scheduler timeout handlers
Luis Henriques
- fuse: invalidate readdir cache on epoch bump
- fs: preserve ACL_DONT_CACHE state in forget_cached_acl()
Maíra Canal
- drm/vc4: Prevent shader BO mappings from becoming writable
- drm/vc4: hvs/v3d: Fix null dereference in unbind
- drm/vc4: Shut down BO cache timer before teardown
- drm/vc4: Supply the overflow slot size in BPOS, not the whole bin BO size
Melissa Wen
- drm/vc4: Use devm_request_irq() for automatic cleanup
- drm/vc4: Clean-up UAPI header inclusion
- drm/v3d: Use devm_reset_control_get_optional_exclusive()
- drm/v3d: Allocate all resources before enabling the clock
- drm/v3d: Introduce Runtime Power Management
- drm/connector: Make drm_connector_attach_hdr_output_metadata_property() return void
- drm/amd/display: Delete unimplemented dm_pp_apply_power_level_change_request() (v2)
- drm/amd/display: Delete dce_get_required_clocks_state()
- drm/amd/display: Remove min/max clock levels from clk_mgr (v2)
- drm/amd/display: Delete max_clocks_state
- drm/amd/display: Set max supported display clock without max_clks_by_state (v2)
- drm/amd/display: Delete max_clks_by_state from DCE clock manager (v2)
- drm/amd/display: Delete disp_clk_voltage from integrated info (v2)
- drm/amd/display: Delete dm_pp_clocks_state
- drm/amd/pm: Delete unused get_display_power_level() function
- drm/amd/pm: Delete dummy get_dal_power_level implementations
- drm/amd/pm: Delete non-functional SMU8 get_dal_power_level implementation
- drm/amd/pm: Delete vddc_dep_on_dal_pwrl
- drm/amd/pm: Delete get_dal_power_level
- drm/amd/pm: Delete PP_DAL_POWERLEVEL
- drm/amd/display: Fix mem_type change detection for async flips
- drm: Guard DRM_CLIENT_CAP_PLANE_COLOR_PIPELINE
- drm/amd/display: Fix NULL pointer dereference in amdgpu_dm_crtc_set_vblank()
Tvrtko Ursulin
- drm/i915/gem: Drop check for changed VM in EXECBUF
- dma-buf/dma_fence_array: remove unused functionality v4
- Revert “i915: don’t use a vma that didn’t match the context VM”
- drm/amdgpu: initialize irq.lock spinlock earlier
- amdgpu/ih6.1: Fix minor version
- drm/amdgpu: Use system unbound workqueue for soft IH ring
- drm/i915/gem: Add missing nospec on parallel submit slot
- drm/xe/guc: Keep scheduler timeline name alive
Acked (13)
Maíra Canal
Melissa Wen
Thadeu Lima de Souza Cascardo
- platform/x86: classmate-laptop: Address memory leaks on driver removal
- platform/x86: classmate-laptop: Unify probe rollback and remove code
- platform/x86: classmate-laptop: Pass struct device pointer to helpers
- platform/x86: classmate-laptop: Rename two helper functions
- platform/x86: classmate-laptop: Register ACPI notify handlers directly
- platform/x86: classmate-laptop: Convert v4 accel driver to a platform one
- platform/x86: classmate-laptop: Convert accel driver to a platform one
- platform/x86: classmate-laptop: Convert tablet driver to a platform one
- platform/x86: classmate-laptop: Convert ipml driver to a platform one
- platform/x86: classmate-laptop: Convert keys driver to a platform one