[PATCH v3 3/4] erofs-utils: mfks: add rebuild FULLDATA for combined EROFS images
Gao Xiang
hsiangkao at linux.alibaba.com
Wed Apr 15 17:47:42 AEST 2026
On 2026/4/15 11:35, zhaoyifan (H) wrote:
> This patch incorrectly handles inline inode:
>
> Reproduce in erofs-utils directory:
> mkfs/mkfs.erofs 1.erofs man/
> mkfs/mkfs.erofs 2.erofs docs/
> mkfs/mkfs.erofs --clean=data merged.erofs 1.erofs 2.erofs
>
> Then PERFORMANCE.md in merged.erofs contains incorrect data after offset 0x2000.
>
> Fixed with following diff:
>
> diff --git a/lib/inode.c b/lib/inode.c
> index bd10e26..36dce56 100644
> --- a/lib/inode.c
> +++ b/lib/inode.c
> @@ -683,6 +683,13 @@ static int erofs_write_unencoded_data(struct erofs_inode *inode,
>
> /* read the tail-end data */
> if (inode->idata_size) {
> + /*
> + * If inode->idata is already present, the caller has prepared
> + * the tail data and nothing more needs to be done here.
> + */
> + if (inode->idata)
> + return 0;
Yes, it should be fixed as:
/*
* Read the tail-end data if inode->idata is NULL; if the tail data
* has been prepared then nothing more needs to be done here.
*/
if (inode->idata_size && !inode->idata) {
}
...
>> +#include "liberofs_cache.h"
> Unnecessary include `liberofs_cache.h`
That would be nice to be addressed too.
I've applied [PATCH 1 and 2], could you send v4 to address this?
Thanks,
Gao Xiang
More information about the Linux-erofs
mailing list