public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] MUSB: Set INDEX register to 0 before accessing CONFIGDATA
@ 2008-09-04  7:23 Gadiyar, Anand
       [not found] ` <5A47E75E594F054BAF48C5E4FC4B92AB02C418D1B1-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
  0 siblings, 1 reply; 6+ messages in thread
From: Gadiyar, Anand @ 2008-09-04  7:23 UTC (permalink / raw)
  To: linux-usb-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
  Cc: linux-omap-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Gupta, Ajay Kumar

From: Anand Gadiyar <gadiyar-l0cyMroinI0@public.gmane.org>

The Index register needs to be zero to access CONFIGDATA.
musb_ep_select()will not set the MUSB_INDEX register unless INDEXED
mode addressing is used. This change will set the register correctly
in INDEXED as well as FLAT mode.

Signed-off-by: Anand Gadiyar <gadiyar-l0cyMroinI0@public.gmane.org>
CC: Ajay Kumar Gupta <ajay.gupta-l0cyMroinI0@public.gmane.org>
---
diff --git a/drivers/usb/musb/musb_core.c b/drivers/usb/musb/musb_core.c
index b398776..6c4da2f 100644
--- a/drivers/usb/musb/musb_core.c
+++ b/drivers/usb/musb/musb_core.c
@@ -1334,7 +1334,7 @@ static int __init musb_core_init(u16 musb_type, struct musb *musb)
 	int		i;
 
 	/* log core options (read using indexed model) */
-	musb_ep_select(mbase, 0);
+	musb_writeb(mbase, MUSB_INDEX, 0);
 	reg = musb_readb(mbase, 0x10 + MUSB_CONFIGDATA);
 
 	strcpy(aInfo, (reg & MUSB_CONFIGDATA_UTMIDW) ? "UTMI-16" : "UTMI-8");--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2008-09-12 17:39 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-04  7:23 [PATCH] MUSB: Set INDEX register to 0 before accessing CONFIGDATA Gadiyar, Anand
     [not found] ` <5A47E75E594F054BAF48C5E4FC4B92AB02C418D1B1-/tLxBxkBPtCIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2008-09-07  5:04   ` David Brownell
2008-09-08  3:12     ` Bryan Wu
     [not found]       ` <386072610809072012wcf053a6j37c238b82667c23a-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2008-09-10 19:01         ` Felipe Balbi
2008-09-11  3:35           ` Bryan Wu
2008-09-12 17:34       ` David Brownell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox