devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Marek Szyprowski <m.szyprowski@samsung.com>
To: JeffyChen <jeffy.chen@rock-chips.com>, linux-kernel@vger.kernel.org
Cc: jcliang@chromium.org, robin.murphy@arm.com, tfiga@chromium.org,
	linux-samsung-soc@vger.kernel.org, Kukjin Kim <kgene@kernel.org>,
	devicetree@vger.kernel.org, linux-arm-msm@vger.kernel.org,
	iommu@lists.linux-foundation.org,
	Frank Rowand <frowand.list@gmail.com>,
	Krzysztof Kozlowski <krzk@kernel.org>,
	Rob Clark <robdclark@gmail.com>,
	Will Deacon <will.deacon@arm.com>, Joerg Roedel <joro@8bytes.org>,
	Rob Herring <robh+dt@kernel.org>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 1/9] iommu/of: Drop early initialisation hooks
Date: Thu, 11 Jan 2018 13:26:26 +0100	[thread overview]
Message-ID: <ad520247-8342-97c2-4448-5f5e87394aa1@samsung.com> (raw)
In-Reply-To: <5A57471E.7020304@rock-chips.com>

Hi Jeffy,

On 2018-01-11 12:14, JeffyChen wrote:
> Hi Marek,
>
> Thanks for your reply.
>
> On 01/11/2018 05:40 PM, Marek Szyprowski wrote:
>> Hi Jeffy,
>>
>> On 2018-01-11 09:22, Jeffy Chen wrote:
>>> With the probe-deferral mechanism, early initialisation hooks are no
>>> longer needed.
>>>
>>> Suggested-by: Robin Murphy <robin.murphy@arm.com>
>>> Signed-off-by: Jeffy Chen <jeffy.chen@rock-chips.com>
>>> ---
>>>
>>>   drivers/iommu/arm-smmu-v3.c  |  2 +-
>>>   drivers/iommu/arm-smmu.c     | 12 ++++++------
>>>   drivers/iommu/exynos-iommu.c |  2 +-
>>
>> For Exynos IOMMU:
>> Acked-by: Marek Szyprowski <m.szyprowski@samsung.com>
>>
>> IPMMU and MSM IOMMU are no longer multi-platform safe after this patch.
>> It breaks them in the same way as my commit 928055a01b3f ("iommu/exynos:
>> Remove custom platform device registration code") broke Exynos IOMMU.
>>
>> You need a similar fix for them:
>> https://www.spinics.net/lists/arm-kernel/msg627648.html
>
> hmmm, right, i did saw this fix in the rockchip iommu driver too.
>
> and there're also some other iommu drivers put bus_set_iommu in their 
> probe() to avoid that.
>
> maybe we can do it in the iommu framework?
>
> for example:
> 1/ add a bus type member to struct iommu_device
> 2/ and a iommu_device_set_bus()
> 3/ do the bus_set_iommu stuff in iommu_device_register()
> 4/ undo bus_set_iommu in iommu_device_unregister()

Frankly, in case the device-tree based systems bus_set_iommu()
should not be needed at all. However for some legacy reasons it
is still required by a few bits of code (at least it was needed
some time ago). Probably it would be best if this is finally
resolved.

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland

      parent reply	other threads:[~2018-01-11 12:26 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-11  8:22 [PATCH 0/9] iommu/rockchip: Use OF_IOMMU Jeffy Chen
2018-01-11  8:22 ` [PATCH 1/9] iommu/of: Drop early initialisation hooks Jeffy Chen
     [not found]   ` <20180111082229.24011-2-jeffy.chen-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2018-01-11  9:40     ` Marek Szyprowski
     [not found]       ` <60fdd375-ca74-0fea-c598-39a68b9e7735-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2018-01-11 11:14         ` JeffyChen
     [not found]           ` <5A57471E.7020304-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2018-01-11 12:24             ` Robin Murphy
     [not found]               ` <faeccc75-79e9-ddb6-446d-88ab63fe4e1f-5wv7dgnIgG8@public.gmane.org>
2018-01-12  1:22                 ` JeffyChen
2018-01-11 12:26           ` Marek Szyprowski [this message]

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=ad520247-8342-97c2-4448-5f5e87394aa1@samsung.com \
    --to=m.szyprowski@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=frowand.list@gmail.com \
    --cc=iommu@lists.linux-foundation.org \
    --cc=jcliang@chromium.org \
    --cc=jeffy.chen@rock-chips.com \
    --cc=joro@8bytes.org \
    --cc=kgene@kernel.org \
    --cc=krzk@kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=robdclark@gmail.com \
    --cc=robh+dt@kernel.org \
    --cc=robin.murphy@arm.com \
    --cc=tfiga@chromium.org \
    --cc=will.deacon@arm.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;
as well as URLs for NNTP newsgroup(s).