From: Robin Murphy <robin.murphy-5wv7dgnIgG8@public.gmane.org>
To: Stefano Stabellini
<stefano.stabellini-mvvWK6WmYclDPfheJLI6IQ@public.gmane.org>
Cc: "linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org"
<linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org>,
"arnd-r2nGTMty4D4@public.gmane.org"
<arnd-r2nGTMty4D4@public.gmane.org>,
Catalin Marinas <Catalin.Marinas-5wv7dgnIgG8@public.gmane.org>,
Will Deacon <Will.Deacon-5wv7dgnIgG8@public.gmane.org>,
"iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org"
<iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org>,
"thunder.leizhen-hv44wF8Li93QT0dZR+AlfA@public.gmane.org"
<thunder.leizhen-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>,
"dwmw2-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org"
<dwmw2-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org>,
"linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org"
<linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org>
Subject: Re: [RFC PATCH 0/5] arm64: IOMMU-backed DMA mapping
Date: Tue, 13 Jan 2015 11:45:25 +0000 [thread overview]
Message-ID: <54B50555.6090803@arm.com> (raw)
In-Reply-To: <alpine.DEB.2.02.1501131102540.3058-7Z66fg9igcxYtxbxJUhB2Dgeux46jI+i@public.gmane.org>
On 13/01/15 11:08, Stefano Stabellini wrote:
> On Mon, 12 Jan 2015, Robin Murphy wrote:
>> Hi all,
>>
>> Whilst it's a long way off perfect, this has reached the point of being
>> functional and stable enough to be useful, so here it is. The core
>> consists of the meat of the arch/arm implementation modified to remove
>> the assumption of PAGE_SIZE pages and ported over to the Intel IOVA
>> allocator instead of the bitmap-based one. For that, this series depends
>> on my "Genericise the IOVA allocator" series posted earlier[1].
>>
>> There are plenty of obvious things still to do, including:
>>
>> * Domain and group handling is all wrong, but that's a bigger problem.
>> For the moment it does more or less the same thing as the arch/arm
>> code, which at least works for the one-IOMMU-per-device situation.
>> * IOMMU domains and IOVA domains probably want to be better integrated
>> with devices and each other, rather than having a proliferation of
>> arch-specific structs.
>> * The temporary map_sg implementation - I have a 'proper' iommu_map_sg
>> based one in progress, but since the simple one works it's not been
>> as high a priority.
>> * Port arch/arm over to it. I'd guess it might be preferable to merge
>> this through arm64 first, though, rather than overcomplicate matters.
>> * There may well be scope for streamlining and tidying up the copied
>> parts - In general I've simply avoided touching anything I don't
>> fully understand.
>> * In the same vein, I'm sure lots of it is fairly ARM-specific, so will
>> need longer-term work to become truly generic.
>>
>> [1]:http://thread.gmane.org/gmane.linux.kernel.iommu/8208
>
> I tried to git-am and build a v3.19-rc4 kernel with this series (config
> file attached), but I get:
>
> In file included from include/linux/dma-mapping.h:82:0,
> from arch/arm64/kernel/asm-offsets.c:23:
> ./arch/arm64/include/asm/dma-mapping.h: In function ‘phys_to_dma’:
> ./arch/arm64/include/asm/dma-mapping.h:69:2: error: ‘struct dev_archdata’ has no member named ‘mapping’
> ./arch/arm64/include/asm/dma-mapping.h: In function ‘dma_to_phys’:
> ./arch/arm64/include/asm/dma-mapping.h:81:19: error: ‘struct dev_archdata’ has no member named ‘mapping’
> make[1]: *** [arch/arm64/kernel/asm-offsets.s] Error 1
>
Oops, looks like I've been relying on having an actual IOMMU driver
select CONFIG_IOMMU_API - enabling the ARM SMMU driver as well as "IOMMU
hardware support" makes everything build, even if it doesn't actually
work with the new framework (the patches for that exist, but are
currently a big ugly mess).
The nested #include guard in arch/arm64/include/asm/device.h in patch 4
is to blame - on reflection, I guess that isn't a great idea regardless
of the logical dependency (I don't think my Kconfig-fu is strong enough
to guarantee that dependency is enforced).
Robin.
_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu
next prev parent reply other threads:[~2015-01-13 11:45 UTC|newest]
Thread overview: 30+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-12 20:48 [RFC PATCH 0/5] arm64: IOMMU-backed DMA mapping Robin Murphy
2015-01-13 8:02 ` Yingjoe Chen
2015-01-13 12:07 ` Robin Murphy
2015-01-15 18:35 ` Robin Murphy
2015-01-16 7:21 ` Yong Wu
2015-01-16 20:12 ` Robin Murphy
[not found] ` <cover.1421086706.git.robin.murphy-5wv7dgnIgG8@public.gmane.org>
2015-01-12 20:48 ` [RFC PATCH 1/5] arm64: Combine coherent and non-coherent swiotlb dma_ops Robin Murphy
2015-01-12 20:48 ` [RFC PATCH 2/5] arm64: implement generic IOMMU configuration Robin Murphy
2015-01-12 20:48 ` [RFC PATCH 3/5] iommu: implement common IOMMU ops for DMA mapping Robin Murphy
[not found] ` <09e5515a9afcb3235f4c425520cd18a6032d31b4.1421086706.git.robin.murphy-5wv7dgnIgG8@public.gmane.org>
2015-01-23 17:42 ` Laura Abbott
[not found] ` <54C287F7.3060603-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org>
2015-01-23 18:14 ` Robin Murphy
2015-01-27 0:21 ` Joerg Roedel
[not found] ` <20150127002116.GI30345-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
2015-01-27 12:27 ` Robin Murphy
[not found] ` <54C7843B.3000605-5wv7dgnIgG8@public.gmane.org>
2015-01-27 12:38 ` Joerg Roedel
[not found] ` <20150127123809.GJ30345-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
2015-01-28 13:53 ` Will Deacon
2015-01-12 20:48 ` [RFC PATCH 4/5] arm64: add IOMMU dma_ops Robin Murphy
[not found] ` <aa7de3b1dd189c31eb8b14d0c0eea699183f8a2c.1421086706.git.robin.murphy-5wv7dgnIgG8@public.gmane.org>
2015-01-23 15:26 ` Will Deacon
[not found] ` <20150123152605.GA31460-5wv7dgnIgG8@public.gmane.org>
2015-01-23 17:33 ` Robin Murphy
2015-01-26 3:25 ` Joseph Lo
[not found] ` <54C5B3B9.1040300-DDmLM1+adcrQT0dZR+AlfA@public.gmane.org>
2015-01-27 17:30 ` Robin Murphy
2015-01-26 9:10 ` Joseph Lo
2015-01-28 2:22 ` Joseph Lo
2015-03-05 14:31 ` Marek Szyprowski
2015-01-12 20:48 ` [RFC PATCH 5/5] arm64: hook up " Robin Murphy
2015-01-13 11:08 ` [RFC PATCH 0/5] arm64: IOMMU-backed DMA mapping Stefano Stabellini
[not found] ` <alpine.DEB.2.02.1501131102540.3058-7Z66fg9igcxYtxbxJUhB2Dgeux46jI+i@public.gmane.org>
2015-01-13 11:45 ` Robin Murphy [this message]
2015-01-23 16:47 ` Catalin Marinas
[not found] ` <20150123164759.GF9557-M2fw3Uu6cmfZROr8t4l/smS4ubULX0JqMm0uRHvK7Nw@public.gmane.org>
2015-01-23 17:41 ` Robin Murphy
2015-03-05 14:31 ` Marek Szyprowski
[not found] ` <54F868A8.7070103-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
2015-03-05 16:42 ` Robin Murphy
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=54B50555.6090803@arm.com \
--to=robin.murphy-5wv7dgnigg8@public.gmane.org \
--cc=Catalin.Marinas-5wv7dgnIgG8@public.gmane.org \
--cc=Will.Deacon-5wv7dgnIgG8@public.gmane.org \
--cc=arnd-r2nGTMty4D4@public.gmane.org \
--cc=dwmw2-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org \
--cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
--cc=linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org \
--cc=linux-lFZ/pmaqli7XmaaqVzeoHQ@public.gmane.org \
--cc=stefano.stabellini-mvvWK6WmYclDPfheJLI6IQ@public.gmane.org \
--cc=thunder.leizhen-hv44wF8Li93QT0dZR+AlfA@public.gmane.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