[libvirt] [PATCH 02/17] conf: relocate virDomainDeviceDef and virDomainHostdevDef
Eric Blake
eblake at redhat.com
Sat Mar 3 02:15:29 UTC 2012
On 02/28/2012 01:14 PM, Laine Stump wrote:
> This patch is only code movement + adding some forward definitions of
> typedefs.
>
> virDomainHostdevDef (not just a pointer to it, but an actual object)
> will be needed in virDomainNetDef and virDomainActualNetDef, so it
> must be relocated earlier in the file.
>
> Likewise, virDomainDeviceDef will be needed in virDomainHostdevDef, so
> it must be moved up even earlier. This, in turn, creates a forward
> reference problem, but fortunately only with pointers to other device
> types, so their typedefs can be moved up in the file, eliminating the
> problem.
> ---
>
> V2: aside from the fact that there are now more types of device to
> have their definitions/enums relocated, I learned that older versions
> of gcc will not allow a duplicate typedef, even if it is identical to
> the original, so rather than just copying the device typedefs from
> their original locations just above each struct definition, I had to
> move them, removing the original.
>
> src/conf/domain_conf.h | 262 ++++++++++++++++++++++++++----------------------
> 1 files changed, 141 insertions(+), 121 deletions(-)
ACK.
--
Eric Blake eblake at redhat.com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 620 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20120302/25f14cd5/attachment-0001.sig>
More information about the libvir-list
mailing list