qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Re: [PATCH 4/9] qdev/usb: make qemu aware of usb busses.


From: Gerd Hoffmann
Subject: [Qemu-devel] Re: [PATCH 4/9] qdev/usb: make qemu aware of usb busses.
Date: Mon, 31 Aug 2009 15:31:42 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.1) Gecko/20090814 Fedora/3.0-2.6.b3.fc11 Lightning/1.0pre Thunderbird/3.0b3

On 08/31/09 14:45, Juan Quintela wrote:
  pc-bios/bios.bin |  Bin 131072 ->  131072 bytes

Do you really wanted to include this?

Oops, no.  Probably committed by mistake via 'git commit -a'

+static struct {
+    const char *name;
+    const char *qdev;
+} usbdevs[] = {
+    {
+        .name = "mouse",
+        .qdev = "QEMU USB Mouse",
+    },{
+        .name = "tablet",
+        .qdev = "QEMU USB Tablet",

We don't want this table here, we want to be able to compile out
table/mouse/disk/...  And to get that compiled out, vl.c shouldn't have
any knowled of what goes here.

Hmm.  That isn't easy to do for the -usbdevice legacy handling ...

+    /* simple devices which don't need extra care */
+    for (i = 0; i<  ARRAY_SIZE(usbdevs); i++) {
+        if (strcmp(devname, usbdevs[i].name) != 0)
+            continue;

This function should be take care in global function.

parse error. --verbose please.

I think we really need a way to pass the extra parameters to
usb_create_simple

No.  Cases where usb_create_simple() doesn't work are handled via

  usb_create();
  /* set properties here */
  qdev_init();

in the -usbdevice legacy path. When creating devices via -device you'll specify the properties directly on the command line instead. Last patch of the series shows this for usb-msd.

There are some usb devices which are not yet fully converted, i.e. parameters can't be passed via properties. This needs more work.

cheers,
  Gerd




reply via email to

[Prev in Thread] Current Thread [Next in Thread]