diff options
author | Yue Hu <huyue2@coolpad.com> | 2023-04-26 16:44:49 +0800 |
---|---|---|
committer | Gao Xiang <hsiangkao@linux.alibaba.com> | 2023-05-29 15:54:49 +0800 |
commit | 597e2953ae9b4a391e883c1f1a4cda5878e2dbed (patch) | |
tree | 5c13adc1ff379dad6964eef91bdb7d6dcbef6a73 /fs/erofs/zdata.c | |
parent | 7877cb91f1081754a1487c144d85dc0d2e2e7fc4 (diff) |
erofs: fold in z_erofs_decompress()
No need this helper since it's just a simple wrapper for decompress
method and only one caller. So, let's fold in directly instead.
Signed-off-by: Yue Hu <huyue2@coolpad.com>
Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com>
Link: https://lore.kernel.org/r/20230426084449.12781-1-zbestahu@gmail.com
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
Diffstat (limited to 'fs/erofs/zdata.c')
-rw-r--r-- | fs/erofs/zdata.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fs/erofs/zdata.c b/fs/erofs/zdata.c index 160b3da43aec..be8d28631d77 100644 --- a/fs/erofs/zdata.c +++ b/fs/erofs/zdata.c @@ -1283,6 +1283,8 @@ static int z_erofs_decompress_pcluster(struct z_erofs_decompress_backend *be, struct erofs_sb_info *const sbi = EROFS_SB(be->sb); struct z_erofs_pcluster *pcl = be->pcl; unsigned int pclusterpages = z_erofs_pclusterpages(pcl); + const struct z_erofs_decompressor *decompressor = + &erofs_decompressors[pcl->algorithmformat]; unsigned int i, inputsize; int err2; struct page *page; @@ -1326,7 +1328,7 @@ static int z_erofs_decompress_pcluster(struct z_erofs_decompress_backend *be, else inputsize = pclusterpages * PAGE_SIZE; - err = z_erofs_decompress(&(struct z_erofs_decompress_req) { + err = decompressor->decompress(&(struct z_erofs_decompress_req) { .sb = be->sb, .in = be->compressed_pages, .out = be->decompressed_pages, |