diff options
author | Stephen Warren <swarren@nvidia.com> | 2011-03-05 00:44:27 -0500 |
---|---|---|
committer | Olof Johansson <olof@lixom.net> | 2011-03-07 18:34:24 -0500 |
commit | b9652c2d127e994748d4bffc45369ed423d5ae8d (patch) | |
tree | d9554c77e28b07bacbe619c706340bd5150416f8 /arch/arm | |
parent | d5fdafd38ca0c28c4648909ce0afd0a5420309ca (diff) |
ARM: tegra: add devices.c entries for audio
For I2S, DAS, PCM devices
Signed-off-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Olof Johansson <olof@lixom.net>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-tegra/devices.c | 70 | ||||
-rw-r--r-- | arch/arm/mach-tegra/devices.h | 4 | ||||
-rw-r--r-- | arch/arm/mach-tegra/include/mach/iomap.h | 3 |
3 files changed, 77 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/devices.c b/arch/arm/mach-tegra/devices.c index 682e6d33108c..1528f9daef1f 100644 --- a/arch/arm/mach-tegra/devices.c +++ b/arch/arm/mach-tegra/devices.c | |||
@@ -503,3 +503,73 @@ struct platform_device tegra_uarte_device = { | |||
503 | .coherent_dma_mask = DMA_BIT_MASK(32), | 503 | .coherent_dma_mask = DMA_BIT_MASK(32), |
504 | }, | 504 | }, |
505 | }; | 505 | }; |
506 | |||
507 | static struct resource i2s_resource1[] = { | ||
508 | [0] = { | ||
509 | .start = INT_I2S1, | ||
510 | .end = INT_I2S1, | ||
511 | .flags = IORESOURCE_IRQ | ||
512 | }, | ||
513 | [1] = { | ||
514 | .start = TEGRA_DMA_REQ_SEL_I2S_1, | ||
515 | .end = TEGRA_DMA_REQ_SEL_I2S_1, | ||
516 | .flags = IORESOURCE_DMA | ||
517 | }, | ||
518 | [2] = { | ||
519 | .start = TEGRA_I2S1_BASE, | ||
520 | .end = TEGRA_I2S1_BASE + TEGRA_I2S1_SIZE - 1, | ||
521 | .flags = IORESOURCE_MEM | ||
522 | } | ||
523 | }; | ||
524 | |||
525 | static struct resource i2s_resource2[] = { | ||
526 | [0] = { | ||
527 | .start = INT_I2S2, | ||
528 | .end = INT_I2S2, | ||
529 | .flags = IORESOURCE_IRQ | ||
530 | }, | ||
531 | [1] = { | ||
532 | .start = TEGRA_DMA_REQ_SEL_I2S2_1, | ||
533 | .end = TEGRA_DMA_REQ_SEL_I2S2_1, | ||
534 | .flags = IORESOURCE_DMA | ||
535 | }, | ||
536 | [2] = { | ||
537 | .start = TEGRA_I2S2_BASE, | ||
538 | .end = TEGRA_I2S2_BASE + TEGRA_I2S2_SIZE - 1, | ||
539 | .flags = IORESOURCE_MEM | ||
540 | } | ||
541 | }; | ||
542 | |||
543 | struct platform_device tegra_i2s_device1 = { | ||
544 | .name = "tegra-i2s", | ||
545 | .id = 0, | ||
546 | .resource = i2s_resource1, | ||
547 | .num_resources = ARRAY_SIZE(i2s_resource1), | ||
548 | }; | ||
549 | |||
550 | struct platform_device tegra_i2s_device2 = { | ||
551 | .name = "tegra-i2s", | ||
552 | .id = 1, | ||
553 | .resource = i2s_resource2, | ||
554 | .num_resources = ARRAY_SIZE(i2s_resource2), | ||
555 | }; | ||
556 | |||
557 | static struct resource tegra_das_resources[] = { | ||
558 | [0] = { | ||
559 | .start = TEGRA_APB_MISC_DAS_BASE, | ||
560 | .end = TEGRA_APB_MISC_DAS_BASE + TEGRA_APB_MISC_DAS_SIZE - 1, | ||
561 | .flags = IORESOURCE_MEM, | ||
562 | }, | ||
563 | }; | ||
564 | |||
565 | struct platform_device tegra_das_device = { | ||
566 | .name = "tegra-das", | ||
567 | .id = -1, | ||
568 | .num_resources = ARRAY_SIZE(tegra_das_resources), | ||
569 | .resource = tegra_das_resources, | ||
570 | }; | ||
571 | |||
572 | struct platform_device tegra_pcm_device = { | ||
573 | .name = "tegra-pcm-audio", | ||
574 | .id = -1, | ||
575 | }; | ||
diff --git a/arch/arm/mach-tegra/devices.h b/arch/arm/mach-tegra/devices.h index 888810c37ee9..4a7dc0a097d6 100644 --- a/arch/arm/mach-tegra/devices.h +++ b/arch/arm/mach-tegra/devices.h | |||
@@ -42,5 +42,9 @@ extern struct platform_device tegra_uartc_device; | |||
42 | extern struct platform_device tegra_uartd_device; | 42 | extern struct platform_device tegra_uartd_device; |
43 | extern struct platform_device tegra_uarte_device; | 43 | extern struct platform_device tegra_uarte_device; |
44 | extern struct platform_device tegra_pmu_device; | 44 | extern struct platform_device tegra_pmu_device; |
45 | extern struct platform_device tegra_i2s_device1; | ||
46 | extern struct platform_device tegra_i2s_device2; | ||
47 | extern struct platform_device tegra_das_device; | ||
48 | extern struct platform_device tegra_pcm_device; | ||
45 | 49 | ||
46 | #endif | 50 | #endif |
diff --git a/arch/arm/mach-tegra/include/mach/iomap.h b/arch/arm/mach-tegra/include/mach/iomap.h index 691cdabd69cf..19dec3ac0854 100644 --- a/arch/arm/mach-tegra/include/mach/iomap.h +++ b/arch/arm/mach-tegra/include/mach/iomap.h | |||
@@ -122,6 +122,9 @@ | |||
122 | #define TEGRA_APB_MISC_BASE 0x70000000 | 122 | #define TEGRA_APB_MISC_BASE 0x70000000 |
123 | #define TEGRA_APB_MISC_SIZE SZ_4K | 123 | #define TEGRA_APB_MISC_SIZE SZ_4K |
124 | 124 | ||
125 | #define TEGRA_APB_MISC_DAS_BASE 0x70000c00 | ||
126 | #define TEGRA_APB_MISC_DAS_SIZE SZ_128 | ||
127 | |||
125 | #define TEGRA_AC97_BASE 0x70002000 | 128 | #define TEGRA_AC97_BASE 0x70002000 |
126 | #define TEGRA_AC97_SIZE SZ_512 | 129 | #define TEGRA_AC97_SIZE SZ_512 |
127 | 130 | ||