public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
From: Bob Liu <lliubbo@gmail.com>
To: linux-omap@vger.kernel.org
Cc: archit@ti.com, tony@atomide.com, balbi@ti.com,
	adrian.hunter@nokia.com, Bob Liu <lliubbo@gmail.com>
Subject: [PATCH] arm: omap3beagle: init musb default role by Kconfig
Date: Tue, 15 Feb 2011 16:55:00 +0800	[thread overview]
Message-ID: <1297760100-7200-1-git-send-email-lliubbo@gmail.com> (raw)

Currently musb is initialized to OTG mode by default in musb_board_data, it's
better to init it depending on Kconfig.

Signed-off-by: Bob Liu <lliubbo@gmail.com>
---
 arch/arm/mach-omap2/board-omap3beagle.c |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
index 14f4224..fb82773 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -554,7 +554,13 @@ static struct omap_board_mux board_mux[] __initdata = {
 
 static struct omap_musb_board_data musb_board_data = {
 	.interface_type		= MUSB_INTERFACE_ULPI,
-	.mode			= MUSB_OTG,
+#if defined(CONFIG_USB_MUSB_OTG)
+	.mode		= MUSB_OTG,
+#elif defined(CONFIG_USB_MUSB_HDRC_HCD)
+	.mode		= MUSB_HOST,
+#elif defined(CONFIG_USB_GADGET_MUSB_HDRC)
+	.mode		= MUSB_PERIPHERAL,
+#endif
 	.power			= 100,
 };
 
-- 
1.6.3.3


             reply	other threads:[~2011-02-15  8:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-15  8:55 Bob Liu [this message]
2011-02-15 11:23 ` [PATCH] arm: omap3beagle: init musb default role by Kconfig Felipe Balbi
2011-02-16  2:07   ` Bob Liu
2011-02-16  8:05     ` Felipe Balbi
2011-02-16  8:49       ` Bob Liu
2011-02-16  9:02         ` Felipe Balbi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1297760100-7200-1-git-send-email-lliubbo@gmail.com \
    --to=lliubbo@gmail.com \
    --cc=adrian.hunter@nokia.com \
    --cc=archit@ti.com \
    --cc=balbi@ti.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=tony@atomide.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox