md/raid5-cache: exclude reclaiming stripes in reclaim check
authorShaohua Li <shli@fb.com>
Sat, 11 Feb 2017 00:18:09 +0000 (16:18 -0800)
committerShaohua Li <shli@fb.com>
Mon, 13 Feb 2017 17:20:05 +0000 (09:20 -0800)
commite33fbb9cc73d6502e69eaf1c178e0c39059763ea
tree3a75c9e524eab2facb854a41e970dfb86fc538c1
parente8fd52eec2cd25b917983b3f3aa738b722522376
md/raid5-cache: exclude reclaiming stripes in reclaim check

stripes which are being reclaimed are still accounted into cached
stripes. The reclaim takes time. r5c_do_reclaim isn't aware of the
stripes and does unnecessary stripe reclaim. In practice, I saw one
stripe is reclaimed one time. This will cause bad IO pattern. Fixing
this by excluding the reclaing stripes in the check.

Cc: Song Liu <songliubraving@fb.com>
Signed-off-by: Shaohua Li <shli@fb.com>
drivers/md/raid5-cache.c
drivers/md/raid5.c
drivers/md/raid5.h