diff options
author | Minkyu Kang <mk7.kang@samsung.com> | 2010-07-06 17:29:44 +0900 |
---|---|---|
committer | Minkyu Kang <mk7.kang@samsung.com> | 2010-07-06 17:29:44 +0900 |
commit | 2271d3ddccfbd4a7640121669ff9b013b1fea361 (patch) | |
tree | 400f22f0a12ff0ae6c472bed6ac648befc1744a2 /drivers/usb/host/ohci.h | |
parent | 25ae8aeb54a6ca89ba1fd11c00865b8fed9348b4 (diff) | |
parent | 54841ab50c20d6fa6c9cc3eb826989da3a22d934 (diff) | |
download | u-boot-imx-2271d3ddccfbd4a7640121669ff9b013b1fea361.zip u-boot-imx-2271d3ddccfbd4a7640121669ff9b013b1fea361.tar.gz u-boot-imx-2271d3ddccfbd4a7640121669ff9b013b1fea361.tar.bz2 |
Merge branch 'master' of git://git.denx.de/u-boot
Diffstat (limited to 'drivers/usb/host/ohci.h')
-rw-r--r-- | drivers/usb/host/ohci.h | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/usb/host/ohci.h b/drivers/usb/host/ohci.h index 79aa79d..d977e8f 100644 --- a/drivers/usb/host/ohci.h +++ b/drivers/usb/host/ohci.h @@ -7,6 +7,17 @@ * usb-ohci.h */ +/* + * e.g. PCI controllers need this + */ +#ifdef CONFIG_SYS_OHCI_SWAP_REG_ACCESS +# define ohci_readl(a) __swap_32(*((volatile u32 *)(a))) +# define ohci_writel(a, b) (*((volatile u32 *)(b)) = __swap_32((volatile u32)a)) +#else +# define ohci_readl(a) (*((volatile u32 *)(a))) +# define ohci_writel(a, b) (*((volatile u32 *)(b)) = ((volatile u32)a)) +#endif /* CONFIG_SYS_OHCI_SWAP_REG_ACCESS */ + /* functions for doing board or CPU specific setup/cleanup */ extern int usb_board_init(void); extern int usb_board_stop(void); @@ -196,8 +207,8 @@ struct ohci_hcca { /* * This is the structure of the OHCI controller's memory mapped I/O - * region. This is Memory Mapped I/O. You must use the readl() and - * writel() macros defined in asm/io.h to access these!! + * region. This is Memory Mapped I/O. You must use the ohci_readl() and + * ohci_writel() macros defined in this file to access these!! */ struct ohci_regs { /* control and status registers */ |