]> git.baikalelectronics.ru Git - kernel.git/commit
md: don't clear MD_CHANGE_CLEAN in md_update_sb() for external arrays
authorDan Williams <dan.j.williams@intel.com>
Mon, 30 Aug 2010 07:33:33 +0000 (17:33 +1000)
committerNeilBrown <neilb@suse.de>
Mon, 30 Aug 2010 08:06:20 +0000 (18:06 +1000)
commit418d0a7503c96d024f0a523be2bddeeb50bf37d4
tree5ee5789f1aae4b238d42c05672db90886b19280e
parent786134b081f1011d8bbcc86a0a6db5c781459fa8
md: don't clear MD_CHANGE_CLEAN in md_update_sb() for external arrays

If this bit is cleared in md_update_sb() the kernel will allow writes to the
array if userspace triggers md_allow_write(), e.g. through stripe_cache_size,
when mdmon is not active.  When mdmon is active the array transitions to
active-idle bypassing write-pending, setting up a race for mdmon to set the
array clean before a write arrives.

Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Signed-off-by: NeilBrown <neilb@suse.de>
drivers/md/md.c