Re: [PATCH 1/2] mm, cma: fix 32-bit warning

From: David Hildenbrand
Date: Mon Feb 24 2025 - 09:44:52 EST


On 24.02.25 15:07, Arnd Bergmann wrote:
From: Arnd Bergmann <arnd@xxxxxxxx>

clang warns about certain always-true conditions, like this one on 32-bit
builds:

mm/cma.c:420:13: error: result of comparison of constant 4294967296 with expression of type 'phys_addr_t' (aka 'unsigned int') is always true [-Werror,-Wtautological-constant-out-of-range-compare]
420 | if (start < SZ_4G)
| ~~~~~ ^ ~~~~~


Hm, so in this case the whole loop is unnecessary.

In any case

Acked-by: David Hildenbrand <david@xxxxxxxxxx>


--
Cheers,

David / dhildenb