Author: markj
Date: Wed Oct 23 18:00:22 2019
New Revision: 353957
URL: https://svnweb.freebsd.org/changeset/base/353957

Log:
  Check for bogus_page in vnode_pager_generic_getpages_done().
  
  We now assert that a page is busy when updating its validity-tracking
  state, but bogus_page is not busied during a getpages operation.
  
  Reported by:  syzkaller
  Reviewed by:  alc, kib
  Discussed with:       jeff
  MFC after:    1 week
  Sponsored by: The FreeBSD Foundation
  Differential Revision:        https://reviews.freebsd.org/D22124

Modified:
  head/sys/vm/vnode_pager.c

Modified: head/sys/vm/vnode_pager.c
==============================================================================
--- head/sys/vm/vnode_pager.c   Wed Oct 23 17:58:19 2019        (r353956)
+++ head/sys/vm/vnode_pager.c   Wed Oct 23 18:00:22 2019        (r353957)
@@ -1149,6 +1149,8 @@ vnode_pager_generic_getpages_done(struct buf *bp)
 
                nextoff = tfoff + PAGE_SIZE;
                mt = bp->b_pages[i];
+               if (mt == bogus_page)
+                       continue;
 
                if (nextoff <= object->un_pager.vnp.vnp_size) {
                        /*
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to