Re: [f2fs-dev] [PATCH v2] f2fs-tools: fix typo of HAVE_PREAD macro and remove duplicate semicolons
Brought to you by:
kjgkr
|
From: Chao Yu <ch...@ke...> - 2025-11-25 01:05:58
|
On 11/21/2025 10:42 AM, Xiaole He wrote:
> 1. Fix typo in HAVE_PREAD macro check (lib/libf2fs_io.c:403):
> - Change HAVE_RPEAD -> HAVE_PREAD
> - The misspelled macro caused pread() optimization to never be used,
> forcing the code to always use the slower lseek() + read() path
> instead of the atomic pread() call.
>
> 2. Remove duplicate semicolons:
> - mkfs/f2fs_format.c:211: Remove extra semicolon in hot_ext_count assignment
> - fsck/dump.c:119: Remove extra semicolon in free_segs initialization
>
> These are minor code quality fixes that don't change functionality but
> improve code correctness and enable the pread() optimization.
>
> Fixes: 4b7e95300988 ("f2fs-tools: use pread and pwrite when they are available.")
> Signed-off-by: Xiaole He <hex...@12...>
Reviewed-by: Chao Yu <ch...@ke...>
Thanks,
|