dmaengine.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Vinod Koul <vkoul@kernel.org>,
	dmaengine@vger.kernel.org, Viresh Kumar <vireshk@kernel.org>
Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Subject: [PATCH v1 07/12] dmaengine: dw: platform: Enable iDMA 32-bit on Intel Elkhart Lake
Date: Tue,  6 Aug 2019 12:40:49 +0300	[thread overview]
Message-ID: <20190806094054.64871-7-andriy.shevchenko@linux.intel.com> (raw)
In-Reply-To: <20190806094054.64871-1-andriy.shevchenko@linux.intel.com>

Intel Elkhart Lake OSE (Offload Service Engine) provides few DMA controllers
to the host. Enable them in the ACPI glue driver.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
---
 drivers/dma/dw/platform.c | 16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)

diff --git a/drivers/dma/dw/platform.c b/drivers/dma/dw/platform.c
index 234abbd6359a..7e0ec6ef3a1f 100644
--- a/drivers/dma/dw/platform.c
+++ b/drivers/dma/dw/platform.c
@@ -173,7 +173,6 @@ static int dw_probe(struct platform_device *pdev)
 	struct dw_dma_chip *chip;
 	struct device *dev = &pdev->dev;
 	struct resource *mem;
-	const struct dw_dma_platform_data *pdata;
 	int err;
 
 	match = device_get_match_data(dev);
@@ -201,13 +200,14 @@ static int dw_probe(struct platform_device *pdev)
 	if (err)
 		return err;
 
-	pdata = dev_get_platdata(dev);
-	if (!pdata)
-		pdata = dw_dma_parse_dt(pdev);
+	if (!data->pdata)
+		data->pdata = dev_get_platdata(dev);
+	if (!data->pdata)
+		data->pdata = dw_dma_parse_dt(pdev);
 
 	chip->dev = dev;
 	chip->id = pdev->id;
-	chip->pdata = pdata;
+	chip->pdata = data->pdata;
 
 	data->chip = chip;
 
@@ -298,6 +298,12 @@ static const struct acpi_device_id dw_dma_acpi_id_table[] = {
 	{ "INTL9C60", (kernel_ulong_t)&dw_dma_chip_pdata },
 	{ "80862286", (kernel_ulong_t)&dw_dma_chip_pdata },
 	{ "808622C0", (kernel_ulong_t)&dw_dma_chip_pdata },
+
+	/* Elkhart Lake iDMA 32-bit (OSE DMA) */
+	{ "80864BB4", (kernel_ulong_t)&idma32_chip_pdata },
+	{ "80864BB5", (kernel_ulong_t)&idma32_chip_pdata },
+	{ "80864BB6", (kernel_ulong_t)&idma32_chip_pdata },
+
 	{ }
 };
 MODULE_DEVICE_TABLE(acpi, dw_dma_acpi_id_table);
-- 
2.20.1


  parent reply	other threads:[~2019-08-06  9:45 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-06  9:40 [PATCH v1 01/12] dmaengine: acpi: Set up DMA mask based on CSRT Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 02/12] dmaengine: acpi: Move index to struct acpi_dma_spec Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 03/12] dmaengine: acpi: Provide consumer device to ->acpi_dma_xlate() Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 04/12] dmaengine: acpi: Add kernel doc parameter descriptions Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 05/12] dmaengine: dw: Export struct dw_dma_chip_pdata for wider use Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 06/12] dmaengine: dw: platform: Use struct dw_dma_chip_pdata Andy Shevchenko
2019-08-06  9:40 ` Andy Shevchenko [this message]
2019-08-14 14:44   ` [PATCH v1 07/12] dmaengine: dw: platform: Enable iDMA 32-bit on Intel Elkhart Lake Andy Shevchenko
2019-08-20 11:13     ` Vinod Koul
2019-08-06  9:40 ` [PATCH v1 08/12] dmaengine: dw: platform: Use devm_platform_ioremap_resource() Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 09/12] dmaengine: dw: platform: Switch to acpi_dma_controller_register() Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 10/12] dmaengine: dw: platform: Move handle check to dw_dma_acpi_controller_register() Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 11/12] dmaengine: dw: platform: Split ACPI helpers to separate module Andy Shevchenko
2019-08-06  9:40 ` [PATCH v1 12/12] dmaengine: dw: platform: Split OF " Andy Shevchenko

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=20190806094054.64871-7-andriy.shevchenko@linux.intel.com \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=dmaengine@vger.kernel.org \
    --cc=vireshk@kernel.org \
    --cc=vkoul@kernel.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).