mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Ralf Baechle <ralf@linux-mips.org>,
	Vinod Koul <vinod.koul@intel.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>
Cc: Maarten ter Huurne <maarten@treewalker.org>,
	linux-mips@linux-mips.org, linux-kernel@vger.kernel.org,
	alsa-devel@alsa-project.org, Lars-Peter Clausen <lars@metafoo.de>
Subject: [PATCH v2 4/6] MIPS: jz4740: Register jz4740 DMA device
Date: Thu, 30 May 2013 18:25:03 +0200	[thread overview]
Message-ID: <1369931105-28065-5-git-send-email-lars@metafoo.de> (raw)
In-Reply-To: <1369931105-28065-1-git-send-email-lars@metafoo.de>

Register a device for the newly added jz4740 dmaengine driver.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Ralf Baechle <ralf@linux-mips.org>
---
No changes since v1
---
 arch/mips/include/asm/mach-jz4740/platform.h |  1 +
 arch/mips/jz4740/board-qi_lb60.c             |  1 +
 arch/mips/jz4740/platform.c                  | 21 +++++++++++++++++++++
 3 files changed, 23 insertions(+)

diff --git a/arch/mips/include/asm/mach-jz4740/platform.h b/arch/mips/include/asm/mach-jz4740/platform.h
index 72cfebd..05988c2 100644
--- a/arch/mips/include/asm/mach-jz4740/platform.h
+++ b/arch/mips/include/asm/mach-jz4740/platform.h
@@ -32,6 +32,7 @@ extern struct platform_device jz4740_codec_device;
 extern struct platform_device jz4740_adc_device;
 extern struct platform_device jz4740_wdt_device;
 extern struct platform_device jz4740_pwm_device;
+extern struct platform_device jz4740_dma_device;
 
 void jz4740_serial_device_register(void);
 
diff --git a/arch/mips/jz4740/board-qi_lb60.c b/arch/mips/jz4740/board-qi_lb60.c
index be2b3de..8a5ec0e 100644
--- a/arch/mips/jz4740/board-qi_lb60.c
+++ b/arch/mips/jz4740/board-qi_lb60.c
@@ -438,6 +438,7 @@ static struct platform_device *jz_platform_devices[] __initdata = {
 	&jz4740_rtc_device,
 	&jz4740_adc_device,
 	&jz4740_pwm_device,
+	&jz4740_dma_device,
 	&qi_lb60_gpio_keys,
 	&qi_lb60_pwm_beeper,
 	&qi_lb60_charger_device,
diff --git a/arch/mips/jz4740/platform.c b/arch/mips/jz4740/platform.c
index e9348fd..35a9d8c 100644
--- a/arch/mips/jz4740/platform.c
+++ b/arch/mips/jz4740/platform.c
@@ -329,3 +329,24 @@ struct platform_device jz4740_pwm_device = {
 	.name = "jz4740-pwm",
 	.id   = -1,
 };
+
+/* DMA */
+static struct resource jz4740_dma_resources[] = {
+	{
+		.start	= JZ4740_DMAC_BASE_ADDR,
+		.end	= JZ4740_DMAC_BASE_ADDR + 0x400 - 1,
+		.flags	= IORESOURCE_MEM,
+	},
+	{
+		.start	= JZ4740_IRQ_DMAC,
+		.end	= JZ4740_IRQ_DMAC,
+		.flags	= IORESOURCE_IRQ,
+	},
+};
+
+struct platform_device jz4740_dma_device = {
+	.name	= "jz4740-dma",
+	.id	= -1,
+	.num_resources = ARRAY_SIZE(jz4740_dma_resources),
+	.resource      = jz4740_dma_resources,
+};
-- 
1.8.2.1


  parent reply	other threads:[~2013-05-30 16:23 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-30 16:24 [PATCH 0/6] Convert JZ4740 to dmaengine Lars-Peter Clausen
2013-05-30 16:25 ` [PATCH v2 1/6] MIPS: jz4740: Correct clock gate bit for DMA controller Lars-Peter Clausen
2013-05-30 16:25 ` [PATCH v2 2/6] MIPS: jz4740: Acquire and enable DMA controller clock Lars-Peter Clausen
2013-05-30 16:25 ` [PATCH v2 3/6] dma: Add a jz4740 dmaengine driver Lars-Peter Clausen
2013-05-30 17:12   ` Vinod Koul
2013-05-30 18:46     ` Lars-Peter Clausen
2013-06-10 17:29       ` Lars-Peter Clausen
2013-06-12  5:38         ` Vinod Koul
2013-06-12 12:07           ` [alsa-devel] " Lars-Peter Clausen
2013-06-21 10:51             ` Vinod Koul
2013-05-30 16:25 ` Lars-Peter Clausen [this message]
2013-05-30 17:24   ` [PATCH v2 4/6] MIPS: jz4740: Register jz4740 DMA device Sergei Shtylyov
2013-06-10 17:30     ` Lars-Peter Clausen
2013-05-30 16:25 ` [PATCH v2 5/6] ASoC: jz4740: Use the generic dmaengine PCM driver Lars-Peter Clausen
2013-05-30 16:25 ` [PATCH v2 6/6] MIPS: jz4740: Remove custom DMA API Lars-Peter Clausen
2013-05-30 17:20   ` Vinod Koul
2013-05-30 18:48     ` Lars-Peter Clausen
2013-06-21 14:13 ` [PATCH 0/6] Convert JZ4740 to dmaengine Vinod Koul

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=1369931105-28065-5-git-send-email-lars@metafoo.de \
    --to=lars@metafoo.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@linux-mips.org \
    --cc=maarten@treewalker.org \
    --cc=ralf@linux-mips.org \
    --cc=vinod.koul@intel.com \
    /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

Powered by JetHome