diff options
Diffstat (limited to 'arch/arm/plat-omap')
-rw-r--r-- | arch/arm/plat-omap/dma.c | 13 | ||||
-rw-r--r-- | arch/arm/plat-omap/gpio.c | 3 | ||||
-rw-r--r-- | arch/arm/plat-omap/include/mach/aic23.h | 116 | ||||
-rw-r--r-- | arch/arm/plat-omap/include/mach/board-h3.h | 4 | ||||
-rw-r--r-- | arch/arm/plat-omap/include/mach/gpio.h | 10 | ||||
-rw-r--r-- | arch/arm/plat-omap/include/mach/mcbsp.h | 11 | ||||
-rw-r--r-- | arch/arm/plat-omap/mcbsp.c | 4 | ||||
-rw-r--r-- | arch/arm/plat-omap/usb.c | 14 |
8 files changed, 26 insertions, 149 deletions
diff --git a/arch/arm/plat-omap/dma.c b/arch/arm/plat-omap/dma.c index 692d2b495af3..e77373c39f8c 100644 --- a/arch/arm/plat-omap/dma.c +++ b/arch/arm/plat-omap/dma.c | |||
@@ -278,14 +278,11 @@ void omap_set_dma_transfer_params(int lch, int data_type, int elem_count, | |||
278 | u32 val; | 278 | u32 val; |
279 | 279 | ||
280 | val = dma_read(CCR(lch)); | 280 | val = dma_read(CCR(lch)); |
281 | val &= ~(3 << 19); | 281 | |
282 | if (dma_trigger > 63) | 282 | /* DMA_SYNCHRO_CONTROL_UPPER depends on the channel number */ |
283 | val |= 1 << 20; | 283 | val &= ~((3 << 19) | 0x1f); |
284 | if (dma_trigger > 31) | 284 | val |= (dma_trigger & ~0x1f) << 14; |
285 | val |= 1 << 19; | 285 | val |= dma_trigger & 0x1f; |
286 | |||
287 | val &= ~(0x1f); | ||
288 | val |= (dma_trigger & 0x1f); | ||
289 | 286 | ||
290 | if (sync_mode & OMAP_DMA_SYNC_FRAME) | 287 | if (sync_mode & OMAP_DMA_SYNC_FRAME) |
291 | val |= 1 << 5; | 288 | val |= 1 << 5; |
diff --git a/arch/arm/plat-omap/gpio.c b/arch/arm/plat-omap/gpio.c index 07b6968a7d16..f856a90b264e 100644 --- a/arch/arm/plat-omap/gpio.c +++ b/arch/arm/plat-omap/gpio.c | |||
@@ -1789,6 +1789,8 @@ static int dbg_gpio_show(struct seq_file *s, void *unused) | |||
1789 | /* FIXME for at least omap2, show pullup/pulldown state */ | 1789 | /* FIXME for at least omap2, show pullup/pulldown state */ |
1790 | 1790 | ||
1791 | irqstat = irq_desc[irq].status; | 1791 | irqstat = irq_desc[irq].status; |
1792 | #if defined(CONFIG_ARCH_OMAP16XX) || defined(CONFIG_ARCH_OMAP24XX) || \ | ||
1793 | defined(CONFIG_ARCH_OMAP34XX) | ||
1792 | if (is_in && ((bank->suspend_wakeup & mask) | 1794 | if (is_in && ((bank->suspend_wakeup & mask) |
1793 | || irqstat & IRQ_TYPE_SENSE_MASK)) { | 1795 | || irqstat & IRQ_TYPE_SENSE_MASK)) { |
1794 | char *trigger = NULL; | 1796 | char *trigger = NULL; |
@@ -1818,6 +1820,7 @@ static int dbg_gpio_show(struct seq_file *s, void *unused) | |||
1818 | (bank->suspend_wakeup & mask) | 1820 | (bank->suspend_wakeup & mask) |
1819 | ? " wakeup" : ""); | 1821 | ? " wakeup" : ""); |
1820 | } | 1822 | } |
1823 | #endif | ||
1821 | seq_printf(s, "\n"); | 1824 | seq_printf(s, "\n"); |
1822 | } | 1825 | } |
1823 | 1826 | ||
diff --git a/arch/arm/plat-omap/include/mach/aic23.h b/arch/arm/plat-omap/include/mach/aic23.h deleted file mode 100644 index 5ccedac77526..000000000000 --- a/arch/arm/plat-omap/include/mach/aic23.h +++ /dev/null | |||
@@ -1,116 +0,0 @@ | |||
1 | /* | ||
2 | * arch/arm/plat-omap/include/mach/aic23.h | ||
3 | * | ||
4 | * Hardware definitions for TI TLV320AIC23 audio codec | ||
5 | * | ||
6 | * Copyright (C) 2002 RidgeRun, Inc. | ||
7 | * Author: Steve Johnson | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify it | ||
10 | * under the terms of the GNU General Public License as published by the | ||
11 | * Free Software Foundation; either version 2 of the License, or (at your | ||
12 | * option) any later version. | ||
13 | * | ||
14 | * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED | ||
15 | * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF | ||
16 | * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN | ||
17 | * NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, | ||
18 | * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT | ||
19 | * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF | ||
20 | * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON | ||
21 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
22 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | ||
23 | * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
24 | * | ||
25 | * You should have received a copy of the GNU General Public License along | ||
26 | * with this program; if not, write to the Free Software Foundation, Inc., | ||
27 | * 675 Mass Ave, Cambridge, MA 02139, USA. | ||
28 | */ | ||
29 | |||
30 | #ifndef __ASM_ARCH_AIC23_H | ||
31 | #define __ASM_ARCH_AIC23_H | ||
32 | |||
33 | // Codec TLV320AIC23 | ||
34 | #define LEFT_LINE_VOLUME_ADDR 0x00 | ||
35 | #define RIGHT_LINE_VOLUME_ADDR 0x01 | ||
36 | #define LEFT_CHANNEL_VOLUME_ADDR 0x02 | ||
37 | #define RIGHT_CHANNEL_VOLUME_ADDR 0x03 | ||
38 | #define ANALOG_AUDIO_CONTROL_ADDR 0x04 | ||
39 | #define DIGITAL_AUDIO_CONTROL_ADDR 0x05 | ||
40 | #define POWER_DOWN_CONTROL_ADDR 0x06 | ||
41 | #define DIGITAL_AUDIO_FORMAT_ADDR 0x07 | ||
42 | #define SAMPLE_RATE_CONTROL_ADDR 0x08 | ||
43 | #define DIGITAL_INTERFACE_ACT_ADDR 0x09 | ||
44 | #define RESET_CONTROL_ADDR 0x0F | ||
45 | |||
46 | // Left (right) line input volume control register | ||
47 | #define LRS_ENABLED 0x0100 | ||
48 | #define LIM_MUTED 0x0080 | ||
49 | #define LIV_DEFAULT 0x0017 | ||
50 | #define LIV_MAX 0x001f | ||
51 | #define LIV_MIN 0x0000 | ||
52 | |||
53 | // Left (right) channel headphone volume control register | ||
54 | #define LZC_ON 0x0080 | ||
55 | #define LHV_DEFAULT 0x0079 | ||
56 | #define LHV_MAX 0x007f | ||
57 | #define LHV_MIN 0x0000 | ||
58 | |||
59 | // Analog audio path control register | ||
60 | #define STA_REG(x) ((x)<<6) | ||
61 | #define STE_ENABLED 0x0020 | ||
62 | #define DAC_SELECTED 0x0010 | ||
63 | #define BYPASS_ON 0x0008 | ||
64 | #define INSEL_MIC 0x0004 | ||
65 | #define MICM_MUTED 0x0002 | ||
66 | #define MICB_20DB 0x0001 | ||
67 | |||
68 | // Digital audio path control register | ||
69 | #define DACM_MUTE 0x0008 | ||
70 | #define DEEMP_32K 0x0002 | ||
71 | #define DEEMP_44K 0x0004 | ||
72 | #define DEEMP_48K 0x0006 | ||
73 | #define ADCHP_ON 0x0001 | ||
74 | |||
75 | // Power control down register | ||
76 | #define DEVICE_POWER_OFF 0x0080 | ||
77 | #define CLK_OFF 0x0040 | ||
78 | #define OSC_OFF 0x0020 | ||
79 | #define OUT_OFF 0x0010 | ||
80 | #define DAC_OFF 0x0008 | ||
81 | #define ADC_OFF 0x0004 | ||
82 | #define MIC_OFF 0x0002 | ||
83 | #define LINE_OFF 0x0001 | ||
84 | |||
85 | // Digital audio interface register | ||
86 | #define MS_MASTER 0x0040 | ||
87 | #define LRSWAP_ON 0x0020 | ||
88 | #define LRP_ON 0x0010 | ||
89 | #define IWL_16 0x0000 | ||
90 | #define IWL_20 0x0004 | ||
91 | #define IWL_24 0x0008 | ||
92 | #define IWL_32 0x000C | ||
93 | #define FOR_I2S 0x0002 | ||
94 | #define FOR_DSP 0x0003 | ||
95 | |||
96 | // Sample rate control register | ||
97 | #define CLKOUT_HALF 0x0080 | ||
98 | #define CLKIN_HALF 0x0040 | ||
99 | #define BOSR_384fs 0x0002 // BOSR_272fs when in USB mode | ||
100 | #define USB_CLK_ON 0x0001 | ||
101 | #define SR_MASK 0xf | ||
102 | #define CLKOUT_SHIFT 7 | ||
103 | #define CLKIN_SHIFT 6 | ||
104 | #define SR_SHIFT 2 | ||
105 | #define BOSR_SHIFT 1 | ||
106 | |||
107 | // Digital interface register | ||
108 | #define ACT_ON 0x0001 | ||
109 | |||
110 | #define TLV320AIC23ID1 (0x1a) // cs low | ||
111 | #define TLV320AIC23ID2 (0x1b) // cs high | ||
112 | |||
113 | void aic23_power_up(void); | ||
114 | void aic23_power_down(void); | ||
115 | |||
116 | #endif /* __ASM_ARCH_AIC23_H */ | ||
diff --git a/arch/arm/plat-omap/include/mach/board-h3.h b/arch/arm/plat-omap/include/mach/board-h3.h index 14909dc7858a..1888326da7ea 100644 --- a/arch/arm/plat-omap/include/mach/board-h3.h +++ b/arch/arm/plat-omap/include/mach/board-h3.h | |||
@@ -30,7 +30,9 @@ | |||
30 | /* In OMAP1710 H3 the Ethernet is directly connected to CS1 */ | 30 | /* In OMAP1710 H3 the Ethernet is directly connected to CS1 */ |
31 | #define OMAP1710_ETHR_START 0x04000300 | 31 | #define OMAP1710_ETHR_START 0x04000300 |
32 | 32 | ||
33 | #define H3_TPS_GPIO_BASE (OMAP_MAX_GPIO_LINES + 16 /* MPUIO */) | ||
34 | # define H3_TPS_GPIO_MMC_PWR_EN (H3_TPS_GPIO_BASE + 4) | ||
35 | |||
33 | extern void h3_mmc_init(void); | 36 | extern void h3_mmc_init(void); |
34 | extern void h3_mmc_slot_cover_handler(void *arg, int state); | ||
35 | 37 | ||
36 | #endif /* __ASM_ARCH_OMAP_H3_H */ | 38 | #endif /* __ASM_ARCH_OMAP_H3_H */ |
diff --git a/arch/arm/plat-omap/include/mach/gpio.h b/arch/arm/plat-omap/include/mach/gpio.h index 04e68e88f134..8d9dfe314387 100644 --- a/arch/arm/plat-omap/include/mach/gpio.h +++ b/arch/arm/plat-omap/include/mach/gpio.h | |||
@@ -87,16 +87,6 @@ extern void omap_set_gpio_debounce_time(int gpio, int enable); | |||
87 | #include <linux/errno.h> | 87 | #include <linux/errno.h> |
88 | #include <asm-generic/gpio.h> | 88 | #include <asm-generic/gpio.h> |
89 | 89 | ||
90 | static inline int omap_request_gpio(int gpio) | ||
91 | { | ||
92 | return gpio_request(gpio, "FIXME"); | ||
93 | } | ||
94 | |||
95 | static inline void omap_free_gpio(int gpio) | ||
96 | { | ||
97 | gpio_free(gpio); | ||
98 | } | ||
99 | |||
100 | static inline int gpio_get_value(unsigned gpio) | 90 | static inline int gpio_get_value(unsigned gpio) |
101 | { | 91 | { |
102 | return __gpio_get_value(gpio); | 92 | return __gpio_get_value(gpio); |
diff --git a/arch/arm/plat-omap/include/mach/mcbsp.h b/arch/arm/plat-omap/include/mach/mcbsp.h index 6a0d1a0a24a7..eef873db3d48 100644 --- a/arch/arm/plat-omap/include/mach/mcbsp.h +++ b/arch/arm/plat-omap/include/mach/mcbsp.h | |||
@@ -87,6 +87,10 @@ | |||
87 | #define OMAP_MCBSP_REG_XCERG 0x3A | 87 | #define OMAP_MCBSP_REG_XCERG 0x3A |
88 | #define OMAP_MCBSP_REG_XCERH 0x3C | 88 | #define OMAP_MCBSP_REG_XCERH 0x3C |
89 | 89 | ||
90 | /* Dummy defines, these are not available on omap1 */ | ||
91 | #define OMAP_MCBSP_REG_XCCR 0x00 | ||
92 | #define OMAP_MCBSP_REG_RCCR 0x00 | ||
93 | |||
90 | #define AUDIO_MCBSP_DATAWRITE (OMAP1510_MCBSP1_BASE + OMAP_MCBSP_REG_DXR1) | 94 | #define AUDIO_MCBSP_DATAWRITE (OMAP1510_MCBSP1_BASE + OMAP_MCBSP_REG_DXR1) |
91 | #define AUDIO_MCBSP_DATAREAD (OMAP1510_MCBSP1_BASE + OMAP_MCBSP_REG_DRR1) | 95 | #define AUDIO_MCBSP_DATAREAD (OMAP1510_MCBSP1_BASE + OMAP_MCBSP_REG_DRR1) |
92 | 96 | ||
@@ -231,11 +235,16 @@ | |||
231 | #define XPBBLK(value) ((value)<<7) /* Bits 7:8 */ | 235 | #define XPBBLK(value) ((value)<<7) /* Bits 7:8 */ |
232 | 236 | ||
233 | /*********************** McBSP XCCR bit definitions *************************/ | 237 | /*********************** McBSP XCCR bit definitions *************************/ |
238 | #define EXTCLKGATE 0x8000 | ||
239 | #define PPCONNECT 0x4000 | ||
240 | #define DXENDLY(value) ((value)<<12) /* Bits 12:13 */ | ||
241 | #define XFULL_CYCLE 0x0800 | ||
234 | #define DILB 0x0020 | 242 | #define DILB 0x0020 |
235 | #define XDMAEN 0x0008 | 243 | #define XDMAEN 0x0008 |
236 | #define XDISABLE 0x0001 | 244 | #define XDISABLE 0x0001 |
237 | 245 | ||
238 | /********************** McBSP RCCR bit definitions *************************/ | 246 | /********************** McBSP RCCR bit definitions *************************/ |
247 | #define RFULL_CYCLE 0x0800 | ||
239 | #define RDMAEN 0x0008 | 248 | #define RDMAEN 0x0008 |
240 | #define RDISABLE 0x0001 | 249 | #define RDISABLE 0x0001 |
241 | 250 | ||
@@ -267,6 +276,8 @@ struct omap_mcbsp_reg_cfg { | |||
267 | u16 rcerh; | 276 | u16 rcerh; |
268 | u16 xcerg; | 277 | u16 xcerg; |
269 | u16 xcerh; | 278 | u16 xcerh; |
279 | u16 xccr; | ||
280 | u16 rccr; | ||
270 | }; | 281 | }; |
271 | 282 | ||
272 | typedef enum { | 283 | typedef enum { |
diff --git a/arch/arm/plat-omap/mcbsp.c b/arch/arm/plat-omap/mcbsp.c index af33fc713e1a..f2401a831f99 100644 --- a/arch/arm/plat-omap/mcbsp.c +++ b/arch/arm/plat-omap/mcbsp.c | |||
@@ -173,6 +173,10 @@ void omap_mcbsp_config(unsigned int id, const struct omap_mcbsp_reg_cfg *config) | |||
173 | OMAP_MCBSP_WRITE(io_base, MCR2, config->mcr2); | 173 | OMAP_MCBSP_WRITE(io_base, MCR2, config->mcr2); |
174 | OMAP_MCBSP_WRITE(io_base, MCR1, config->mcr1); | 174 | OMAP_MCBSP_WRITE(io_base, MCR1, config->mcr1); |
175 | OMAP_MCBSP_WRITE(io_base, PCR0, config->pcr0); | 175 | OMAP_MCBSP_WRITE(io_base, PCR0, config->pcr0); |
176 | if (cpu_is_omap2430() || cpu_is_omap34xx()) { | ||
177 | OMAP_MCBSP_WRITE(io_base, XCCR, config->xccr); | ||
178 | OMAP_MCBSP_WRITE(io_base, RCCR, config->rccr); | ||
179 | } | ||
176 | } | 180 | } |
177 | EXPORT_SYMBOL(omap_mcbsp_config); | 181 | EXPORT_SYMBOL(omap_mcbsp_config); |
178 | 182 | ||
diff --git a/arch/arm/plat-omap/usb.c b/arch/arm/plat-omap/usb.c index add0485703b5..e278de6862ae 100644 --- a/arch/arm/plat-omap/usb.c +++ b/arch/arm/plat-omap/usb.c | |||
@@ -431,15 +431,6 @@ bad: | |||
431 | 431 | ||
432 | /*-------------------------------------------------------------------------*/ | 432 | /*-------------------------------------------------------------------------*/ |
433 | 433 | ||
434 | #if defined(CONFIG_USB_GADGET_OMAP) || \ | ||
435 | defined(CONFIG_USB_OHCI_HCD) || defined(CONFIG_USB_OHCI_HCD_MODULE) || \ | ||
436 | (defined(CONFIG_USB_OTG) && defined(CONFIG_ARCH_OMAP_OTG)) | ||
437 | static void usb_release(struct device *dev) | ||
438 | { | ||
439 | /* normally not freed */ | ||
440 | } | ||
441 | #endif | ||
442 | |||
443 | #ifdef CONFIG_USB_GADGET_OMAP | 434 | #ifdef CONFIG_USB_GADGET_OMAP |
444 | 435 | ||
445 | static struct resource udc_resources[] = { | 436 | static struct resource udc_resources[] = { |
@@ -466,7 +457,6 @@ static struct platform_device udc_device = { | |||
466 | .name = "omap_udc", | 457 | .name = "omap_udc", |
467 | .id = -1, | 458 | .id = -1, |
468 | .dev = { | 459 | .dev = { |
469 | .release = usb_release, | ||
470 | .dma_mask = &udc_dmamask, | 460 | .dma_mask = &udc_dmamask, |
471 | .coherent_dma_mask = 0xffffffff, | 461 | .coherent_dma_mask = 0xffffffff, |
472 | }, | 462 | }, |
@@ -497,7 +487,6 @@ static struct platform_device ohci_device = { | |||
497 | .name = "ohci", | 487 | .name = "ohci", |
498 | .id = -1, | 488 | .id = -1, |
499 | .dev = { | 489 | .dev = { |
500 | .release = usb_release, | ||
501 | .dma_mask = &ohci_dmamask, | 490 | .dma_mask = &ohci_dmamask, |
502 | .coherent_dma_mask = 0xffffffff, | 491 | .coherent_dma_mask = 0xffffffff, |
503 | }, | 492 | }, |
@@ -524,9 +513,6 @@ static struct resource otg_resources[] = { | |||
524 | static struct platform_device otg_device = { | 513 | static struct platform_device otg_device = { |
525 | .name = "omap_otg", | 514 | .name = "omap_otg", |
526 | .id = -1, | 515 | .id = -1, |
527 | .dev = { | ||
528 | .release = usb_release, | ||
529 | }, | ||
530 | .num_resources = ARRAY_SIZE(otg_resources), | 516 | .num_resources = ARRAY_SIZE(otg_resources), |
531 | .resource = otg_resources, | 517 | .resource = otg_resources, |
532 | }; | 518 | }; |