The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 1 | /**************************************************************************** |
| 2 | **************************************************************************** |
| 3 | *** |
| 4 | *** This header was automatically generated from a Linux kernel header |
| 5 | *** of the same name, to make information necessary for userspace to |
| 6 | *** call into the kernel available to libc. It contains only constants, |
| 7 | *** structures, and macros generated from the original header, and thus, |
| 8 | *** contains no copyrightable information. |
| 9 | *** |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 10 | *** To edit the content of this header, modify the corresponding |
| 11 | *** source file (e.g. under external/kernel-headers/original/) then |
| 12 | *** run bionic/libc/kernel/tools/update_all.py |
| 13 | *** |
| 14 | *** Any manual change here will be lost the next time this script will |
| 15 | *** be run. You've been warned! |
| 16 | *** |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 17 | **************************************************************************** |
| 18 | ****************************************************************************/ |
| 19 | #ifndef __ASM_ARCH_OMAP_MCBSP_H |
| 20 | #define __ASM_ARCH_OMAP_MCBSP_H |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 21 | #include <asm/hardware.h> |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 22 | #define OMAP730_MCBSP1_BASE 0xfffb1000 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 23 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 24 | #define OMAP730_MCBSP2_BASE 0xfffb1800 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 25 | #define OMAP1510_MCBSP1_BASE 0xe1011800 |
| 26 | #define OMAP1510_MCBSP2_BASE 0xfffb1000 |
| 27 | #define OMAP1510_MCBSP3_BASE 0xe1017000 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 28 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 29 | #define OMAP1610_MCBSP1_BASE 0xe1011800 |
| 30 | #define OMAP1610_MCBSP2_BASE 0xfffb1000 |
| 31 | #define OMAP1610_MCBSP3_BASE 0xe1017000 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 32 | #define OMAP24XX_MCBSP1_BASE 0x48074000 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 33 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 34 | #define OMAP24XX_MCBSP2_BASE 0x48076000 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 35 | #define OMAP_MCBSP_READ(base, reg) __raw_readw((base) + OMAP_MCBSP_REG_##reg) |
| 36 | #define OMAP_MCBSP_WRITE(base, reg, val) __raw_writew((val), (base) + OMAP_MCBSP_REG_##reg) |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 37 | #define RRST 0x0001 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 38 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 39 | #define RRDY 0x0002 |
| 40 | #define RFULL 0x0004 |
| 41 | #define RSYNC_ERR 0x0008 |
| 42 | #define RINTM(value) ((value)<<4) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 43 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 44 | #define ABIS 0x0040 |
| 45 | #define DXENA 0x0080 |
| 46 | #define CLKSTP(value) ((value)<<11) |
| 47 | #define RJUST(value) ((value)<<13) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 48 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 49 | #define DLB 0x8000 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 50 | #define XRST 0x0001 |
| 51 | #define XRDY 0x0002 |
| 52 | #define XEMPTY 0x0004 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 53 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 54 | #define XSYNC_ERR 0x0008 |
| 55 | #define XINTM(value) ((value)<<4) |
| 56 | #define GRST 0x0040 |
| 57 | #define FRST 0x0080 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 58 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 59 | #define SOFT 0x0100 |
| 60 | #define FREE 0x0200 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 61 | #define CLKRP 0x0001 |
| 62 | #define CLKXP 0x0002 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 63 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 64 | #define FSRP 0x0004 |
| 65 | #define FSXP 0x0008 |
| 66 | #define DR_STAT 0x0010 |
| 67 | #define DX_STAT 0x0020 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 68 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 69 | #define CLKS_STAT 0x0040 |
| 70 | #define SCLKME 0x0080 |
| 71 | #define CLKRM 0x0100 |
| 72 | #define CLKXM 0x0200 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 73 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 74 | #define FSRM 0x0400 |
| 75 | #define FSXM 0x0800 |
| 76 | #define RIOEN 0x1000 |
| 77 | #define XIOEN 0x2000 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 78 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 79 | #define IDLE_EN 0x4000 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 80 | #define RWDLEN1(value) ((value)<<5) |
| 81 | #define RFRLEN1(value) ((value)<<8) |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 82 | #define XWDLEN1(value) ((value)<<5) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 83 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 84 | #define XFRLEN1(value) ((value)<<8) |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 85 | #define RDATDLY(value) (value) |
| 86 | #define RFIG 0x0004 |
| 87 | #define RCOMPAND(value) ((value)<<3) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 88 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 89 | #define RWDLEN2(value) ((value)<<5) |
| 90 | #define RFRLEN2(value) ((value)<<8) |
| 91 | #define RPHASE 0x8000 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 92 | #define XDATDLY(value) (value) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 93 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 94 | #define XFIG 0x0004 |
| 95 | #define XCOMPAND(value) ((value)<<3) |
| 96 | #define XWDLEN2(value) ((value)<<5) |
| 97 | #define XFRLEN2(value) ((value)<<8) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 98 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 99 | #define XPHASE 0x8000 |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 100 | #define CLKGDV(value) (value) |
| 101 | #define FWID(value) ((value)<<8) |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 102 | #define FPER(value) (value) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 103 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 104 | #define FSGM 0x1000 |
| 105 | #define CLKSM 0x2000 |
| 106 | #define CLKSP 0x4000 |
| 107 | #define GSYNC 0x8000 |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 108 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 109 | #define RMCM 0x0001 |
| 110 | #define RCBLK(value) ((value)<<2) |
| 111 | #define RPABLK(value) ((value)<<5) |
| 112 | #define RPBBLK(value) ((value)<<7) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 113 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 114 | #define XMCM(value) (value) |
| 115 | #define XCBLK(value) ((value)<<2) |
| 116 | #define XPABLK(value) ((value)<<5) |
| 117 | #define XPBBLK(value) ((value)<<7) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 118 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 119 | struct omap_mcbsp_reg_cfg { |
| 120 | u16 spcr2; |
| 121 | u16 spcr1; |
| 122 | u16 rcr2; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 123 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 124 | u16 rcr1; |
| 125 | u16 xcr2; |
| 126 | u16 xcr1; |
| 127 | u16 srgr2; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 128 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 129 | u16 srgr1; |
| 130 | u16 mcr2; |
| 131 | u16 mcr1; |
| 132 | u16 pcr0; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 133 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 134 | u16 rcerc; |
| 135 | u16 rcerd; |
| 136 | u16 xcerc; |
| 137 | u16 xcerd; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 138 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 139 | u16 rcere; |
| 140 | u16 rcerf; |
| 141 | u16 xcere; |
| 142 | u16 xcerf; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 143 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 144 | u16 rcerg; |
| 145 | u16 rcerh; |
| 146 | u16 xcerg; |
| 147 | u16 xcerh; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 148 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 149 | }; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 150 | typedef enum { |
| 151 | OMAP_MCBSP1 = 0, |
| 152 | OMAP_MCBSP2, |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 153 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 154 | OMAP_MCBSP3, |
| 155 | } omap_mcbsp_id; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 156 | typedef int __bitwise omap_mcbsp_io_type_t; |
| 157 | #define OMAP_MCBSP_IRQ_IO ((__force omap_mcbsp_io_type_t) 1) |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 158 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 159 | #define OMAP_MCBSP_POLL_IO ((__force omap_mcbsp_io_type_t) 2) |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 160 | typedef enum { |
| 161 | OMAP_MCBSP_WORD_8 = 0, |
| 162 | OMAP_MCBSP_WORD_12, |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 163 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 164 | OMAP_MCBSP_WORD_16, |
| 165 | OMAP_MCBSP_WORD_20, |
| 166 | OMAP_MCBSP_WORD_24, |
| 167 | OMAP_MCBSP_WORD_32, |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 168 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 169 | } omap_mcbsp_word_length; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 170 | typedef enum { |
| 171 | OMAP_MCBSP_CLK_RISING = 0, |
| 172 | OMAP_MCBSP_CLK_FALLING, |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 173 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 174 | } omap_mcbsp_clk_polarity; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 175 | typedef enum { |
| 176 | OMAP_MCBSP_FS_ACTIVE_HIGH = 0, |
| 177 | OMAP_MCBSP_FS_ACTIVE_LOW, |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 178 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 179 | } omap_mcbsp_fs_polarity; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 180 | typedef enum { |
| 181 | OMAP_MCBSP_CLK_STP_MODE_NO_DELAY = 0, |
| 182 | OMAP_MCBSP_CLK_STP_MODE_DELAY, |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 183 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 184 | } omap_mcbsp_clk_stp_mode; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 185 | typedef enum { |
| 186 | OMAP_MCBSP_SPI_MASTER = 0, |
| 187 | OMAP_MCBSP_SPI_SLAVE, |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 188 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 189 | } omap_mcbsp_spi_mode; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 190 | struct omap_mcbsp_spi_cfg { |
| 191 | omap_mcbsp_spi_mode spi_mode; |
| 192 | omap_mcbsp_clk_polarity rx_clock_polarity; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 193 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 194 | omap_mcbsp_clk_polarity tx_clock_polarity; |
| 195 | omap_mcbsp_fs_polarity fsx_polarity; |
| 196 | u8 clk_div; |
| 197 | omap_mcbsp_clk_stp_mode clk_stp_mode; |
Ben Cheng | 654325d | 2012-03-07 21:13:49 -0800 | [diff] [blame^] | 198 | /* WARNING: DO NOT EDIT, AUTO-GENERATED CODE - SEE TOP FOR INSTRUCTIONS */ |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 199 | omap_mcbsp_word_length word_length; |
| 200 | }; |
The Android Open Source Project | 1dc9e47 | 2009-03-03 19:28:35 -0800 | [diff] [blame] | 201 | #endif |