]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
When creating a snapshot, create a list of initially allocated blocks.
authorKirk McKusick <mckusick@FreeBSD.org>
Wed, 9 Oct 2002 07:28:35 +0000 (07:28 +0000)
committerKirk McKusick <mckusick@FreeBSD.org>
Wed, 9 Oct 2002 07:28:35 +0000 (07:28 +0000)
commit98d275df37d3c2650776face5e9398e5fa5195dd
treea381ea83bda261c20d982b0381c2f6395abb64b8
parent3f521b6022ea6f9efdb4b388551e4216436cc30a
When creating a snapshot, create a list of initially allocated blocks.
Whenever doing a copy-on-write check, first look in the list of
initially allocated blocks to see if it is there. If so, no further
check is needed. If not, fall through and do the full check. This
change eliminates one of two known deadlocks caused by snapshots.
Handling the second deadlock will be the subject of another check-in.
This change also reduces the cost of the copy-on-write check by
speeding up the verification of frequently checked blocks.

Sponsored by: DARPA & NAI Labs.
sys/ufs/ufs/inode.h