lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <3c223f62-4aca-4b7d-82e6-a1fbf758de26@lucifer.local>
Date: Tue, 29 Jul 2025 13:32:10 +0100
From: Lorenzo Stoakes <lorenzo.stoakes@...cle.com>
To: Harry Yoo <harry.yoo@...cle.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>, Mike Rapoport <rppt@...nel.org>,
        David Hildenbrand <david@...hat.com>,
        "Liam R . Howlett" <Liam.Howlett@...cle.com>,
        Vlastimil Babka <vbabka@...e.cz>,
        Suren Baghdasaryan <surenb@...gle.com>, Michal Hocko <mhocko@...e.com>,
        Jann Horn <jannh@...gle.com>, Pedro Falcato <pfalcato@...e.de>,
        linux-mm@...ck.org, linux-kernel@...r.kernel.org,
        Uladzislau Rezki <urezki@...il.com>
Subject: Re: [PATCH] mm: correct type for vmalloc vm_flags fields

On Tue, Jul 29, 2025 at 09:10:50PM +0900, Harry Yoo wrote:
> I see one more thing in patch 3 of the series:

Can we please try to do this review closer to the series in future, and
ideally in one go. Doing things this way isn't helpful.

While you're right (this function is just awful, no wonder - struct
vm_struct vma...!), the vm_flags_t series is in NO WAY broken, since
vm_flags_t == unsigned long.

I expect there to be a few 'stragglers' of one kind or another, when I do
the next stage of the work _all such callers_ will be detected (as the
kernel will not compile otherwise).

Anyway of course we should fix this, the TL; DR is this isn't an urgent
fix.

I'll send a fix-patch.

>
> diff --git a/arch/arm64/mm/mmu.c b/arch/arm64/mm/mmu.c
> index 8fcf59ba39db..248d96349fd0 100644
> --- a/arch/arm64/mm/mmu.c
> +++ b/arch/arm64/mm/mmu.c
> @@ -720,7 +720,7 @@ void mark_rodata_ro(void)
>
>  static void __init declare_vma(struct vm_struct *vma,

^ this is beyond appalling.

Somebody from arm side should really fix this because this is just insane.

>  			       void *va_start, void *va_end,
> -			       unsigned long vm_flags)
> +			       vm_flags_t vm_flags)
>  {
>  	phys_addr_t pa_start = __pa_symbol(va_start);
>  	unsigned long size = va_end - va_start;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ