]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Both cluster_rbuild() and cluster_wbuild() sometimes set the pages
authorKonstantin Belousov <kib@FreeBSD.org>
Thu, 22 Aug 2013 18:26:45 +0000 (18:26 +0000)
committerKonstantin Belousov <kib@FreeBSD.org>
Thu, 22 Aug 2013 18:26:45 +0000 (18:26 +0000)
commit4f8cf6e59bc6d3c0f1a750d046906b68cdd160fb
treeefcf3b91736a972d4bd20694ca316b8ef94611b6
parente68c64f0ba0ee7ad39dd68589c87e5f8c873f627
Both cluster_rbuild() and cluster_wbuild() sometimes set the pages
shared busy without first draining the hard busy state.  Previously it
went unnoticed since VPO_BUSY and m->busy fields were distinct, and
vm_page_io_start() did not verified that the passed page has VPO_BUSY
flag cleared, but such page state is wrong.  New implementation is
more strict and catched this case.

Drain the busy state as needed, before calling vm_page_sbusy().

Tested by: pho, jkim
Sponsored by: The FreeBSD Foundation
sys/kern/vfs_bio.c
sys/kern/vfs_cluster.c
sys/sys/buf.h