[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevi
From: |
Paul Durrant |
Subject: |
Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s |
Date: |
Fri, 4 Jan 2019 16:40:39 +0000 |
> -----Original Message-----
> From: Anthony PERARD [mailto:address@hidden
> Sent: 04 January 2019 16:31
> To: Paul Durrant <address@hidden>
> Cc: address@hidden; address@hidden; xen-
> address@hidden; Kevin Wolf <address@hidden>; Max Reitz
> <address@hidden>; Stefano Stabellini <address@hidden>
> Subject: Re: [PATCH v7 16/18] xen: automatically create XenBlockDevice-s
>
> Almost done, there is one thing left which I believe is an issue.
> Whenever I attach a raw file to QEMU, it print:
> qemu-system-i386: warning: Opening a block device as a file using the
> 'file' driver is deprecated
Oh, I'd not noticed that... but then I only use raw files occasionally.
>
> So, I think the comment below isn't true. We should create a "raw"
> driver for "raw" files.
>
> On Thu, Dec 20, 2018 at 05:14:37PM +0000, Paul Durrant wrote:
> > +static XenBlockDrive *xen_block_drive_create(const char *id,
> > + const char *device_type,
> > + QDict *opts, Error **errp)
> > +{
> ...
>
> > + if (params) {
> > + char **v = g_strsplit(params, ":", 2);
> > +
> > + if (v[1] == NULL) {
> > + filename = g_strdup(v[0]);
> > + driver = g_strdup("file");
> > + } else {
> > + if (strcmp(v[0], "aio") == 0) {
> > + driver = g_strdup("file");
> > + } else if (strcmp(v[0], "vhd") == 0) {
> > + driver = g_strdup("vpc");
> > + } else {
> > + driver = g_strdup(v[0]);
> > + }
> > + filename = g_strdup(v[1]);
> > + }
> > +
> > + g_strfreev(v);
> > + }
> > +
> ...
>
> > + /* If the image is a raw file then we are done */
>
> raw files should use the "raw" driver, so we aren't done yet.
>
Ok. Having a strictly 2-layer stack actually makes things simpler anyway :-)
Paul
> > + if (!strcmp(driver, "file")) {
> > + goto done;
> > + }
>
> --
> Anthony PERARD
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Paul Durrant, 2019/01/04
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Anthony PERARD, 2019/01/04
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s,
Paul Durrant <=
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Kevin Wolf, 2019/01/08
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Paul Durrant, 2019/01/08
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Anthony PERARD, 2019/01/08
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Paul Durrant, 2019/01/08
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Paul Durrant, 2019/01/08
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Kevin Wolf, 2019/01/08
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Paul Durrant, 2019/01/08
- Re: [Qemu-devel] [PATCH v7 16/18] xen: automatically create XenBlockDevice-s, Anthony PERARD, 2019/01/08