Re: [PATCH v5 5/8] mm/gup: break out gup_lookup_pte() helper
From: Rik van Riel
Date: Thu Nov 19 2026 - 22:04:22 EST
On Tue, 2026-11-17 at 13:48 +0000, Lorenzo Stoakes (ARM) wrote:
>
> > + need_no_page_table = true;
>
> This is set true but not used anywhere? This is dead code no? Am I
> missing
> something?
>
> Patches should be incremental but adding completely useless locals
> incrementally
> seems silly?
>
> > + }
> > +
> > pte_unmap_unlock(ptep, ptl);
> > return ret;
>
> I'm guessing you forgot to include the code that works with
> need_no_page_table here?
That code is in patch 7. The check isn't needed
yet in patch 5, and it got shuffled wrong during
some refactoring.
In v6 the need_no_page_table thing will be in
patch 7.
>
> 'need_no_page_table' isn't a great name either. Maybe is_none or
> something?
>
Maybe pte_is_none?
--
All Rights Reversed.