mm-backing-dev-use-group-allocation-free-of-per-cpu-counters-api.patch removed from -mm tree
The quilt patch titled
Subject: mm: backing-dev: use group allocation/free of per-cpu counters API
has been removed from the -mm tree. Its filename was
mm-backing-dev-use-group-allocation-free-of-per-cpu-counters-api.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: Kefeng Wang <[email protected]>
Subject: mm: backing-dev: use group allocation/free of per-cpu counters API
Date: Mon, 25 Mar 2024 11:56:35 +0800
Use group allocation/free of per-cpu counters api to accelerate wb_init/exit() and simplify code.
---
mm/backing-dev.c | 23 +++++------------------ 1 file changed, 5 insertions(+), 18 deletions(-)
mm/backing-dev.c renamed from mm/backing-dev.c~mm-backing-dev-use-group-allocation-free-of-per-cpu-counters-api +5 -18
@@ -388,7 +388,7 @@ static void wb_update_bandwidth_workfn(sstatic int wb_init (struct bdi_writeback *wb,struct backing_dev_info *bdi,gfp_t gfp) { -int i, err; +int err;memset (wb,0 ,sizeof (*wb));
@@ -416,18 +416,10 @@ static int wb_init(struct bdi_writebackif (err)return err; -for (i =0 ; i <NR_WB_STAT_ITEMS ; i++) { - err =percpu_counter_init (&wb->stat[i],0 , gfp); -if (err) - goto out_destroy_stat; - } - -return 0 ; + err =percpu_counter_init_many (wb->stat,0 , gfp,NR_WB_STAT_ITEMS ); +if (err) +fprop_local_destroy_percpu (&wb->completions); -out_destroy_stat: -while (i--) -percpu_counter_destroy (&wb->stat[i]); -fprop_local_destroy_percpu (&wb->completions);return err; }
@@ -460,13 +452,8 @@ static void wb_shutdown(struct bdi_writestatic void wb_exit (struct bdi_writeback *wb) { -int i; -WARN_ON (delayed_work_pending (&wb->dwork)); - -for (i =0 ; i <NR_WB_STAT_ITEMS ; i++) -percpu_counter_destroy (&wb->stat[i]); - +percpu_counter_destroy_many (wb->stat,NR_WB_STAT_ITEMS );fprop_local_destroy_percpu (&wb->completions); }
_
Patches currently in -mm which might be from [email protected] are
arm64-mm-drop-vm_fault_badmap-vm_fault_badaccess.patch arm-mm-drop-vm_fault_badmap-vm_fault_badaccess.patch mm-move-mm-counter-updating-out-of-set_pte_range.patch mm-filemap-batch-mm-counter-updating-in-filemap_map_pages.patch mm-swapfile-check-usable-swap-device-in-__folio_throttle_swaprate.patch mm-memory-check-userfaultfd_wp-in-vmf_orig_pte_uffd_wp.patch