mirror of
https://github.com/torvalds/linux.git
synced 2026-01-12 00:42:35 +08:00
Merge tag 'mm-hotfixes-stable-2025-12-28-21-50' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
Pull misc fixes from Andrew Morton: "27 hotfixes. 12 are cc:stable, 18 are MM. There's a patch series from Jiayuan Chen which fixes some issues with KASAN and vmalloc. Apart from that it's the usual shower of singletons - please see the respective changelogs for details" * tag 'mm-hotfixes-stable-2025-12-28-21-50' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm: (27 commits) mm/ksm: fix pte_unmap_unlock of wrong address in break_ksm_pmd_entry mm/page_owner: fix memory leak in page_owner_stack_fops->release() mm/memremap: fix spurious large folio warning for FS-DAX MAINTAINERS: notify the "Device Memory" community of memory hotplug changes sparse: update MAINTAINERS info mm/page_alloc: report 1 as zone_batchsize for !CONFIG_MMU mm: consider non-anon swap cache folios in folio_expected_ref_count() rust: maple_tree: rcu_read_lock() in destructor to silence lockdep mm: memcg: fix unit conversion for K() macro in OOM log mm: fixup pfnmap memory failure handling to use pgoff tools/mm/page_owner_sort: fix timestamp comparison for stable sorting selftests/mm: fix thread state check in uffd-unit-tests kernel/kexec: fix IMA when allocation happens in CMA area kernel/kexec: change the prototype of kimage_map_segment() MAINTAINERS: add ABI headers to KHO and LIVE UPDATE .mailmap: remove one of the entries for WangYuli mm/damon/vaddr: fix missing pte_unmap_unlock in damos_va_migrate_pmd_entry() MAINTAINERS: update one straggling entry for Bartosz Golaszewski mm/page_alloc: change all pageblocks migrate type on coalescing mm: leafops.h: correct kernel-doc function param. names ...
This commit is contained in:
@@ -265,7 +265,16 @@ impl<T: ForeignOwnable> MapleTree<T> {
|
||||
loop {
|
||||
// This uses the raw accessor because we're destroying pointers without removing them
|
||||
// from the maple tree, which is only valid because this is the destructor.
|
||||
let ptr = ma_state.mas_find_raw(usize::MAX);
|
||||
//
|
||||
// Take the rcu lock because mas_find_raw() requires that you hold either the spinlock
|
||||
// or the rcu read lock. This is only really required if memory reclaim might
|
||||
// reallocate entries in the tree, as we otherwise have exclusive access. That feature
|
||||
// doesn't exist yet, so for now, taking the rcu lock only serves the purpose of
|
||||
// silencing lockdep.
|
||||
let ptr = {
|
||||
let _rcu = kernel::sync::rcu::Guard::new();
|
||||
ma_state.mas_find_raw(usize::MAX)
|
||||
};
|
||||
if ptr.is_null() {
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user