[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v5 2/6] block: Avoid BlockDriverState.filename
From: |
Kevin Wolf |
Subject: |
Re: [Qemu-devel] [PATCH v5 2/6] block: Avoid BlockDriverState.filename |
Date: |
Mon, 26 Oct 2015 17:51:59 +0100 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Am 19.10.2015 um 20:49 hat Max Reitz geschrieben:
> In places which directly pass a filename to the OS, we should not use
> the filename field at all but exact_filename instead (although the
> former currently equals the latter if that is set).
>
> In raw_open_common(), we do not need to access BDS.filename because we
> already have a local variable pointing to the filename.
>
> Signed-off-by: Max Reitz <address@hidden>
> diff --git a/block/raw-posix.c b/block/raw-posix.c
> index 918c756..9cb7ebd 100644
> --- a/block/raw-posix.c
> +++ b/block/raw-posix.c
> @@ -505,7 +505,7 @@ static int raw_open_common(BlockDriverState *bs, QDict
> *options,
> "specified. Falling back to aio=threads.\n"
> " This will become an error condition in "
> "future QEMU versions.\n",
> - bs->filename);
> + filename);
> }
> #else
> if (bdrv_flags & BDRV_O_NATIVE_AIO) {
error_printf("WARNING: aio=native was specified for '%s', but "
"is not supported in this build. Falling back to "
"aio=threads.\n"
" This will become an error condition in "
"future QEMU versions.\n",
bs->filename);
}
That's another instance that should be changed.
Kevin
- [Qemu-devel] [PATCH v5 0/6] block: Drop BDS.filename, Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v5 1/6] block: Change bdrv_get_encrypted_filename(), Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v5 2/6] block: Avoid BlockDriverState.filename, Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v5 3/6] block: Add bdrv_filename(), Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v5 4/6] qemu-img: Use bdrv_filename() for map, Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v5 6/6] iotests: Test changed Quorum filename, Max Reitz, 2015/10/19
- [Qemu-devel] [PATCH v5 5/6] block: Drop BlockDriverState.filename, Max Reitz, 2015/10/19