btrfs: improve comments around nocow path
authorNikolay Borisov <nborisov@suse.com>
Wed, 21 Aug 2019 07:42:57 +0000 (10:42 +0300)
committerDavid Sterba <dsterba@suse.com>
Mon, 9 Sep 2019 12:59:13 +0000 (14:59 +0200)
commita6bd9cd1559b8e78d1d03fe64445ae6dc419ea16
tree0a3735e4c27a50ad4456bfa2e3ce193e1287b9e0
parent3e024846d241b992ded27fdfdb78ea819abaa0cb
btrfs: improve comments around nocow path

run_delalloc_nocow contains numerous, somewhat subtle, checks when
figuring out whether a particular extent should be CoW'ed or not. This
patch explicitly states the assumptions those checks verify. As a
result also document 2 of the more subtle checks in check_committed_ref
as well.

Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/extent-tree.c
fs/btrfs/inode.c