From: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
To: Qian Cai <cai@lca.pw>
Cc: linux-rpi-kernel@lists.infradead.org, f.fainelli@gmail.com,
will@kernel.org, marc.zyngier@arm.com, catalin.marinas@arm.com,
linux-kernel@vger.kernel.org, Rob Herring <robh+dt@kernel.org>,
linux-mm@kvack.org, mbrugger@suse.com, wahrenst@gmx.net,
phill@raspberrypi.org, robin.murphy@arm.com,
Christoph Hellwig <hch@lst.de>,
linux-arm-kernel@lists.infradead.org, m.szyprowski@samsung.com
Subject: Re: [PATCH v6 3/4] arm64: use both ZONE_DMA and ZONE_DMA32
Date: Mon, 21 Oct 2019 16:34:58 +0200 [thread overview]
Message-ID: <78caa5bcfc0d59e8ec5d6b7060df76896d25248b.camel@suse.de> (raw)
In-Reply-To: <3956E54B-6C7A-4C47-B9B6-75F556EFD3F5@lca.pw>
[-- Attachment #1.1: Type: text/plain, Size: 1572 bytes --]
On Mon, 2019-10-21 at 10:15 -0400, Qian Cai wrote:
> > On Sep 11, 2019, at 2:25 PM, Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> > wrote:
> >
> > So far all arm64 devices have supported 32 bit DMA masks for their
> > peripherals. This is not true anymore for the Raspberry Pi 4 as most of
> > it's peripherals can only address the first GB of memory on a total of
> > up to 4 GB.
> >
> > This goes against ZONE_DMA32's intent, as it's expected for ZONE_DMA32
> > to be addressable with a 32 bit mask. So it was decided to re-introduce
> > ZONE_DMA in arm64.
> >
> > ZONE_DMA will contain the lower 1G of memory, which is currently the
> > memory area addressable by any peripheral on an arm64 device.
> > ZONE_DMA32 will contain the rest of the 32 bit addressable memory.
> >
> > Signed-off-by: Nicolas Saenz Julienne <nsaenzjulienne@suse.de>
> > Reviewed-by: Catalin Marinas <catalin.marinas@arm.com>
> >
> > ---
>
> With ZONE_DMA=y, this config will fail to reserve 512M CMA on a server,
>
> https://raw.githubusercontent.com/cailca/linux-mm/master/arm64.config
>
> CONFIG_DMA_CMA=y
> CONFIG_CMA_SIZE_MBYTES=64
> CONFIG_CMA_SIZE_SEL_MBYTES=y
> CONFIG_CMA_ALIGNMENT=8
> CONFIG_CMA=y
> CONFIG_CMA_DEBUGFS=y
> CONFIG_CMA_AREAS=7
>
> Is this expected?
Not really, just tested cma=512M on a Raspberry Pi4, and it went well. The only
thing on my build that differs from your config is CONFIG_CMA_DEBUGFS.
Could you post more information on the device you're experiencing this on? Also
some logs.
Regards,
Nicolas
[-- Attachment #1.2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2019-10-21 14:35 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-11 18:25 [PATCH v6 0/4] Raspberry Pi 4 DMA addressing support Nicolas Saenz Julienne
2019-09-11 18:25 ` [PATCH v6 1/4] arm64: mm: use arm64_dma_phys_limit instead of calling max_zone_dma_phys() Nicolas Saenz Julienne
2019-09-11 18:25 ` [PATCH v6 2/4] arm64: rename variables used to calculate ZONE_DMA32's size Nicolas Saenz Julienne
2019-09-11 18:25 ` [PATCH v6 3/4] arm64: use both ZONE_DMA and ZONE_DMA32 Nicolas Saenz Julienne
2019-10-21 14:15 ` Qian Cai
2019-10-21 14:34 ` Nicolas Saenz Julienne [this message]
2019-10-21 14:46 ` Qian Cai
2019-10-21 17:01 ` Nicolas Saenz Julienne
2019-10-21 17:25 ` Qian Cai
2019-10-21 17:55 ` Nicolas Saenz Julienne
2019-10-21 20:36 ` Qian Cai
2019-10-22 11:23 ` Nicolas Saenz Julienne
2019-10-23 7:11 ` Matthias Brugger
2019-10-31 15:51 ` Catalin Marinas
2019-10-31 16:04 ` Nicolas Saenz Julienne
2019-10-31 18:02 ` Catalin Marinas
2019-10-31 18:11 ` Nicolas Saenz Julienne
2019-10-31 18:13 ` Catalin Marinas
2019-12-03 5:08 ` John Stultz
2019-12-03 5:38 ` John Stultz
2019-12-03 6:03 ` John Stultz
2019-12-03 10:12 ` Will Deacon
2019-12-03 11:19 ` Catalin Marinas
2019-09-11 18:25 ` [PATCH v6 4/4] mm: refresh ZONE_DMA and ZONE_DMA32 comments in 'enum zone_type' Nicolas Saenz Julienne
2019-10-01 16:05 ` [PATCH v6 0/4] Raspberry Pi 4 DMA addressing support Catalin Marinas
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=78caa5bcfc0d59e8ec5d6b7060df76896d25248b.camel@suse.de \
--to=nsaenzjulienne@suse.de \
--cc=cai@lca.pw \
--cc=catalin.marinas@arm.com \
--cc=f.fainelli@gmail.com \
--cc=hch@lst.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=m.szyprowski@samsung.com \
--cc=marc.zyngier@arm.com \
--cc=mbrugger@suse.com \
--cc=phill@raspberrypi.org \
--cc=robh+dt@kernel.org \
--cc=robin.murphy@arm.com \
--cc=wahrenst@gmx.net \
--cc=will@kernel.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).