lvol: fix lvol store examine when no lvols present
When there are no lvols present on lvol store spdk_bdev_module_examine_done function is not called when tasting is done. Signed-off-by: Maciej Szwed <maciej.szwed@intel.com> Change-Id: Ia6c559f392148e3b4444dbc547df462bbe02356d Reviewed-on: https://review.gerrithub.io/388402 Tested-by: SPDK Automated Test System <sys_sgsw@intel.com> Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com> Signed-off-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com> Reviewed-on: https://review.gerrithub.io/388587 Reviewed-by: Dariusz Stojaczyk <dariuszx.stojaczyk@intel.com>
This commit is contained in:
parent
b08ab084af
commit
574af757ca
@ -848,9 +848,14 @@ _vbdev_lvs_examine_cb(void *arg, struct spdk_lvol_store *lvol_store, int lvserrn
|
||||
|
||||
lvol_store->lvols_opened = 0;
|
||||
|
||||
/* Open all lvols */
|
||||
TAILQ_FOREACH_SAFE(lvol, &lvol_store->lvols, link, tmp) {
|
||||
spdk_lvol_open(lvol, _vbdev_lvs_examine_finish, lvol_store);
|
||||
if (TAILQ_EMPTY(&lvol_store->lvols)) {
|
||||
SPDK_INFOLOG(SPDK_TRACE_VBDEV_LVOL, "Lvol store examination done\n");
|
||||
spdk_bdev_module_examine_done(SPDK_GET_BDEV_MODULE(lvol));
|
||||
} else {
|
||||
/* Open all lvols */
|
||||
TAILQ_FOREACH_SAFE(lvol, &lvol_store->lvols, link, tmp) {
|
||||
spdk_lvol_open(lvol, _vbdev_lvs_examine_finish, lvol_store);
|
||||
}
|
||||
}
|
||||
|
||||
end:
|
||||
|
Loading…
Reference in New Issue
Block a user