From: "David Hildenbrand (Arm)" <david@kernel.org>
To: Mike Rapoport <rppt@kernel.org>,
Andrew Morton <akpm@linux-foundation.org>
Cc: "Liam R. Howlett" <liam@infradead.org>,
Michal Hocko <mhocko@suse.com>,
Vlastimil Babka <vbabka@kernel.org>,
linux-kernel@vger.kernel.org, linux-mm@kvack.org,
Sashiko <sashiko-bot@kernel.org>
Subject: Re: [PATCH] mm/cma: fix handling of free ranges that cross 4G for multi-range areas
Date: Wed, 2 Dec 2026 13:43:59 +0100 [thread overview]
Message-ID: <75585a43-4a83-45af-9d13-0056019cb7c5@kernel.org> (raw)
In-Reply-To: <20261202113910.1412130-1-rppt@kernel.org>
On 12/2/26 12:39, Mike Rapoport wrote:
> From: "Mike Rapoport (Microsoft)" <rppt@kernel.org>
>
> Multi-range CMA areas are placed only above 4G. cma_find_free_range()
> enforces this by skipping free ranges that start below 4G, including the
> ranges that cross 4G.
>
> On systems where RAM is contiguous across 4G, like QEMU arm64 virt
> machines with more than 3G of RAM, the largest free range of a node may
> cross 4G. When hugetlb_cma falls back to a multi-range area, it cannot
> use any part of that range and the reservation fails if the remaining
> ranges are too small.
>
> Use the part of such ranges above 4G instead of skipping them.
>
> Comparing a phys_addr_t with SZ_4G causes warnings on 32-bit builds, so
> make cma_find_free_range() a stub that returns 0.
>
> Reported-by: Sashiko <sashiko-bot@kernel.org>
> Closes: https://sashiko.dev/bug/linux-59c2cbb5-4dcf-49a5-90c2-72f5b734d510
> Fixes: c009da4258f9 ("mm, cma: support multiple contiguous ranges, if requested")
> Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Reviewed-by: David Hildenbrand (Arm) <david@kernel.org>
--
Cheers,
David
prev parent reply other threads:[~2026-12-02 12:44 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-12-02 11:39 [PATCH] mm/cma: fix handling of free ranges that cross 4G for multi-range areas Mike Rapoport
2026-12-02 12:43 ` David Hildenbrand (Arm) [this message]
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=75585a43-4a83-45af-9d13-0056019cb7c5@kernel.org \
--to=david@kernel.org \
--cc=akpm@linux-foundation.org \
--cc=liam@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mhocko@suse.com \
--cc=rppt@kernel.org \
--cc=sashiko-bot@kernel.org \
--cc=vbabka@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