f2fs: compress: reduce one page array alloc and free when write compressed page

Don't alloc new page pointers array to replace old, just use old, introduce
valid_nr_cpages to indicate valid number of page pointers in array, try to
reduce one page array alloc and free when write compress page.

Signed-off-by: Fengnan Chang <changfengnan@vivo.com>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
This commit is contained in:
Fengnan Chang 2021-11-10 10:37:13 +08:00 • committed by Jaegeuk Kim
commit 3271d7eb00
3 changed files with 12 additions and 22 deletions