The quilt patch titled Subject: memcg: return the folio in union mc_target has been removed from the -mm tree. Its filename was memcg-return-the-folio-in-union-mc_target.patch This patch was dropped because it was merged into the mm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm ------------------------------------------------------ From: "Matthew Wilcox (Oracle)" <willy@xxxxxxxxxxxxx> Subject: memcg: return the folio in union mc_target Date: Thu, 11 Jan 2024 18:12:17 +0000 All users of target.page convert it to the folio, so we can just return the folio directly and save a few calls to compound_head(). Link: https://lkml.kernel.org/r/20240111181219.3462852-3-willy@xxxxxxxxxxxxx Signed-off-by: Matthew Wilcox (Oracle) <willy@xxxxxxxxxxxxx> Acked-by: Johannes Weiner <hannes@xxxxxxxxxxx> Reviewed-by: Roman Gushchin <roman.gushchin@xxxxxxxxx> Reviewed-by: Muchun Song <muchun.song@xxxxxxxxx> Acked-by: Shakeel Butt <shakeelb@xxxxxxxxxx> Acked-by: Michal Hocko <mhocko@xxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- mm/memcontrol.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) --- a/mm/memcontrol.c~memcg-return-the-folio-in-union-mc_target +++ a/mm/memcontrol.c @@ -5873,7 +5873,7 @@ static int mem_cgroup_do_precharge(unsig } union mc_target { - struct page *page; + struct folio *folio; swp_entry_t ent; }; @@ -6095,7 +6095,7 @@ out: * Return: * * MC_TARGET_NONE - If the pte is not a target for move charge. * * MC_TARGET_PAGE - If the page corresponding to this pte is a target for - * move charge. If @target is not NULL, the page is stored in target->page + * move charge. If @target is not NULL, the folio is stored in target->folio * with extra refcnt taken (Caller should release it). * * MC_TARGET_SWAP - If the swap entry corresponding to this pte is a * target for charge migration. If @target is not NULL, the entry is @@ -6160,7 +6160,7 @@ static enum mc_target_type get_mctgt_typ is_device_coherent_page(page)) ret = MC_TARGET_DEVICE; if (target) - target->page = page; + target->folio = page_folio(page); } if (!ret || !target) { if (target) @@ -6210,7 +6210,7 @@ static enum mc_target_type get_mctgt_typ put_page(page); return MC_TARGET_NONE; } - target->page = page; + target->folio = page_folio(page); } } return ret; @@ -6440,7 +6440,7 @@ static int mem_cgroup_move_charge_pte_ra } target_type = get_mctgt_type_thp(vma, addr, *pmd, &target); if (target_type == MC_TARGET_PAGE) { - folio = page_folio(target.page); + folio = target.folio; if (folio_isolate_lru(folio)) { if (!mem_cgroup_move_account(folio, true, mc.from, mc.to)) { @@ -6452,7 +6452,7 @@ static int mem_cgroup_move_charge_pte_ra folio_unlock(folio); folio_put(folio); } else if (target_type == MC_TARGET_DEVICE) { - folio = page_folio(target.page); + folio = target.folio; if (!mem_cgroup_move_account(folio, true, mc.from, mc.to)) { mc.precharge -= HPAGE_PMD_NR; @@ -6482,7 +6482,7 @@ retry: device = true; fallthrough; case MC_TARGET_PAGE: - folio = page_folio(target.page); + folio = target.folio; /* * We can have a part of the split pmd here. Moving it * can be done but it would be too convoluted so simply _ Patches currently in -mm which might be from willy@xxxxxxxxxxxxx are rmap-replace-two-calls-to-compound_order-with-folio_order.patch writeback-remove-a-duplicate-prototype-for-tag_pages_for_writeback.patch writeback-factor-folio_prepare_writeback-out-of-write_cache_pages.patch writeback-factor-writeback_get_batch-out-of-write_cache_pages.patch writeback-simplify-the-loops-in-write_cache_pages.patch pagevec-add-ability-to-iterate-a-queue.patch writeback-use-the-folio_batch-queue-iterator.patch writeback-move-the-folio_prepare_writeback-loop-out-of-write_cache_pages.patch writeback-remove-a-use-of-write_cache_pages-from-do_writepages.patch bounds-support-non-power-of-two-config_nr_cpus.patch