Skip to content

Commit

Permalink
Kconfig: Extract CONFIG_USB_CHIPIDEA from CONFIG_IMX
Browse files Browse the repository at this point in the history
TYPE_CHIPIDEA models an IP block which is also used in TYPE_ZYNQ_MACHINE which
itself is not an IMX device. CONFIG_ZYNQ selects CONFIG_USB_EHCI_SYSBUS while
TYPE_CHIPIDEA is a separate compilation unit, so only works by accident if
CONFIG_IMX is given. Fix that by extracting CONFIG_USB_CHIPIDEA from CONFIG_IMX.

cc: [email protected]
Fixes: 616ec12 "hw/arm/xilinx_zynq: Fix USB port instantiation"
Signed-off-by: Bernhard Beschow <[email protected]>
Message-id: [email protected]
Reviewed-by: Peter Maydell <[email protected]>
Signed-off-by: Peter Maydell <[email protected]>
  • Loading branch information
shentok authored and pm215 committed Feb 20, 2025
1 parent 262f4ab commit 464ce71
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion hw/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -303,7 +303,7 @@ config ZYNQ
select PL330
select SDHCI
select SSI_M25P80
select USB_EHCI_SYSBUS
select USB_CHIPIDEA
select XILINX # UART
select XILINX_AXI
select XILINX_SPI
Expand Down Expand Up @@ -489,6 +489,7 @@ config FSL_IMX25
select IMX
select IMX_FEC
select IMX_I2C
select USB_CHIPIDEA
select WDT_IMX2
select SDHCI

Expand Down Expand Up @@ -516,6 +517,7 @@ config FSL_IMX6
select PL310 # cache controller
select PCI_EXPRESS_DESIGNWARE
select SDHCI
select USB_CHIPIDEA
select OR_IRQ

config ASPEED_SOC
Expand Down Expand Up @@ -576,6 +578,7 @@ config FSL_IMX7
select SDHCI
select OR_IRQ
select UNIMP
select USB_CHIPIDEA

config ARM_SMMUV3
bool
Expand All @@ -591,6 +594,7 @@ config FSL_IMX6UL
select IMX_I2C
select WDT_IMX2
select SDHCI
select USB_CHIPIDEA
select UNIMP

config MICROBIT
Expand Down
4 changes: 4 additions & 0 deletions hw/usb/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -143,3 +143,7 @@ config USB_DWC3
config XLNX_USB_SUBSYS
bool
select USB_DWC3

config USB_CHIPIDEA
bool
select USB_EHCI_SYSBUS
2 changes: 1 addition & 1 deletion hw/usb/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ system_ss.add(when: 'CONFIG_USB_XHCI_SYSBUS', if_true: files('hcd-xhci-sysbus.c'
system_ss.add(when: 'CONFIG_USB_XHCI_NEC', if_true: files('hcd-xhci-nec.c'))
system_ss.add(when: 'CONFIG_USB_DWC2', if_true: files('hcd-dwc2.c'))
system_ss.add(when: 'CONFIG_USB_DWC3', if_true: files('hcd-dwc3.c'))
system_ss.add(when: 'CONFIG_USB_CHIPIDEA', if_true: files('chipidea.c'))

system_ss.add(when: 'CONFIG_IMX', if_true: files('chipidea.c'))
system_ss.add(when: 'CONFIG_IMX_USBPHY', if_true: files('imx-usb-phy.c'))
system_ss.add(when: 'CONFIG_VT82C686', if_true: files('vt82c686-uhci-pci.c'))
system_ss.add(when: 'CONFIG_XLNX_VERSAL', if_true: files('xlnx-versal-usb2-ctrl-regs.c'))
Expand Down

0 comments on commit 464ce71

Please sign in to comment.