mm: Don't pin ZERO_PAGE in pin_user_pages()
[linux-block.git] / Documentation / core-api / pin_user_pages.rst
index 9fb0b1080d3b8cc7ae142fda425ebd01fe64ed0c..d3c1f6d8c0e0ec819843ad11bea22cad9614e657 100644 (file)
@@ -112,6 +112,12 @@ pages:
 This also leads to limitations: there are only 31-10==21 bits available for a
 counter that increments 10 bits at a time.
 
+* Because of that limitation, special handling is applied to the zero pages
+  when using FOLL_PIN.  We only pretend to pin a zero page - we don't alter its
+  refcount or pincount at all (it is permanent, so there's no need).  The
+  unpinning functions also don't do anything to a zero page.  This is
+  transparent to the caller.
+
 * Callers must specifically request "dma-pinned tracking of pages". In other
   words, just calling get_user_pages() will not suffice; a new set of functions,
   pin_user_page() and related, must be used.