lkml.org 
[lkml]   [2011]   [Dec]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH v4 4/4] usb: simplify hdrc configuration
Date
HDRC requires either NOP_USB_XCEIV or TWLX030_USB, and it selects the
right one based on architectures or board.

However, many OMAP2+ boards are excluded from this selection and it's
possible to have a configuration with no transceiver, so HDRC doesn't
work.

What we need is a 'soft' dependency, and this can be achieved by
transforming the 'selects' to 'default'. This way we can have sane
defaults for all OMAP2+ boards, and the ones that need NOP can just
specify that manually.

This simplifies the config from:

CONFIG_USB=y
CONFIG_TWL4030_CORE=y
CONFIG_TWL4030_USB=y

To:

CONFIG_USB=y
CONFIG_TWL4030_CORE=y

And so on.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
---
drivers/usb/musb/Kconfig | 4 +---
drivers/usb/otg/Kconfig | 3 +++
2 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/usb/musb/Kconfig b/drivers/usb/musb/Kconfig
index 07a0346..b60d3a5 100644
--- a/drivers/usb/musb/Kconfig
+++ b/drivers/usb/musb/Kconfig
@@ -7,9 +7,7 @@
config USB_MUSB_HDRC
depends on USB && USB_GADGET
depends on (ARM || (BF54x && !BF544) || (BF52x && !BF522 && !BF523))
- select NOP_USB_XCEIV if (ARCH_DAVINCI || MACH_OMAP3EVM || BLACKFIN)
- select TWL4030_USB if MACH_OMAP_3430SDP
- select TWL6030_USB if MACH_OMAP_4430SDP || MACH_OMAP4_PANDA
+ depends on (NOP_USB_XCEIV || TWL4030_USB || TWL6030_USB)
select USB_OTG_UTILS
select USB_GADGET_DUALSPEED
tristate 'Inventra Highspeed Dual Role Controller (TI, ADI, ...)'
diff --git a/drivers/usb/otg/Kconfig b/drivers/usb/otg/Kconfig
index c66481a..5beb8b7 100644
--- a/drivers/usb/otg/Kconfig
+++ b/drivers/usb/otg/Kconfig
@@ -60,6 +60,7 @@ config TWL4030_USB
tristate "TWL4030 USB Transceiver Driver"
depends on TWL4030_CORE && REGULATOR_TWL4030
select USB_OTG_UTILS
+ default y if ARCH_OMAP3
help
Enable this to support the USB OTG transceiver on TWL4030
family chips (including the TWL5030 and TPS659x0 devices).
@@ -70,6 +71,7 @@ config TWL6030_USB
tristate "TWL6030 USB Transceiver Driver"
depends on TWL4030_CORE
select USB_OTG_UTILS
+ default y if ARCH_OMAP4
help
Enable this to support the USB OTG transceiver on TWL6030
family chips. This TWL6030 transceiver has the VBUS and ID GND
@@ -81,6 +83,7 @@ config TWL6030_USB
config NOP_USB_XCEIV
tristate "NOP USB Transceiver Driver"
select USB_OTG_UTILS
+ default y if ARCH_DAVINCI || MACH_OMAP3EVM || BLACKFIN
help
this driver is to be used by all the usb transceiver which are either
built-in with usb ip or which are autonomous and doesn't require any
--
1.7.8.rc1.14.g248db


\
 
 \ /
  Last update: 2011-12-20 02:19    [from the cache]
©2003-2011 Jasper Spaans