Hello,

On 2021/7/10 0:52, 5kft wrote:
It appears that the logic in "set_compress_context" (in 
https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/tree/fs/f2fs/f2fs.h, 
line 4021) does not actually set the compression level in the inode for zstd compression 
- it only sets it for lz4:

     if (F2FS_I(inode)->i_compress_algorithm == COMPRESS_LZ4 &&
              F2FS_OPTION(sbi).compress_level)
          F2FS_I(inode)->i_compress_flag |=
                   F2FS_OPTION(sbi).compress_level <<
                   COMPRESS_LEVEL_OFFSET;

Shouldn't this condition include "F2FS_I(inode)->i_compress_algorithm == 
COMPRESS_ZSTD" as part of the condition as well?

You're correct and it's a good catch, I've made a patch to fix this issue.

Thanks a lot for the report!

Thanks,



_______________________________________________
Linux-f2fs-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel



_______________________________________________
Linux-f2fs-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

Reply via email to