[PATCH v7 4/4] erofs-utils: mkfs: support EROFS meta-only image generation from S3

Gao Xiang hsiangkao at linux.alibaba.com
Fri Aug 8 17:23:09 AEST 2025



On 2025/8/8 15:16, Hongbo Li wrote:

...

>> +                dataimport_mode != EROFS_MKFS_DATA_IMPORT_ZEROFILL)
> 
> Did you forget setting dataimport_mode as EROFS_MKFS_DATA_IMPORT_ZEROFILL?
> 
> diff --git a/mkfs/main.c b/mkfs/main.c
> index 07bc3ed..edc8fff 100644
> --- a/mkfs/main.c
> +++ b/mkfs/main.c
> @@ -1220,6 +1220,7 @@ static int mkfs_parse_options_cfg(int argc, char *argv[])
>                          err = mkfs_parse_s3_cfg(optarg);
>                          if (err)
>                                  return err;
> +                       dataimport_mode = EROFS_MKFS_DATA_IMPORT_ZEROFILL;
>                          break;
>   #endif
>                  case 'V':

No, users need to specify `--clean=0` to make it work.

The default mode is still -EOPNOTSUPP.

Thanks,
Gao Xiang

> 
> 
> Thanks,
> Hongbo
> 
>> +                err = -EOPNOTSUPP;
>> +            else
>> +                err = s3erofs_build_trees(root, &s3cfg,
>> +                              cfg.c_src_path);
>> +            if (err)
>> +                goto exit;
>>   #endif
>>           }



More information about the Linux-erofs mailing list