linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/3] A few gup refactorings and documentation updates
@ 2021-08-08 23:50 John Hubbard
  2021-08-08 23:50 ` [PATCH 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-08 23:50 UTC (permalink / raw)
  To: Andrew Morton, Matthew Wilcox; +Cc: LKML, linux-mm, John Hubbard

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. The try_get_page() in particular seems better now,
even if there are a few more "if" branches in there.

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.

Also, this is based on today's linux-next (next-20210806), in order to
stay reasonably close to mmotm. So I know that this short series doesn't
conflict with the folio-so-far patches in linux-next, anyway.


John Hubbard (3):
  mm/gup: documentation corrections for gup/pup
  mm/gup: small refactoring: simplify try_grab_page()
  mm/gup: refactor and simplify try_get_page()

 include/linux/mm.h | 11 ++++++-----
 mm/gup.c           | 49 ++++++++++++++--------------------------------
 2 files changed, 21 insertions(+), 39 deletions(-)

-- 
2.32.0



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

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

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-08 23:50 [PATCH 0/3] A few gup refactorings and documentation updates John Hubbard
2021-08-08 23:50 ` [PATCH 1/3] mm/gup: documentation corrections for gup/pup John Hubbard
2021-08-09  1:39   ` Matthew Wilcox
2021-08-09  6:46     ` John Hubbard
2021-08-10 21:19     ` John Hubbard
2021-08-08 23:50 ` [PATCH 2/3] mm/gup: small refactoring: simplify try_grab_page() John Hubbard
2021-08-09  6:38   ` Christoph Hellwig
2021-08-09  6:46     ` John Hubbard
2021-08-08 23:50 ` [PATCH 3/3] mm/gup: refactor and simplify try_get_page() John Hubbard
2021-08-09  6:29   ` Christoph Hellwig
2021-08-09  6:36     ` 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).