[PATCH v2 1/2] lightnvm: hold lock until finish the target creation

2016-05-23 Thread Wenwei Tao
From: Wenwei Tao When create a target, we check whether the target is already exist first. If the answer is no, we release the lock and continue the creation. This cannot prevent concurrent creation of the same target, so hold the lock until finish the target creation.

[PATCH v2 1/2] lightnvm: hold lock until finish the target creation

2016-05-23 Thread Wenwei Tao
From: Wenwei Tao When create a target, we check whether the target is already exist first. If the answer is no, we release the lock and continue the creation. This cannot prevent concurrent creation of the same target, so hold the lock until finish the target creation. Signed-off-by: Wenwei Tao