Re: [PATCH] mm/huge_memory: check VMA end bounds in insert_pmd() and insert_pud()
From: David Hildenbrand (Arm)
Date: Thu Nov 26 2026 - 06:23:30 EST
On 11/25/26 23:57, Elkin Cruz wrote:
> On Wed, Nov 25, 2026 at 2:40 PM David Hildenbrand (Arm)
> <david@xxxxxxxxxx> wrote:
>
>> Which users in the tree trigger this?
>
> Very fair point. After a quick check, there are indeed no users in the
> tree that can trigger this.
> Back to the whiteboard. The linter is still too noisy. I will hold off
> sending any more patches :).
>
> Please ignore/drop this patch.
In general, making code more robust is good. But then, please don't use Fixes:
or CC stable because that makes people think that there is an actual problem.
For the code here, couldn't we do something like
if (addr < vma->vm_start ||
addr + HPAGE_PMD_SIZE >= vma->vm_end )
... not sure if we'd have to care about overflows.
--
Cheers,
David