Hi, >> I fail to see the point. EHCIPCIState should not be needed outside of >> hcd-ehci-pci.c and I'd prefer to leave it there. Likewise for sysbus. > > It is exactly what I commented on my v1 for needing a v2 and you seemed > to concur... In C, to embed a struct in another struct the compiler > needs the full struct definition (compare i440fx, prep_pci series) and > it thus needs to be in an #include'able header.
Sure. > @@ -115,6 +115,9 @@ typedef struct Tegra2State { > TegraClocksState clocks; > SDHCIState sdhci[4]; > TegraI2CState i2c[4]; > +#if 0 > + EHCISysBusState usb[3]; > +#endif > } Tegra2State; Ah, *that* is the place where you need it (outside hcd-ehci-sysbus.c). Makes sense indeed. I'll go put the bits as-is into the usb queue. cheers, Gerd