From: Bora Sahin <bora.sahin@ttnet.net.tr>
To: "Jordan Crouse" <jordan.crouse@amd.com>
Cc: linux-mips@linux-mips.org
Subject: Re: ALCHEMY: AU1200 USB Host Controller (OHCI/EHCI)
Date: Mon, 12 Dec 2005 12:51:25 +0200 [thread overview]
Message-ID: <965523406.20051212125125@ttnet.net.tr> (raw)
In-Reply-To: <20051208210042.GB17458@cosmic.amd.com>
Hi,
Thursday, December 8, 2005, 11:00:42 PM, you wrote:
Jordan> Ok, here we go. I give you the OHCI/EHCI host controller support for
Jordan> the Alchemy AU1200 processor. I'm sending this up, partly because I
Jordan> have it ready to go, but also because it seems that enough folks are
Jordan> getting their hands on AU1200 parts to make this a hot topic.
Especially, it's high time to me... :-)
Jordan> Special thanks to Pete Popov and his merry band of kernel hackers for
Jordan> paving the way by pushing to seperate EHCI and PCI in the USB subsystem.
Me to...
I have a few comments related to the OHCI part of it...
diff --git a/drivers/usb/host/ohci-au1xxx.c b/drivers/usb/host/ohci-au1xxx.c
+#else /* Au1200 */
+
+#define USB_HOST_CONFIG (USB_MSR_BASE + USB_MSR_MCFG)
+#define USB_MCFG_PFEN (1<<31)
+#define USB_MCFG_RDCOMB (1<<30)
+#define USB_MCFG_SSDEN (1<<23)
+#define USB_MCFG_OHCCLKEN (1<<16)
+#define USB_MCFG_UCAM (1<<7)
+#define USB_MCFG_OBMEN (1<<1)
+#define USB_MCFG_OMEMEN (1<<0)
Maybe, the place where to put those defines is
include/asm-mips/mach-au1x00/au1000.h? Because there are some similar defines in
that file, actually shift values. For consistency, are they used?..
+#define USBH_ENABLE_CE USB_MCFG_OHCCLKEN
+#ifdef CONFIG_DMA_COHERENT
+#define USBH_ENABLE_INIT (USB_MCFG_OHCCLKEN \
+ | USB_MCFG_PFEN | USB_MCFG_RDCOMB \
+ | USB_MCFG_SSDEN | USB_MCFG_UCAM \
Aha! What I was lacking in my patch was USB_MCFG_UCAM! For test, I added it to
my patch, and it worked! Reserved in the doc. So do USB_MCFG_PFEN and
USB_MCFG_RDCOMB. What's the meaning of that fields?
+#else /* Au1200 */
+
+ /* write HW defaults again in case Yamon cleared them */
+ if (au_readl(USB_HOST_CONFIG) == 0) {
+ au_writel(0x00d02000, USB_HOST_CONFIG);
+ au_readl(USB_HOST_CONFIG);
+ udelay(1000);
+ }
+ au_writel(USBH_ENABLE_CE | au_readl(USB_HOST_CONFIG), USB_HOST_CONFIG);
+ au_readl(USB_HOST_CONFIG);
+ udelay(1000);
+ au_writel(USBH_ENABLE_INIT | au_readl(USB_HOST_CONFIG), USB_HOST_CONFIG);
+ au_readl(USB_HOST_CONFIG);
+ udelay(1000);
Are au_readl() and udelay() necessary between the two au_writel()? Just for
curiosity, I tried it without them and as it seems, it worked!
--
Bora SAHIN
next prev parent reply other threads:[~2005-12-12 10:52 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-08 21:00 ALCHEMY: AU1200 USB Host Controller (OHCI/EHCI) Jordan Crouse
2005-12-10 5:13 ` [linux-usb-devel] " David Brownell
2005-12-10 6:42 ` Pete Popov
2005-12-12 10:51 ` Bora Sahin [this message]
2006-01-03 14:25 ` Matej Kupljen
2006-01-03 15:54 ` Jordan Crouse
2006-01-03 21:45 ` Matej Kupljen
2006-01-04 7:18 ` Matej Kupljen
2006-01-04 12:50 ` Sathesh Babu Edara
2006-01-04 12:50 ` Sathesh Babu Edara
2006-01-04 13:06 ` Kevin D. Kissell
2006-01-09 4:54 ` LL and SC instruction simulation Sathesh Babu Edara
2006-01-09 4:54 ` Sathesh Babu Edara
2006-01-09 7:43 ` Sathesh Babu Edara
2006-01-09 7:43 ` RE: Sathesh Babu Edara
2006-01-09 7:49 ` LL and SC instruction simulation Sathesh Babu Edara
2006-01-09 7:49 ` Sathesh Babu Edara
2006-01-09 14:54 ` Ralf Baechle
2006-01-09 15:17 ` Kevin D. Kissell
2006-01-09 15:17 ` Kevin D. Kissell
2006-01-09 15:21 ` Ralf Baechle
2006-01-09 15:30 ` Ralf Baechle
2006-01-09 15:47 ` Kevin D. Kissell
2006-01-09 15:47 ` Kevin D. Kissell
2006-01-09 15:51 ` Ralf Baechle
2006-01-09 9:00 ` Kevin D. Kissell
2006-01-09 9:00 ` Re: Kevin D. Kissell
2006-01-09 21:23 ` [processor frequency] Wolfgang Denk
2006-01-09 21:53 ` Kevin D. Kissell
2006-01-09 23:01 ` Wolfgang Denk
2006-01-04 12:12 ` ALCHEMY: AU1200 USB Host Controller (OHCI/EHCI) Matej Kupljen
2006-01-04 12:32 ` Matthias Lenk
2006-01-04 13:07 ` Matej Kupljen
2006-01-04 13:54 ` bora.sahin
2006-01-04 14:17 ` Matej Kupljen
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=965523406.20051212125125@ttnet.net.tr \
--to=bora.sahin@ttnet.net.tr \
--cc=jordan.crouse@amd.com \
--cc=linux-mips@linux-mips.org \
/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