Skip to contentSkip to conversation

Make sysbus EHCI devices ARM only by default

PATCH In review David Gibson 3 participants 5 messages Feb 18, 2015 – Mar 2, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Make sysbus EHCI devices ARM only by default

A number of ARM embedded boards include EHCI USB host controllers which appear as directly mapped devices, rather than sitting on a PCI bus.

At present code to emulate such devices is included whenever EHCI support is included. This patch adjusts teh config options to only include them in builds targetting ARM by default.

---
 default-configs/arm-softmmu.mak | 1 +
 hw/usb/Makefile.objs            | 3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)
default-configs/arm-softmmu.mak +1 -0
index 7671ee2..b00c2e1 100644
@@ -33,6 +33,7 @@ CONFIG_PFLASH_CFI01=y
 CONFIG_PFLASH_CFI02=y
 CONFIG_MICRODRIVE=y
 CONFIG_USB_MUSB=y
+CONFIG_USB_EHCI_SYSBUS=y
 
 CONFIG_ARM11MPCORE=y
 CONFIG_A9MPCORE=y
hw/usb/Makefile.objs +2 -1
index 3fe4dff..0ccd477 100644
@@ -5,7 +5,8 @@ common-obj-y += libhw.o
 # usb host adapters
 common-obj-$(CONFIG_USB_UHCI) += hcd-uhci.o
 common-obj-$(CONFIG_USB_OHCI) += hcd-ohci.o
-common-obj-$(CONFIG_USB_EHCI) += hcd-ehci.o hcd-ehci-pci.o hcd-ehci-sysbus.o
+common-obj-$(CONFIG_USB_EHCI) += hcd-ehci.o hcd-ehci-pci.o
+common-obj-$(CONFIG_USB_EHCI_SYSBUS) += hcd-ehci-sysbus.o
 common-obj-$(CONFIG_USB_XHCI) += hcd-xhci.o
 common-obj-$(CONFIG_USB_MUSB) += hcd-musb.o
 
Signature · 1 line
2.1.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 6 lines · David Gibson

A number of ARM embedded boards include EHCI USB host controllers which appear as directly mapped devices, rather than sitting on a PCI bus.

At present code to emulate such devices is included whenever EHCI support is included. This patch adjusts teh config options to only include them in builds targetting ARM by default.

I'm not even sure if any ARM board is using it, so it could just be killed I think. If not,

Paolo

Quoted 33 lines
---
 default-configs/arm-softmmu.mak | 1 +
 hw/usb/Makefile.objs            | 3 ++-
 2 files changed, 3 insertions(+), 1 deletion(-)
default-configs/arm-softmmu.mak +1 -0
index 7671ee2..b00c2e1 100644
@@ -33,6 +33,7 @@ CONFIG_PFLASH_CFI01=y
 CONFIG_PFLASH_CFI02=y
 CONFIG_MICRODRIVE=y
 CONFIG_USB_MUSB=y
+CONFIG_USB_EHCI_SYSBUS=y
 
 CONFIG_ARM11MPCORE=y
 CONFIG_A9MPCORE=y
hw/usb/Makefile.objs +2 -1
index 3fe4dff..0ccd477 100644
@@ -5,7 +5,8 @@ common-obj-y += libhw.o
 # usb host adapters
 common-obj-$(CONFIG_USB_UHCI) += hcd-uhci.o
 common-obj-$(CONFIG_USB_OHCI) += hcd-ohci.o
-common-obj-$(CONFIG_USB_EHCI) += hcd-ehci.o hcd-ehci-pci.o hcd-ehci-sysbus.o
+common-obj-$(CONFIG_USB_EHCI) += hcd-ehci.o hcd-ehci-pci.o
+common-obj-$(CONFIG_USB_EHCI_SYSBUS) += hcd-ehci-sysbus.o
 common-obj-$(CONFIG_USB_XHCI) += hcd-xhci.o
 common-obj-$(CONFIG_USB_MUSB) += hcd-musb.o
 
#2 lore raw
In reply to David Gibson
Quoted 8 lines · David Gibson

A number of ARM embedded boards include EHCI USB host controllers which appear as directly mapped devices, rather than sitting on a PCI bus.

At present code to emulate such devices is included whenever EHCI support is included. This patch adjusts teh config options to only include them in builds targetting ARM by default.

After this commit, the 'pc' machine type lost a few devices, as noticed by the vmstate checker nightly run. Is this expected?

Section "xlnx,ps7-usb" does not exist in dest Section "fusbh200-ehci-usb" does not exist in dest Section "tegra2-ehci-usb" does not exist in dest Section "sysbus-ehci-usb" does not exist in dest Section "exynos4210-ehci-usb" does not exist in dest

Amit

#3 lore raw
Quoted 10 lines · Amit Shah
Quoted 8 lines · David Gibson

A number of ARM embedded boards include EHCI USB host controllers which appear as directly mapped devices, rather than sitting on a PCI bus.

At present code to emulate such devices is included whenever EHCI support is included. This patch adjusts teh config options to only include them in builds targetting ARM by default.

Quoted 8 lines

After this commit, the 'pc' machine type lost a few devices, as noticed by the vmstate checker nightly run. Is this expected?

Section "xlnx,ps7-usb" does not exist in dest Section "fusbh200-ehci-usb" does not exist in dest Section "tegra2-ehci-usb" does not exist in dest Section "sysbus-ehci-usb" does not exist in dest Section "exynos4210-ehci-usb" does not exist in dest

Yes, that's expected. Those are all sysbus EHCI interfaces that AFAIK are only actually used on certain ARM platforms.

Signature · 4 lines
David Gibson			| I'll have my music baroque, and my code
david AT gibson.dropbear.id.au	| minimalist, thank you.  NOT _the_ _other_
				| _way_ _around_!
http://www.ozlabs.org/~dgibson
#4 lore raw
Quoted 14 lines · David Gibson
Quoted 13 lines · Amit Shah
Quoted 8 lines · David Gibson

A number of ARM embedded boards include EHCI USB host controllers which appear as directly mapped devices, rather than sitting on a PCI bus.

At present code to emulate such devices is included whenever EHCI support is included. This patch adjusts teh config options to only include them in builds targetting ARM by default.

After this commit, the 'pc' machine type lost a few devices, as noticed by the vmstate checker nightly run. Is this expected?

Quoted 8 lines
Quoted 5 lines

Section "xlnx,ps7-usb" does not exist in dest Section "fusbh200-ehci-usb" does not exist in dest Section "tegra2-ehci-usb" does not exist in dest Section "sysbus-ehci-usb" does not exist in dest Section "exynos4210-ehci-usb" does not exist in dest

Yes, that's expected. Those are all sysbus EHCI interfaces that AFAIK are only actually used on certain ARM platforms.

OK, thanks.

Amit