public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: linuxppc-dev@lists.ozlabs.org
Cc: Suman Tripathi <stripathi@apm.com>,
	chris@printf.net, anton@enomsg.org, devicetree@vger.kernel.org,
	jcm@redhat.com, linux-mmc@vger.kernel.org, patches@apm.com,
	ddutile@redhat.com, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 1/2] mmc: host: arasan: Add addition of-arasan quirks and add IOMMU support.
Date: Mon, 15 Dec 2014 22:27:33 +0100	[thread overview]
Message-ID: <3866536.C6OiUcuGCr@wuerfel> (raw)
In-Reply-To: <1418662867-9210-2-git-send-email-stripathi@apm.com>

On Monday 15 December 2014 22:31:06 Suman Tripathi wrote:
> @@ -162,6 +206,16 @@ static int sdhci_arasan_probe(struct platform_device *pdev)
>                 goto clk_dis_ahb;
>         }
> 
> +#if defined(CONFIG_IOMMU_SUPPORT)
> +       sdhci_arasan->domain = iommu_domain_alloc(&amba_bustype);
> +       if (!sdhci_arasan->domain) {
> +               dev_err(&pdev->dev, "Unable to allocate iommu domain\n");
> +               return PTR_ERR(sdhci_arasan->domain);
> +       }
> +
> +       iommu_attach_device(sdhci_arasan->domain, &pdev->dev);
> +#endif
> +
> 

Device drivers should never care about the implementation details
of the iommu. Please change the code to use the regular dma_map_*
interfaces that will work both with and without IOMMU.

	Arnd

  reply	other threads:[~2014-12-15 21:28 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-12-15 17:01 [PATCH 0/2] Add SDHCI support for APM X-Gene SoC using ARASAN SDHCI controller Suman Tripathi
     [not found] ` <1418662867-9210-1-git-send-email-stripathi-qTEPVZfXA3Y@public.gmane.org>
2014-12-15 17:01   ` [PATCH 1/2] mmc: host: arasan: Add addition of-arasan quirks and add IOMMU support Suman Tripathi
2014-12-15 21:27     ` Arnd Bergmann [this message]
2015-01-06 11:40       ` Suman Tripathi
2015-01-06 13:55         ` Arnd Bergmann
2014-12-15 17:01   ` [PATCH 2/2] arm64: dts: Add APM X-Gene SDHCI DTS node Suman Tripathi

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=3866536.C6OiUcuGCr@wuerfel \
    --to=arnd@arndb.de \
    --cc=anton@enomsg.org \
    --cc=chris@printf.net \
    --cc=ddutile@redhat.com \
    --cc=devicetree@vger.kernel.org \
    --cc=jcm@redhat.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=patches@apm.com \
    --cc=stripathi@apm.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