From: Michal Privoznik Date: Thu, 28 Feb 2019 16:43:57 +0000 (+0100) Subject: virISCSIDirectReportLuns: Drop ClearVols X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=f8aecea77903aa1fbed8b5ca22bc82086d4ece1f;p=libvirt.git virISCSIDirectReportLuns: Drop ClearVols In bf5cf610f206d5d54 I've fixed a problem where iscsi-direct backend was reporting only the last LUN. The fix consisted of moving virStoragePoolObjClearVols() one level up. However, as it turns out, storage driver already calls it before calling refreshPool callback (which is virStorageBackendISCSIDirectRefreshPool() in this case). Signed-off-by: Michal Privoznik Reviewed-by: Pavel Hrdina --- diff --git a/src/storage/storage_backend_iscsi_direct.c b/src/storage/storage_backend_iscsi_direct.c index fc161e6833..6283a2836b 100644 --- a/src/storage/storage_backend_iscsi_direct.c +++ b/src/storage/storage_backend_iscsi_direct.c @@ -375,7 +375,6 @@ virISCSIDirectReportLuns(virStoragePoolObjPtr pool, def->capacity = 0; def->allocation = 0; - virStoragePoolObjClearVols(pool); for (i = 0; i < list->num; i++) { if (virISCSIDirectRefreshVol(pool, iscsi, list->luns[i], portal) < 0) goto cleanup;