Commit bb8451cc authored by Daniel Verkamp's avatar Daniel Verkamp
Browse files

Replace rte_panic() with abort()



Remove a DPDK dependency from generic code.

Change-Id: I8e3e2c0a36d980b426a1967ed1f88fb8b855c382
Signed-off-by: default avatarDaniel Verkamp <daniel.verkamp@intel.com>
parent a8e6c0ae
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -340,7 +340,7 @@ struct spdk_bdev_io *spdk_bdev_get_io(void)
	rc = rte_mempool_get(spdk_bdev_g_io_pool, (void **)&bdev_io);
	if (rc < 0 || !bdev_io) {
		SPDK_ERRLOG("Unable to get spdk_bdev_io\n");
		rte_panic("no memory\n");
		abort();
	}

	memset(bdev_io, 0, sizeof(*bdev_io));
+1 −1
Original line number Diff line number Diff line
@@ -512,7 +512,7 @@ struct spdk_iscsi_pdu *spdk_get_pdu(void)
	rc = rte_mempool_get(g_spdk_iscsi.pdu_pool, (void **)&pdu);
	if ((rc < 0) || !pdu) {
		SPDK_ERRLOG("Unable to get PDU\n");
		rte_panic("no memory\n");
		abort();
	}

	/* we do not want to zero out the last part of the structure reserved for AHS and sense data */
+1 −1
Original line number Diff line number Diff line
@@ -54,7 +54,7 @@ spdk_iscsi_task_get(uint32_t *owner_task_ctr, struct spdk_iscsi_task *parent)
	rc = rte_mempool_get(g_spdk_iscsi.task_pool, (void **)&task);
	if ((rc < 0) || !task) {
		SPDK_ERRLOG("Unable to get task\n");
		rte_panic("no memory\n");
		abort();
	}

	memset(task, 0, sizeof(*task));