md: initialize percpu refcounters using PERCU_REF_ALLOW_REINIT
authorRoman Gushchin <guro@fb.com>
Tue, 7 May 2019 17:01:49 +0000 (10:01 -0700)
committerDennis Zhou <dennis@kernel.org>
Thu, 9 May 2019 17:50:59 +0000 (10:50 -0700)
commitddde2af747ad79010f14691f381522987fbcb860
tree6e2b6287133d7ae7f2a49ba3f1a4dc014933806c
parent214828962dead0c698f92b60ef97ce3c5fc2c8fe
md: initialize percpu refcounters using PERCU_REF_ALLOW_REINIT

Percpu reference counters should now be initialized with the
PERCPU_REF_ALLOW_REINIT in order to allow switching them to the
percpu mode from the atomic mode.
To make percpu_ref_switch_to_percpu() call in set_in_sync()
succeed,let's initialize percpu refcounters with the
PERCU_REF_ALLOW_REINIT flag.

Signed-off-by: Roman Gushchin <guro@fb.com>
Acked-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Dennis Zhou <dennis@kernel.org>
drivers/md/md.c