nvme: Call the probe_cb if a device isn't claimed
If the first call to spdk_nvme_probe probes a device and the driver elects not to take it, still call the probe callback for that device on subsequence calls to spdk_nvme_probe. Change-Id: If06467cf6796c827a0bbfba6e36d5b91534526fc Signed-off-by: Ben Walker <benjamin.walker@intel.com>
This commit is contained in:
parent
11ef5d396b
commit
7473d6b37c
@ -127,13 +127,6 @@ spdk_pci_enumerate(struct spdk_pci_enum_ctx *ctx,
|
||||
ctx->cb_fn = enum_cb;
|
||||
ctx->cb_arg = enum_ctx;
|
||||
|
||||
if (rte_eal_pci_scan() != 0) {
|
||||
ctx->cb_arg = NULL;
|
||||
ctx->cb_fn = NULL;
|
||||
pthread_mutex_unlock(&ctx->mtx);
|
||||
return -1;
|
||||
}
|
||||
|
||||
if (rte_eal_pci_probe() != 0) {
|
||||
ctx->cb_arg = NULL;
|
||||
ctx->cb_fn = NULL;
|
||||
|
@ -429,15 +429,13 @@ _spdk_nvme_probe(const struct spdk_nvme_transport_id *trid, void *cb_ctx,
|
||||
if (hotplug_fd < 0) {
|
||||
SPDK_ERRLOG("Failed to open uevent netlink socket\n");
|
||||
}
|
||||
|
||||
nvme_transport_ctrlr_scan(trid, cb_ctx, probe_cb, remove_cb);
|
||||
} else {
|
||||
nvme_hotplug_monitor(cb_ctx, probe_cb, attach_cb, remove_cb);
|
||||
}
|
||||
} else {
|
||||
nvme_transport_ctrlr_scan(trid, cb_ctx, probe_cb, remove_cb);
|
||||
}
|
||||
|
||||
nvme_transport_ctrlr_scan(trid, cb_ctx, probe_cb, remove_cb);
|
||||
|
||||
if (!spdk_process_is_primary()) {
|
||||
TAILQ_FOREACH(ctrlr, &g_spdk_nvme_driver->attached_ctrlrs, tailq) {
|
||||
nvme_ctrlr_proc_get_ref(ctrlr);
|
||||
|
Loading…
Reference in New Issue
Block a user