From: eric.y.miao@gmail.com (Eric Miao)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/5] usb/otg/ulpi: extend the generic ulpi driver.
Date: Sat, 12 Jun 2010 17:35:24 +0800 [thread overview]
Message-ID: <AANLkTimHDBI0grgNrcvZ-BWS9kd0z4lFqEgVoyM4ysVJ@mail.gmail.com> (raw)
In-Reply-To: <1275464450-23003-2-git-send-email-grinberg@compulab.co.il>
> +/* ULPI Function Control Register bits */
> +#define ULPI_FC_HS ? ? 0 ? ? ? ? ? ? ? /* Enable HS tcvr */
> +#define ULPI_FC_FS ? ? (0x1 << 0) ? ? ?/* Enable FS tcvr */
> +#define ULPI_FC_LS ? ? (0x2 << 0) ? ? ?/* Enable LS tcvr */
> +#define ULPI_FC_FS_LS ?(0x3 << 0) ? ? ?/* Enable FS tcvr for LS packets */
> +#define ULPI_FC_TRM_SEL ? ? ? ?(0x1 << 2) ? ? ?/* Internal pullup and HS termination */
> +#define ULPI_FC_NODRV ?(0x1 << 3) ? ? ?/* Non-Driving Operation */
> +#define ULPI_FC_NONRZI (0x1 << 4) ? ? ?/* Disable bit-stuff and NRZI encode */
> +#define ULPI_FC_RESET ?(0x1 << 5) ? ? ?/* Reset the UTMI core */
> +#define ULPI_FC_DEFAULT ? ? ? ?0x41 ? ? ? ? ? ?/* Function Control Register Default */
> +
> +
> +/* ULPI Interface Register bits */
> +#define ULPI_IC_6PIN ? (1 << 0) ? ? ? ?/* XCVR 6 serial pin mode */
> +#define ULPI_IC_3PIN ? (1 << 1) ? ? ? ?/* XCVR 3 serial pin mode */
> +#define ULPI_IC_CARKIT (1 << 2) ? ? ? ?/* Carkit mode */
> +#define ULPI_IC_CLKSPND ? ? ? ?(1 << 3) ? ? ? ?/* Active low clock suspend */
> +#define ULPI_IC_AUTORES ? ? ? ?(1 << 4) ? ? ? ?/* PHY auto transmit resume signal */
> +#define ULPI_IC_VBUSINV ? ? ? ?(1 << 5) ? ? ? ?/* Invert the external VBUS indicator */
> +#define ULPI_IC_INDPT ?(1 << 6) ? ? ? ?/* Indicator Pass Through */
> +#define ULPI_IC_DISPRT (1 << 7) ? ? ? ?/* Interface Protect Disable */
> +#define ULPI_IC_DEFAULT ? ? ? ?0x0 ? ? ? ? ? ? /* Interface Control Register Default */
> +
> ?struct otg_transceiver *otg_ulpi_create(struct otg_io_access_ops *ops,
> - ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? unsigned int flags);
> + ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? u8 fc_flags, u8 ic_flags, u8 otg_flags);
>
Just one comment about the API, I might not know all the detail of these two
FC/IC registers, but maybe it can be even better:
1. separate flags definition from the FC/IC register bits, i.e. sometimes not
all the register bits will be used, and some times a meaningful flag name is
better (though the flag definition can be encoded properly to simplify the
algorithm to map into the actual register bits)
2. extend the original 'flags' variable and bits for the above definitions, so
we can keep the API unchanged.
next prev parent reply other threads:[~2010-06-12 9:35 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-02 7:40 [PATCH 0/5] Enable pxa310 usb otg port host mode Igor Grinberg
2010-06-02 7:40 ` [PATCH 1/5] usb/otg/ulpi: extend the generic ulpi driver Igor Grinberg
2010-06-02 7:40 ` [PATCH 2/5] usb/otg/ulpi: add support for SMSC USB3319 ulpi phy Igor Grinberg
2010-06-02 7:40 ` [PATCH 3/5] [ARM] pxa: add PXA310 specific ULPI implementation Igor Grinberg
2010-06-02 7:40 ` [PATCH 4/5] [ARM] usb/host/ohci-pxa27x: make PXA310 USB OTG port work in host mode Igor Grinberg
2010-06-02 7:40 ` [PATCH 5/5] [ARM] pxa/cm-x300: enable USB host port 2 on CM-X300 with PXA310 cpu Igor Grinberg
2010-06-12 11:48 ` [PATCH 4/5] [ARM] usb/host/ohci-pxa27x: make PXA310 USB OTG port work in host mode Eric Miao
2010-06-12 14:24 ` David Brownell
2010-06-13 6:57 ` Mike Rapoport
2010-06-13 7:04 ` Eric Miao
2010-06-13 7:06 ` Mike Rapoport
2010-06-12 9:35 ` Eric Miao [this message]
2010-06-12 17:34 ` [PATCH 1/5] usb/otg/ulpi: extend the generic ulpi driver David Brownell
2010-06-15 14:47 ` Igor Grinberg
2010-08-13 10:21 ` [PATCH] ARM: imx: fix build failure concerning otg/ulpi Uwe Kleine-König
2010-08-13 10:54 ` Sergei Shtylyov
2010-08-13 12:06 ` [PATCH v2] " Uwe Kleine-König
2010-08-15 6:05 ` Igor Grinberg
2010-08-16 4:53 ` Uwe Kleine-König
2010-08-16 6:09 ` Igor Grinberg
2010-08-22 7:24 ` Igor Grinberg
2010-08-22 17:10 ` Greg KH
2010-06-02 8:29 ` [PATCH 0/5] Enable pxa310 usb otg port host mode Eric Miao
2010-06-06 6:15 ` Igor Grinberg
2010-06-09 11:49 ` Mike Rapoport
2010-06-09 12:43 ` Eric Miao
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=AANLkTimHDBI0grgNrcvZ-BWS9kd0z4lFqEgVoyM4ysVJ@mail.gmail.com \
--to=eric.y.miao@gmail.com \
--cc=linux-arm-kernel@lists.infradead.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;
as well as URLs for NNTP newsgroup(s).