linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/3] A few gup refactorings and documentation updates
@ 2021-08-11  7:05 John Hubbard
  2021-08-11  7:05 ` [PATCH v2 1/3] mm/gup: documentation corrections for gup/pup John Hubbard
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: John Hubbard @ 2021-08-11  7:05 UTC (permalink / raw)
  To: Andrew Morton
  Cc: Heiko Carstens, Vasily Gorbik, Christian Borntraeger, LKML,
	linux-mm, linux-s390, linux-fsdevel, John Hubbard

OK, here is v2 with changes as recommended by Christoph Hellwig and
Matthew Wilcox (thanks!):

* Changed refs to @refs, and added some more documentation as well.

* Completely removed try_get_page(). (I'm adding more people and lists
to Cc, because of those call site changes.)

* Reversed the logic in try_grab_page() to make it a touch more
  readable.

Also, this has been rebased to today's linux-next (next-20210810), and
re-tested on that.

Here is the v1 cover letter, edited slightly to keep up with the latest
story.

While reviewing some of the other things going on around gup.c, I
noticed that the documentation was wrong for a few of the routines that
I wrote. And then I noticed that there was some significant code
duplication too. So this fixes those issues.

This is not entirely risk-free, but after looking closely at this, I
think it's actually a useful improvement, getting rid of the code
duplication here.

However, it is possible I've overlooked something. I did some local LTP
and other testing on an x86 test machine but failed to find any problems
yet.

And the original v1 is here:
https://lore.kernel.org/r/20210808235018.1924918-1-jhubbard@nvidia.com

John Hubbard (3):
  mm/gup: documentation corrections for gup/pup
  mm/gup: small refactoring: simplify try_grab_page()
  mm/gup: Remove try_get_page(), call try_get_compound_head() directly

 arch/s390/mm/fault.c |  2 +-
 fs/pipe.c            |  2 +-
 include/linux/mm.h   | 10 +-----
 mm/gup.c             | 79 ++++++++++++++++++++++----------------------
 4 files changed, 43 insertions(+), 50 deletions(-)

--
2.32.0


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2021-08-12 21:59 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-11  7:05 [PATCH v2 0/3] A few gup refactorings and documentation updates John Hubbard
2021-08-11  7:05 ` [PATCH v2 1/3] mm/gup: documentation corrections for gup/pup John Hubbard
2021-08-11  7:05 ` [PATCH v2 2/3] mm/gup: small refactoring: simplify try_grab_page() John Hubbard
2021-08-12  9:20   ` Christoph Hellwig
2021-08-12 21:59     ` John Hubbard
2021-08-11  7:05 ` [PATCH v2 3/3] mm/gup: Remove try_get_page(), call try_get_compound_head() directly John Hubbard
2021-08-11 20:35   ` William Kucharski
2021-08-11 22:07     ` John Hubbard
2021-08-12  2:17       ` William Kucharski
2021-08-12  9:22   ` Christoph Hellwig
2021-08-12 18:19     ` John Hubbard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).