[Top][All Lists]

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

[Qemu-devel] Re: [PATCH 5/8] ide/pci: convert to qdev.

From: Gerd Hoffmann
Subject: [Qemu-devel] Re: [PATCH 5/8] ide/pci: convert to qdev.
Date: Fri, 11 Sep 2009 16:58:25 +0200
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv: Gecko/20090814 Fedora/3.0-2.6.b3.fc11 Lightning/1.0pre Thunderbird/3.0b3

On 09/11/09 16:35, Juan Quintela wrote:
-    IDEBus bus[2];
+    IDEBus *bus[2];

You notice this little thing "*" that changed?
VMState preffers pretty much embedded arrays than pointers (arrays of
pointers have the same problem, basically).

Notice the "preffers" part.  VMState can follow pointers, just that each
VMStateDescription is a series of offsets in one structure.  Having
pointers brings to you all the problems associated with ioctl's with
pointers in the middle of the payload.  It is doable, just not nice.

I don't see the problem here.

You'll need a separate VMStateDescription for a IDEBus anyway, then have all the ide drivers use that, just to avoid duplication.

ide will just be

pci will be something like
  /* busmaster stuff goes here */

I fail to see how it makes a big difference whenever the ide bus is referenced or embedded ...


reply via email to

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