From: swarren@nvidia.com (Stephen Warren)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/5] ARM: Tegra: Add devices.c entries for audio
Date: Wed, 23 Feb 2011 11:58:48 -0700 [thread overview]
Message-ID: <1298487532-5000-2-git-send-email-swarren@nvidia.com> (raw)
In-Reply-To: <1298487532-5000-1-git-send-email-swarren@nvidia.com>
For I2S, DAS, PCM devices
Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
NOTE: This patch will not apply until Olof's recently posted
boards-for-next branch is merged.
arch/arm/mach-tegra/devices.c | 70 ++++++++++++++++++++++++++++++
arch/arm/mach-tegra/devices.h | 4 ++
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 682e6d3..1528f9d 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 = {
.coherent_dma_mask = DMA_BIT_MASK(32),
},
};
+
+static struct resource i2s_resource1[] = {
+ [0] = {
+ .start = INT_I2S1,
+ .end = INT_I2S1,
+ .flags = IORESOURCE_IRQ
+ },
+ [1] = {
+ .start = TEGRA_DMA_REQ_SEL_I2S_1,
+ .end = TEGRA_DMA_REQ_SEL_I2S_1,
+ .flags = IORESOURCE_DMA
+ },
+ [2] = {
+ .start = TEGRA_I2S1_BASE,
+ .end = TEGRA_I2S1_BASE + TEGRA_I2S1_SIZE - 1,
+ .flags = IORESOURCE_MEM
+ }
+};
+
+static struct resource i2s_resource2[] = {
+ [0] = {
+ .start = INT_I2S2,
+ .end = INT_I2S2,
+ .flags = IORESOURCE_IRQ
+ },
+ [1] = {
+ .start = TEGRA_DMA_REQ_SEL_I2S2_1,
+ .end = TEGRA_DMA_REQ_SEL_I2S2_1,
+ .flags = IORESOURCE_DMA
+ },
+ [2] = {
+ .start = TEGRA_I2S2_BASE,
+ .end = TEGRA_I2S2_BASE + TEGRA_I2S2_SIZE - 1,
+ .flags = IORESOURCE_MEM
+ }
+};
+
+struct platform_device tegra_i2s_device1 = {
+ .name = "tegra-i2s",
+ .id = 0,
+ .resource = i2s_resource1,
+ .num_resources = ARRAY_SIZE(i2s_resource1),
+};
+
+struct platform_device tegra_i2s_device2 = {
+ .name = "tegra-i2s",
+ .id = 1,
+ .resource = i2s_resource2,
+ .num_resources = ARRAY_SIZE(i2s_resource2),
+};
+
+static struct resource tegra_das_resources[] = {
+ [0] = {
+ .start = TEGRA_APB_MISC_DAS_BASE,
+ .end = TEGRA_APB_MISC_DAS_BASE + TEGRA_APB_MISC_DAS_SIZE - 1,
+ .flags = IORESOURCE_MEM,
+ },
+};
+
+struct platform_device tegra_das_device = {
+ .name = "tegra-das",
+ .id = -1,
+ .num_resources = ARRAY_SIZE(tegra_das_resources),
+ .resource = tegra_das_resources,
+};
+
+struct platform_device tegra_pcm_device = {
+ .name = "tegra-pcm-audio",
+ .id = -1,
+};
diff --git a/arch/arm/mach-tegra/devices.h b/arch/arm/mach-tegra/devices.h
index 888810c..4a7dc0a 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;
extern struct platform_device tegra_uartd_device;
extern struct platform_device tegra_uarte_device;
extern struct platform_device tegra_pmu_device;
+extern struct platform_device tegra_i2s_device1;
+extern struct platform_device tegra_i2s_device2;
+extern struct platform_device tegra_das_device;
+extern struct platform_device tegra_pcm_device;
#endif
diff --git a/arch/arm/mach-tegra/include/mach/iomap.h b/arch/arm/mach-tegra/include/mach/iomap.h
index 691cdab..19dec3a 100644
--- a/arch/arm/mach-tegra/include/mach/iomap.h
+++ b/arch/arm/mach-tegra/include/mach/iomap.h
@@ -122,6 +122,9 @@
#define TEGRA_APB_MISC_BASE 0x70000000
#define TEGRA_APB_MISC_SIZE SZ_4K
+#define TEGRA_APB_MISC_DAS_BASE 0x70000c00
+#define TEGRA_APB_MISC_DAS_SIZE SZ_128
+
#define TEGRA_AC97_BASE 0x70002000
#define TEGRA_AC97_SIZE SZ_512
--
1.7.1
next prev parent reply other threads:[~2011-02-23 18:58 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-02-23 18:58 [PATCH 0/5] ARM: Tegra: Harmony: Enable audio driver Stephen Warren
2011-02-23 18:58 ` Stephen Warren [this message]
2011-02-23 21:04 ` [PATCH 1/5] ARM: Tegra: Add devices.c entries for audio Colin Cross
2011-02-23 18:58 ` [PATCH 2/5] ARM: Tegra: Rename I2S clocks to match driver name Stephen Warren
2011-02-23 21:06 ` Colin Cross
2011-02-23 18:58 ` [PATCH 3/5] ARM: Tegra: Rename clk_dev1/2 to cdev1/2 Stephen Warren
2011-02-23 21:06 ` Colin Cross
2011-02-23 18:58 ` [PATCH 4/5] ARM: Tegra: Create defines for GPIO names Stephen Warren
2011-02-23 19:08 ` Colin Cross
2011-02-23 20:35 ` Stephen Warren
2011-02-23 20:39 ` Colin Cross
2011-02-23 20:49 ` Stephen Warren
2011-02-23 20:58 ` Colin Cross
2011-02-23 18:58 ` [PATCH 5/5] ARM: Tegra: Enable Harmony audio support Stephen Warren
2011-02-23 21:08 ` Colin Cross
2011-02-23 21:16 ` Stephen Warren
2011-02-23 21:19 ` Colin Cross
2011-02-23 21:08 ` Olof Johansson
2011-02-23 21:15 ` Colin Cross
2011-02-23 21:21 ` Olof Johansson
2011-02-23 21:22 ` Stephen Warren
2011-02-23 21:25 ` Olof Johansson
2011-02-23 21:21 ` Colin Cross
2011-02-23 21:24 ` Olof Johansson
2011-02-23 21:35 ` Stephen Warren
2011-02-23 21:51 ` Olof Johansson
2011-02-23 21:54 ` Stephen Warren
2011-02-23 22:48 ` Russell King - ARM Linux
-- strict thread matches above, loose matches on Subject: below --
2011-03-05 5:42 [PATCH 0/5] ARM: Tegra: Enable audio (boards-for-next-i2c) Stephen Warren
2011-03-05 5:42 ` [PATCH 1/5] ARM: Tegra: Add devices.c entries for audio Stephen Warren
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1298487532-5000-2-git-send-email-swarren@nvidia.com \
--to=swarren@nvidia.com \
--cc=linux-arm-kernel@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).