Re: [PATCH] mm/gup: don't permit users to call get_user_pages with FOLL_LONGTERM

From: Souptick Joarder
Date: Fri Sep 04 2020 - 21:18:00 EST


On Fri, Sep 4, 2020 at 12:09 AM Matthew Wilcox <willy@xxxxxxxxxxxxx> wrote:
>
> On Thu, Sep 03, 2020 at 12:42:44PM +0530, Souptick Joarder wrote:
> > We can use is_valid_gup_flags() inside ->
> > get_user_pages_locked(),
> > get_user_pages_unlocked(),
> > pin_user_pages_locked() as well.
> >
> > Are you planning to add it in future patches ?
>
> If you're looking for a new project, adding a foll_t or gup_t or
> something for the FOLL flags (like we have for gfp_t or vm_fault_t)
> would be helpful. We're inconsistent with our naming here.

Sure. I will start looking into this and come up with a RFC version.