From: will.deacon@arm.com (Will Deacon)
To: linux-arm-kernel@lists.infradead.org
Subject: Warnings in arch/arm64/mm/dma-mapping.c
Date: Tue, 30 Oct 2018 10:13:42 +0000 [thread overview]
Message-ID: <20181030101342.GC19955@arm.com> (raw)
In-Reply-To: <20181030074344.GA24697@lst.de>
On Tue, Oct 30, 2018 at 08:43:44AM +0100, Christoph Hellwig wrote:
> On Mon, Oct 29, 2018 at 04:51:47PM -0700, Florian Fainelli wrote:
> > I have not a chance to run a bisection yet, but I suspect this is coming
> > from Christoph's latest batch of DMA-API changes in ARM64 under the
> > merge commit befa93633193e5327e4045d1e5fa29114580fa5d ("Merge tag
> > 'dma-mapping-4.20-1' of git://git.infradead.org/users/hch/dma-mapping"),
> > here are the warnings:
>
> This should fix it:
Tested-by: Will Deacon <will.deacon@arm.com>
I guess Catalin can pick this up for -rc1, since there's also the kprobes
RO fix kicking around for arm64?
Will
> ---
> From 773c5e097c5cf3868443ffb79ae64d79f70e3ccf Mon Sep 17 00:00:00 2001
> From: Christoph Hellwig <hch@lst.de>
> Date: Tue, 30 Oct 2018 09:41:29 +0200
> Subject: arm64: fix warnings without CONFIG_IOMMU_DMA
>
> __swiotlb_get_sgtable_page and __swiotlb_mmap_pfn are not only misnamed
> but also only used if CONFIG_IOMMU_DMA is set. Just add a simple ifdef
> for now, given that we plan to remove them entirely for the next merge
> window.
>
> Reported-by: Florian Fainelli <f.fainelli@gmail.com>
> Signed-off-by: Christoph Hellwig <hch@lst.de>
> ---
> arch/arm64/mm/dma-mapping.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/arch/arm64/mm/dma-mapping.c b/arch/arm64/mm/dma-mapping.c
> index d190612b8f33..560756a7290e 100644
> --- a/arch/arm64/mm/dma-mapping.c
> +++ b/arch/arm64/mm/dma-mapping.c
> @@ -160,6 +160,7 @@ void arch_sync_dma_for_cpu(struct device *dev, phys_addr_t paddr,
> __dma_unmap_area(phys_to_virt(paddr), size, dir);
> }
>
> +#ifdef CONFIG_IOMMU_DMA
> static int __swiotlb_get_sgtable_page(struct sg_table *sgt,
> struct page *page, size_t size)
> {
> @@ -188,6 +189,7 @@ static int __swiotlb_mmap_pfn(struct vm_area_struct *vma,
>
> return ret;
> }
> +#endif /* CONFIG_IOMMU_DMA */
>
> static int __init atomic_pool_init(void)
> {
> --
> 2.19.1
>
next prev parent reply other threads:[~2018-10-30 10:13 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <a771d5ce-28a2-609e-5fd7-338fadc20743@gmail.com>
2018-10-30 7:43 ` Warnings in arch/arm64/mm/dma-mapping.c Christoph Hellwig
2018-10-30 10:13 ` Will Deacon [this message]
2018-10-30 17:10 ` Florian Fainelli
2018-11-02 17:47 ` Catalin Marinas
2018-11-02 18:26 ` Christoph Hellwig
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=20181030101342.GC19955@arm.com \
--to=will.deacon@arm.com \
--cc=linux-arm-kernel@lists.infradead.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).