Commit ef282937 authored by Artur Paszkiewicz's avatar Artur Paszkiewicz Committed by Tomasz Zawadzki
Browse files

raid: in examine ignore bdevs that are already raid members



Fixes: #3314

Signed-off-by: default avatarArtur Paszkiewicz <artur.paszkiewicz@intel.com>
Change-Id: If514b713966ecbd5c5fa7dc93981b0a8c418f23d
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/22487


Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
Community-CI: Mellanox Build Bot
Reviewed-by: default avatarShuhei Matsumoto <smatsumoto@nvidia.com>
Reviewed-by: default avatarJim Harris <jim.harris@samsung.com>
parent f34b13ec
Loading
Loading
Loading
Loading
+6 −2
Original line number Diff line number Diff line
@@ -3514,10 +3514,13 @@ raid_bdev_examine(struct spdk_bdev *bdev)
	struct raid_bdev_examine_ctx *ctx;
	int rc;

	if (raid_bdev_find_base_info_by_bdev(bdev) != NULL) {
		goto done;
	}

	if (spdk_bdev_get_dif_type(bdev) != SPDK_DIF_DISABLE) {
		raid_bdev_examine_no_sb(bdev);
		spdk_bdev_module_examine_done(&g_raid_if);
		return;
		goto done;
	}

	ctx = calloc(1, sizeof(*ctx));
@@ -3551,6 +3554,7 @@ raid_bdev_examine(struct spdk_bdev *bdev)
	return;
err:
	raid_bdev_examine_ctx_free(ctx);
done:
	spdk_bdev_module_examine_done(&g_raid_if);
}