qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Blue Swirl <blauwirbel@gmail.com>
To: Anthony Liguori <aliguori@us.ibm.com>
Cc: qemu-devel@nongnu.org, Gerd Hoffman <kraxel@redhat.com>
Subject: Re: [Qemu-devel] [PATCH] usb-bsd: convert to QOM
Date: Sat, 4 Feb 2012 11:54:57 +0000	[thread overview]
Message-ID: <CAAu8pHsMYk1_cm8JsEOQqVFWHBoxfUwG7Q91auwpHfsdeTwtaQ@mail.gmail.com> (raw)
In-Reply-To: <1328312519-23799-1-git-send-email-aliguori@us.ibm.com>

On Fri, Feb 3, 2012 at 23:41, Anthony Liguori <aliguori@us.ibm.com> wrote:
> Untested but simple enough.
>
> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>

There are still some problems, though build does not fail anymore:
  CC    usb-bsd.o
/src/qemu/usb-bsd.c:417: warning: initialization from incompatible pointer type
/src/qemu/usb-bsd.c:401: warning: 'usb_host_class_initfn' defined but not used

> ---
>  usb-bsd.c |   11 ++++++-----
>  1 files changed, 6 insertions(+), 5 deletions(-)
>
> diff --git a/usb-bsd.c b/usb-bsd.c
> index 2c6afc8..43fd1a1 100644
> --- a/usb-bsd.c
> +++ b/usb-bsd.c
> @@ -410,15 +410,16 @@ static void usb_host_class_initfn(ObjectClass *klass, void *data)
>     uc->handle_destroy = usb_host_handle_destroy;
>  }
>
> -static struct DeviceInfo usb_host_dev_info = {
> -    .name      = "usb-host",
> -    .size      = sizeof(USBHostDevice),
> -    .class_init= usb_host_initfn,
> +static TypeInfo usb_host_dev_info = {
> +    .name          = "usb-host",
> +    .parent        = TYPE_USB_DEVICE,
> +    .instance_size = sizeof(USBHostDevice),
> +    .class_init    = usb_host_initfn,
>  };
>
>  static void usb_host_register_devices(void)
>  {
> -    usb_qdev_register(&usb_host_dev_info, NULL, NULL);
> +    type_register_static(&usb_host_dev_info);
>  }
>  device_init(usb_host_register_devices)
>
> --
> 1.7.4.1
>
>

  reply	other threads:[~2012-02-04 11:55 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-03 23:41 [Qemu-devel] [PATCH] usb-bsd: convert to QOM Anthony Liguori
2012-02-04 11:54 ` Blue Swirl [this message]
2012-02-04 17:07   ` Anthony Liguori
2012-02-04 17:26     ` Blue Swirl
2012-02-04 17:31       ` Blue Swirl

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=CAAu8pHsMYk1_cm8JsEOQqVFWHBoxfUwG7Q91auwpHfsdeTwtaQ@mail.gmail.com \
    --to=blauwirbel@gmail.com \
    --cc=aliguori@us.ibm.com \
    --cc=kraxel@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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).