qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Kevin Wolf <kwolf@redhat.com>
To: Max Reitz <mreitz@redhat.com>
Cc: qemu-devel@nongnu.org, Stefan Hajnoczi <stefanha@redhat.com>
Subject: Re: [Qemu-devel] [RFC v2 1/6] bdrv: Use "Error" for opening images
Date: Fri, 6 Sep 2013 15:08:36 +0200	[thread overview]
Message-ID: <20130906130836.GI2588@dhcp-200-207.str.redhat.com> (raw)
In-Reply-To: <1378389342-4749-2-git-send-email-mreitz@redhat.com>

Am 05.09.2013 um 15:55 hat Max Reitz geschrieben:
> Add an Error ** parameter to BlockDriver.bdrv_open and
> BlockDriver.bdrv_file_open to allow more specific error messages.
> 
> Signed-off-by: Max Reitz <mreitz@redhat.com>

> diff --git a/block/raw_bsd.c b/block/raw_bsd.c
> index ab2b0fd..793121a 100644
> --- a/block/raw_bsd.c
> +++ b/block/raw_bsd.c
> @@ -130,12 +130,14 @@ static int raw_has_zero_init(BlockDriverState *bs)
>      return bdrv_has_zero_init(bs->file);
>  }
>  
> -static int raw_create(const char *filename, QEMUOptionParameter *options)
> +static int raw_create(const char *filename, QEMUOptionParameter *options,
> +                      Error **errp)
>  {
>      return bdrv_create_file(filename, options);
>  }
>  
> -static int raw_open(BlockDriverState *bs, QDict *options, int flags)
> +static int raw_open(BlockDriverState *bs, QDict *options, int flags,
> +                    Error **errp)
>  {
>      bs->sg = bs->file->sg;
>      return 0;

raw_create() shouldn't be converted in this patch, this causes a build
failure.

Kevin

  reply	other threads:[~2013-09-06 13:08 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-05 13:55 [Qemu-devel] [RFC v2 0/6] block: Error parameter for opening/creating images Max Reitz
2013-09-05 13:55 ` [Qemu-devel] [RFC v2 1/6] bdrv: Use "Error" for opening images Max Reitz
2013-09-06 13:08   ` Kevin Wolf [this message]
2013-09-06 13:36   ` Kevin Wolf
2013-09-05 13:55 ` [Qemu-devel] [RFC v2 2/6] bdrv: Use "Error" for creating images Max Reitz
2013-09-05 13:55 ` [Qemu-devel] [RFC v2 3/6] block: Error parameter for open functions Max Reitz
2013-09-06 13:35   ` Kevin Wolf
2013-09-05 13:55 ` [Qemu-devel] [RFC v2 4/6] block: Error parameter for create functions Max Reitz
2013-09-06 13:45   ` Kevin Wolf
2013-09-05 13:55 ` [Qemu-devel] [RFC v2 5/6] qcow2: Use Error parameter Max Reitz
2013-09-06 14:15   ` Kevin Wolf
2013-09-05 13:55 ` [Qemu-devel] [RFC v2 6/6] bdrv: No silent error message discarding Max Reitz
2013-09-06 14:22   ` Kevin Wolf

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20130906130836.GI2588@dhcp-200-207.str.redhat.com \
    --to=kwolf@redhat.com \
    --cc=mreitz@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=stefanha@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).