[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160608120829.GB16322@e104818-lin.cambridge.arm.com>
Date: Wed, 8 Jun 2016 13:08:29 +0100
From: Catalin Marinas <catalin.marinas@....com>
To: Jisheng Zhang <jszhang@...vell.com>
Cc: will.deacon@....com, linux-kernel@...r.kernel.org,
linux-arm-kernel@...ts.infradead.org, Arnd Bergmann <arnd@...db.de>
Subject: Re: [PATCH] arm64: mm: only initialize swiotlb when necessary
On Wed, Jun 08, 2016 at 03:53:46PM +0800, Jisheng Zhang wrote:
> static int __init arm64_dma_init(void)
> {
> + if (swiotlb_force || max_pfn > (arm64_dma_phys_limit >> PAGE_SHIFT))
> + swiotlb = 1;
> +
> return atomic_pool_init();
> }
So any platform with RAM larger than 4GB would still initialise swiotlb.
I wouldn't say it's an issue, 64MB is not a significant loss on such
systems.
An alternative would be to defer the freeing until we are aware of all
possible dma masks for the populated devices (e.g. from DT), though I'm
not sure that's enough, drivers may try to change such masks when
probed.
--
Catalin
Powered by blists - more mailing lists