X-Git-Url: https://git.kernel.dk/?a=blobdiff_plain;f=backend.c;h=b61de7c0782bfd1400d97b2077da521c7a55e152;hb=06eac6b2318da7759a055c4a3ac01c2c1e8aa764;hp=2e8a9946ac1e85638a0ec84f295f1c3ec4b33ffd;hpb=dcf9844e850e01d7c4db59960bbc4450a8cbf7ef;p=fio.git diff --git a/backend.c b/backend.c index 2e8a9946..b61de7c0 100644 --- a/backend.c +++ b/backend.c @@ -2056,8 +2056,16 @@ static bool check_mount_writes(struct thread_data *td) if (!td_write(td) || td->o.allow_mounted_write) return false; + /* + * If FIO_HAVE_CHARDEV_SIZE is defined, it's likely that chrdevs + * are mkfs'd and mounted. + */ for_each_file(td, f, i) { +#ifdef FIO_HAVE_CHARDEV_SIZE + if (f->filetype != FIO_TYPE_BLOCK && f->filetype != FIO_TYPE_CHAR) +#else if (f->filetype != FIO_TYPE_BLOCK) +#endif continue; if (device_is_mounted(f->file_name)) goto mounted;