Commit 0f3ad9c6 authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge tag 'mm-hotfixes-stable-2025-10-22-12-43' of...

Merge tag 'mm-hotfixes-stable-2025-10-22-12-43' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

Pull hotfixes from Andrew Morton:
 "17 hotfixes. 12 are cc:stable and 14 are for MM.

  There's a two-patch DAMON series from SeongJae Park which addresses a
  missed check and possible memory leak. Apart from that it's all
  singletons - please see the changelogs for details"

* tag 'mm-hotfixes-stable-2025-10-22-12-43' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm:
  csky: abiv2: adapt to new folio flags field
  mm/damon/core: use damos_commit_quota_goal() for new goal commit
  mm/damon/core: fix potential memory leak by cleaning ops_filter in damon_destroy_scheme
  hugetlbfs: move lock assertions after early returns in huge_pmd_unshare()
  vmw_balloon: indicate success when effectively deflating during migration
  mm/damon/core: fix list_add_tail() call on damon_call()
  mm/mremap: correctly account old mapping after MREMAP_DONTUNMAP remap
  mm: prevent poison consumption when splitting THP
  ocfs2: clear extent cache after moving/defragmenting extents
  mm: don't spin in add_stack_record when gfp flags don't allow
  dma-debug: don't report false positives with DMA_BOUNCE_UNALIGNED_KMALLOC
  mm/damon/sysfs: dealloc commit test ctx always
  mm/damon/sysfs: catch commit test ctx alloc failure
  hung_task: fix warnings caused by unaligned lock pointers
parents dd72c8fc 9aa12167
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -21,7 +21,7 @@ void update_mmu_cache_range(struct vm_fault *vmf, struct vm_area_struct *vma,

	folio = page_folio(pfn_to_page(pfn));

	if (test_and_set_bit(PG_dcache_clean, &folio->flags))
	if (test_and_set_bit(PG_dcache_clean, &folio->flags.f))
		return;

	icache_inv_range(address, address + nr*PAGE_SIZE);
+2 −2
Original line number Diff line number Diff line
@@ -20,8 +20,8 @@

static inline void flush_dcache_folio(struct folio *folio)
{
	if (test_bit(PG_dcache_clean, &folio->flags))
		clear_bit(PG_dcache_clean, &folio->flags);
	if (test_bit(PG_dcache_clean, &folio->flags.f))
		clear_bit(PG_dcache_clean, &folio->flags.f);
}
#define flush_dcache_folio flush_dcache_folio

+3 −5
Original line number Diff line number Diff line
@@ -1737,7 +1737,7 @@ static int vmballoon_migratepage(struct balloon_dev_info *b_dev_info,
{
	unsigned long status, flags;
	struct vmballoon *b;
	int ret;
	int ret = 0;

	b = container_of(b_dev_info, struct vmballoon, b_dev_info);

@@ -1796,17 +1796,15 @@ static int vmballoon_migratepage(struct balloon_dev_info *b_dev_info,
		 * A failure happened. While we can deflate the page we just
		 * inflated, this deflation can also encounter an error. Instead
		 * we will decrease the size of the balloon to reflect the
		 * change and report failure.
		 * change.
		 */
		atomic64_dec(&b->size);
		ret = -EBUSY;
	} else {
		/*
		 * Success. Take a reference for the page, and we will add it to
		 * the list after acquiring the lock.
		 */
		get_page(newpage);
		ret = 0;
	}

	/* Update the balloon list under the @pages_lock */
@@ -1817,7 +1815,7 @@ static int vmballoon_migratepage(struct balloon_dev_info *b_dev_info,
	 * If we succeed just insert it to the list and update the statistics
	 * under the lock.
	 */
	if (!ret) {
	if (status == VMW_BALLOON_SUCCESS) {
		balloon_page_insert(&b->b_dev_info, newpage);
		__count_vm_event(BALLOON_MIGRATE);
	}
+0 −9
Original line number Diff line number Diff line
@@ -478,14 +478,6 @@ hugetlb_vmdelete_list(struct rb_root_cached *root, pgoff_t start, pgoff_t end,
		if (!hugetlb_vma_trylock_write(vma))
			continue;

		/*
		 * Skip VMAs without shareable locks. Per the design in commit
		 * 40549ba8f8e0, these will be handled by remove_inode_hugepages()
		 * called after this function with proper locking.
		 */
		if (!__vma_shareable_lock(vma))
			goto skip;

		v_start = vma_offset_start(vma, start);
		v_end = vma_offset_end(vma, end);

@@ -496,7 +488,6 @@ hugetlb_vmdelete_list(struct rb_root_cached *root, pgoff_t start, pgoff_t end,
		 * vmas.  Therefore, lock is not held when calling
		 * unmap_hugepage_range for private vmas.
		 */
skip:
		hugetlb_vma_unlock_write(vma);
	}
}
+5 −0
Original line number Diff line number Diff line
@@ -867,6 +867,11 @@ static int __ocfs2_move_extents_range(struct buffer_head *di_bh,
			mlog_errno(ret);
			goto out;
		}
		/*
		 * Invalidate extent cache after moving/defragging to prevent
		 * stale cached data with outdated extent flags.
		 */
		ocfs2_extent_map_trunc(inode, cpos);

		context->clusters_moved += alloc_size;
next:
Loading