lkml.org 
[lkml]   [2017]   [Feb]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH/RFC] arm64: defconfig: Enlarge CMA alignment to 2 MiB
Hi Geert,

On Sat, Jan 28, 2017 at 1:03 AM, Geert Uytterhoeven
<geert+renesas@glider.be> wrote:
> Some IOMMUs (e.g. Renesas IPMMU/VMSA) support only page sizes of 4 KiB,
> 2 MiB, and 1 GiB.
>
> With the default setting of CONFIG_CMA_ALIGNMENT = 8, allocations larger
> than 1 MiB are aligned to a 1 MiB boundary only. Hence a 2 MiB
> allocation may not be aligned, leading to a mapping of 512 4 KiB pages.
>
> Increase CONFIG_CMA_ALIGNMENT to allow mapping a 2 MiB buffer using a
> single PTE, decreasing memory usage and TLB pressure.
>
> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be>
> ---
> Is this useful?
>
> Should there instead be different defaults in Kconfig, depending on
> enabled platform support?

I think there is a dependency on the kernel page size configuration as
well. In case of 16 KiB or 64 KiB page size configuration other large
page sizes may be required.

Thanks,

/ magnus

\
 
 \ /
  Last update: 2017-02-01 14:46    [W:0.062 / U:4.040 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site