2005-04-17 05:20:36 +07:00
|
|
|
// include/asm-arm/mach-omap/usb.h
|
|
|
|
|
|
|
|
#ifndef __ASM_ARCH_OMAP_USB_H
|
|
|
|
#define __ASM_ARCH_OMAP_USB_H
|
|
|
|
|
2012-02-25 01:34:36 +07:00
|
|
|
#include <linux/io.h>
|
2012-07-16 20:31:09 +07:00
|
|
|
#include <linux/platform_device.h>
|
2010-02-18 05:09:30 +07:00
|
|
|
#include <linux/usb/musb.h>
|
2005-04-17 05:20:36 +07:00
|
|
|
|
2009-11-23 01:11:00 +07:00
|
|
|
#define OMAP3_HS_USB_PORTS 3
|
|
|
|
|
2011-03-01 21:38:16 +07:00
|
|
|
enum usbhs_omap_port_mode {
|
|
|
|
OMAP_USBHS_PORT_MODE_UNUSED,
|
|
|
|
OMAP_EHCI_PORT_MODE_PHY,
|
|
|
|
OMAP_EHCI_PORT_MODE_TLL,
|
|
|
|
OMAP_EHCI_PORT_MODE_HSIC,
|
2010-05-10 23:26:10 +07:00
|
|
|
OMAP_OHCI_PORT_MODE_PHY_6PIN_DATSE0,
|
|
|
|
OMAP_OHCI_PORT_MODE_PHY_6PIN_DPDM,
|
|
|
|
OMAP_OHCI_PORT_MODE_PHY_3PIN_DATSE0,
|
|
|
|
OMAP_OHCI_PORT_MODE_PHY_4PIN_DPDM,
|
|
|
|
OMAP_OHCI_PORT_MODE_TLL_6PIN_DATSE0,
|
|
|
|
OMAP_OHCI_PORT_MODE_TLL_6PIN_DPDM,
|
|
|
|
OMAP_OHCI_PORT_MODE_TLL_3PIN_DATSE0,
|
|
|
|
OMAP_OHCI_PORT_MODE_TLL_4PIN_DPDM,
|
|
|
|
OMAP_OHCI_PORT_MODE_TLL_2PIN_DATSE0,
|
2011-03-01 21:38:16 +07:00
|
|
|
OMAP_OHCI_PORT_MODE_TLL_2PIN_DPDM
|
2010-05-10 23:26:10 +07:00
|
|
|
};
|
|
|
|
|
2012-06-04 14:56:15 +07:00
|
|
|
#ifdef CONFIG_ARCH_OMAP2PLUS
|
|
|
|
|
2011-03-01 21:38:16 +07:00
|
|
|
struct ehci_hcd_omap_platform_data {
|
|
|
|
enum usbhs_omap_port_mode port_mode[OMAP3_HS_USB_PORTS];
|
|
|
|
int reset_gpio_port[OMAP3_HS_USB_PORTS];
|
|
|
|
struct regulator *regulator[OMAP3_HS_USB_PORTS];
|
|
|
|
unsigned phy_reset:1;
|
|
|
|
};
|
2010-05-10 23:26:10 +07:00
|
|
|
|
2011-03-01 21:38:16 +07:00
|
|
|
struct ohci_hcd_omap_platform_data {
|
|
|
|
enum usbhs_omap_port_mode port_mode[OMAP3_HS_USB_PORTS];
|
2010-05-10 23:26:10 +07:00
|
|
|
unsigned es2_compatibility:1;
|
|
|
|
};
|
|
|
|
|
2011-03-01 21:38:16 +07:00
|
|
|
struct usbhs_omap_platform_data {
|
|
|
|
enum usbhs_omap_port_mode port_mode[OMAP3_HS_USB_PORTS];
|
|
|
|
|
|
|
|
struct ehci_hcd_omap_platform_data *ehci_data;
|
|
|
|
struct ohci_hcd_omap_platform_data *ohci_data;
|
|
|
|
};
|
2012-07-16 20:31:08 +07:00
|
|
|
|
|
|
|
struct usbtll_omap_platform_data {
|
|
|
|
enum usbhs_omap_port_mode port_mode[OMAP3_HS_USB_PORTS];
|
|
|
|
};
|
2005-04-17 05:20:36 +07:00
|
|
|
/*-------------------------------------------------------------------------*/
|
|
|
|
|
2010-02-18 05:09:30 +07:00
|
|
|
struct omap_musb_board_data {
|
|
|
|
u8 interface_type;
|
|
|
|
u8 mode;
|
2010-03-25 18:14:23 +07:00
|
|
|
u16 power;
|
2010-03-25 18:25:27 +07:00
|
|
|
unsigned extvbus:1;
|
2010-12-07 20:27:45 +07:00
|
|
|
void (*set_phy_power)(u8 on);
|
|
|
|
void (*clear_irq)(void);
|
|
|
|
void (*set_mode)(u8 mode);
|
|
|
|
void (*reset)(void);
|
2010-02-18 05:09:30 +07:00
|
|
|
};
|
|
|
|
|
|
|
|
enum musb_interface {MUSB_INTERFACE_ULPI, MUSB_INTERFACE_UTMI};
|
|
|
|
|
2012-07-16 20:31:08 +07:00
|
|
|
extern int omap_tll_enable(void);
|
|
|
|
extern int omap_tll_disable(void);
|
2011-03-01 21:38:18 +07:00
|
|
|
|
2010-07-05 20:31:30 +07:00
|
|
|
#endif
|
|
|
|
|
2005-04-17 05:20:36 +07:00
|
|
|
#endif /* __ASM_ARCH_OMAP_USB_H */
|