All of lore.kernel.org
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@infradead.org>
To: Yafang Shao <laoar.shao@gmail.com>
Cc: akpm@linux-foundation.org, linux-mm@kvack.org,
	"Kirill A . Shutemov" <kirill.shutemov@linux.intel.com>
Subject: Re: [PATCH] mm, gpu: fix error when FOLL_MLOCK an unpresent page
Date: Mon, 30 Aug 2021 08:00:31 +0100	[thread overview]
Message-ID: <YSyCDxWWvKP2OthC@infradead.org> (raw)
In-Reply-To: <20210829011953.9051-1-laoar.shao@gmail.com>

On Sun, Aug 29, 2021 at 01:19:53AM +0000, Yafang Shao wrote:
> After some analyzation, I found it was caused by a bug in GUP.
> When the kernel module calls get_user_pages() with FOLL_MLOCK being set but
> FOLL_POPULATE being unset, if the page of the user addr isn't present, the

Which is not a valid way to call get_user_pages.  What we need to do is
to reject that case.  No-tree user does this so that bug is what ever
crap out of tree code you're using.


  reply	other threads:[~2021-08-30  7:00 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-29  1:19 [PATCH] mm, gpu: fix error when FOLL_MLOCK an unpresent page Yafang Shao
2021-08-30  7:00 ` Christoph Hellwig [this message]
2021-08-30  9:12   ` Yafang Shao
2021-08-30 10:08     ` Christoph Hellwig
2021-08-30 10:55       ` Yafang Shao
2021-08-31  1:36         ` Kirill A. Shutemov
2021-08-31 12:32           ` Yafang Shao

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YSyCDxWWvKP2OthC@infradead.org \
    --to=hch@infradead.org \
    --cc=akpm@linux-foundation.org \
    --cc=kirill.shutemov@linux.intel.com \
    --cc=laoar.shao@gmail.com \
    --cc=linux-mm@kvack.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.