[PATCH 2/2] erofs-utils: lib: refine tailpcluster compression approach

Gao Xiang hsiangkao at linux.alibaba.com
Tue Feb 8 08:52:28 AEDT 2022


On Sat, Feb 05, 2022 at 12:09:44AM +0800, Gao Xiang wrote:
> As my previous comment [1] mentioned, currently, in order to inline
> a tail pcluster right after its inode metadata, tail data is split,
> compressed with many 4KiB pclusters and then the last pcluster is
> chosen.
> 
> However, it can have some impacts to overall compression ratios if big
> pclusters are enabled. So instead, let's implement another approach:
> compressing with two pclusters by trying recompressing.
> 
> It also enables EOF lcluster inlining for small compressed data, so
> please make sure the kernel is already fixed up [2].
> 
> [1] https://lore.kernel.org/r/YXkBIpcCG12Y8qMN@B-P7TQMD6M-0146.local
> [2] https://lore.kernel.org/r/20220203190203.30794-1-xiang@kernel.org
> Signed-off-by: Gao Xiang <hsiangkao at linux.alibaba.com>

Yue Hu reported a buffer overflow case with some specific file due to
this patch. So don't use it immediately. I will investigate soon.

Thanks,
Gao Xiang


More information about the Linux-erofs mailing list