[PATCH 1/1] USB: Chipidea: Create a menu in Kconfig to choose driver bindings

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

 



It's more flexible to enable each driver binding, especially
when one driver binding is used by more than one platforms.

Signed-off-by: Richard Zhao <richard.zhao@xxxxxxxxxxxxx>
---
 drivers/usb/chipidea/Kconfig  |   18 ++++++++++++++++++
 drivers/usb/chipidea/Makefile |    9 ++-------
 2 files changed, 20 insertions(+), 7 deletions(-)

diff --git a/drivers/usb/chipidea/Kconfig b/drivers/usb/chipidea/Kconfig
index fd36dc8..91cf82b 100644
--- a/drivers/usb/chipidea/Kconfig
+++ b/drivers/usb/chipidea/Kconfig
@@ -29,4 +29,22 @@ config USB_CHIPIDEA_DEBUG
 	help
 	  Say Y here to enable debugging output of the ChipIdea driver.
 
+menu "ChipIdea driver bindings"
+
+config USB_CHIPIDEA_PCI
+	tristate "PCI ChipIdea USB controller"
+	default y if PCI
+	depends on PCI
+	help
+	  Say Y here to enable ChipIdea USB controller with PCI interface.
+
+config USB_CHIPIDEA_MSM
+	tristate "MSM ChipIdea USB controller"
+	default y if ARCH_MSM
+	depends on ARCH_MSM
+	help
+	  Say Y here to enable ChipIdea USB controller for Qualcomm MSM SoCs.
+
+endmenu
+
 endif
diff --git a/drivers/usb/chipidea/Makefile b/drivers/usb/chipidea/Makefile
index cc34937..74d8c60 100644
--- a/drivers/usb/chipidea/Makefile
+++ b/drivers/usb/chipidea/Makefile
@@ -5,10 +5,5 @@ ci_hdrc-$(CONFIG_USB_CHIPIDEA_UDC)	+= udc.o
 ci_hdrc-$(CONFIG_USB_CHIPIDEA_HOST)	+= host.o
 ci_hdrc-$(CONFIG_USB_CHIPIDEA_DEBUG)	+= debug.o
 
-ifneq ($(CONFIG_PCI),)
-	obj-$(CONFIG_USB_CHIPIDEA)	+= ci13xxx_pci.o
-endif
-
-ifneq ($(CONFIG_ARCH_MSM),)
-	obj-$(CONFIG_USB_CHIPIDEA)	+= ci13xxx_msm.o
-endif
+obj-$(CONFIG_USB_CHIPIDEA_PCI)		+= ci13xxx_pci.o
+obj-$(CONFIG_USB_CHIPIDEA_MSM)		+= ci13xxx_msm.o
-- 
1.7.5.4


--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux