copy: calculate bytes per second while copying, and pass to progress info

Also, show it in import-fs/repart.
This commit is contained in:
Lennart Poettering
2025-09-09 17:05:05 +02:00
committed by Luca Boccassi
parent e566236fc1
commit acd4943528
5 changed files with 42 additions and 16 deletions

View File

@@ -236,7 +236,7 @@ typedef struct sd_hwdb sd_hwdb;
/* shared/ forward declarations */
typedef int (*copy_progress_bytes_t)(uint64_t n_bytes, void *userdata);
typedef int (*copy_progress_bytes_t)(uint64_t n_bytes, uint64_t bytes_per_second, void *userdata);
typedef int (*copy_progress_path_t)(const char *path, const struct stat *st, void *userdata);
struct local_address;