From: Nipun Gupta <nipun.gupta@nxp.com>
To: <dev@dpdk.org>
Cc: <hemant.agrawal@nxp.com>, <jerin.jacob@caviumnetworks.com>,
<nikhil.rao@intel.com>, Nipun Gupta <nipun.gupta@nxp.com>
Subject: [dpdk-dev] [PATCH v4 5/5] event/dpaa2: improve the err handling and log msg
Date: Tue, 17 Oct 2017 22:08:34 +0530 [thread overview]
Message-ID: <1508258314-11151-5-git-send-email-nipun.gupta@nxp.com> (raw)
In-Reply-To: <1508258314-11151-1-git-send-email-nipun.gupta@nxp.com>
Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com>
Acked-by: Hemant Agrawal <hemant.agrawal@nxp.com>
---
drivers/event/dpaa2/dpaa2_eventdev.c | 9 +++++++++
drivers/event/dpaa2/dpaa2_hw_dpcon.c | 2 +-
2 files changed, 10 insertions(+), 1 deletion(-)
diff --git a/drivers/event/dpaa2/dpaa2_eventdev.c b/drivers/event/dpaa2/dpaa2_eventdev.c
index ee3a164..d1be5de 100644
--- a/drivers/event/dpaa2/dpaa2_eventdev.c
+++ b/drivers/event/dpaa2/dpaa2_eventdev.c
@@ -140,11 +140,20 @@
*/
struct rte_event *ev_temp = rte_malloc(NULL,
sizeof(struct rte_event), 0);
+
+ if (!ev_temp) {
+ if (!loop)
+ return num_tx;
+ frames_to_send = loop;
+ PMD_DRV_LOG(ERR, "Unable to allocate memory");
+ goto send_partial;
+ }
rte_memcpy(ev_temp, event, sizeof(struct rte_event));
DPAA2_SET_FD_ADDR((&fd_arr[loop]), ev_temp);
DPAA2_SET_FD_LEN((&fd_arr[loop]),
sizeof(struct rte_event));
}
+send_partial:
loop = 0;
while (loop < frames_to_send) {
loop += qbman_swp_enqueue_multiple_desc(swp,
diff --git a/drivers/event/dpaa2/dpaa2_hw_dpcon.c b/drivers/event/dpaa2/dpaa2_hw_dpcon.c
index 2c416b5..005e623 100644
--- a/drivers/event/dpaa2/dpaa2_hw_dpcon.c
+++ b/drivers/event/dpaa2/dpaa2_hw_dpcon.c
@@ -100,7 +100,7 @@
TAILQ_INSERT_TAIL(&dpcon_dev_list, dpcon_node, next);
- PMD_DRV_LOG(DEBUG, "DPAA2: Added [dpcon.%d]", dpcon_id);
+ RTE_LOG(DEBUG, PMD, "DPAA2: Added [dpcon.%d]\n", dpcon_id);
return 0;
}
--
1.9.1
next prev parent reply other threads:[~2017-10-17 10:23 UTC|newest]
Thread overview: 37+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-10-10 17:51 [dpdk-dev] [PATCH 1/4] drivers: add queue parameter in event processing callback Nipun Gupta
2017-10-10 17:51 ` [dpdk-dev] [PATCH 2/4] net/dpaa2: add API's to support event eth adapter Nipun Gupta
2017-10-10 17:51 ` [dpdk-dev] [PATCH 3/4] event/dpaa2: " Nipun Gupta
2017-10-11 3:45 ` Rao, Nikhil
2017-10-11 11:03 ` Nipun Gupta
2017-10-11 4:10 ` Rao, Nikhil
2017-10-11 11:03 ` Nipun Gupta
2017-10-10 17:51 ` [dpdk-dev] [PATCH 4/4] event/dpaa2: improve the err handling and log msg Nipun Gupta
2017-10-12 17:18 ` [dpdk-dev] [PATCH v2 1/4] drivers: add queue parameter in event processing callback Nipun Gupta
2017-10-12 17:18 ` [dpdk-dev] [PATCH v2 2/4] net/dpaa2: add API's to support event eth adapter Nipun Gupta
2017-10-13 14:55 ` Hemant Agrawal
2017-10-12 17:18 ` [dpdk-dev] [PATCH v2 3/4] event/dpaa2: " Nipun Gupta
2017-10-13 5:57 ` Rao, Nikhil
2017-10-13 14:52 ` Hemant Agrawal
2017-10-12 17:18 ` [dpdk-dev] [PATCH v2 4/4] event/dpaa2: improve the err handling and log msg Nipun Gupta
2017-10-13 14:52 ` Hemant Agrawal
2017-10-13 14:48 ` [dpdk-dev] [PATCH v2 1/4] drivers: add queue parameter in event processing callback Hemant Agrawal
2017-10-16 21:44 ` [dpdk-dev] [PATCH v3 " Nipun Gupta
2017-10-16 21:44 ` [dpdk-dev] [PATCH v3 2/4] net/dpaa2: add API's to support event eth adapter Nipun Gupta
2017-10-16 21:44 ` [dpdk-dev] [PATCH v3 3/4] event/dpaa2: " Nipun Gupta
2017-10-17 5:00 ` Jerin Jacob
2017-10-17 10:28 ` Nipun Gupta
2017-10-16 21:44 ` [dpdk-dev] [PATCH v3 4/4] event/dpaa2: improve the err handling and log msg Nipun Gupta
2017-10-17 16:38 ` [dpdk-dev] [PATCH v4 1/5] drivers: add queue parameter in event processing callback Nipun Gupta
2017-10-17 16:38 ` [dpdk-dev] [PATCH v4 2/5] net/dpaa2: add API's to support event eth adapter Nipun Gupta
2017-10-17 12:32 ` Hemant Agrawal
2017-10-17 16:38 ` [dpdk-dev] [PATCH v4 3/5] drivers: add net as dependency for event drivers Nipun Gupta
2017-10-21 10:05 ` Jerin Jacob
2017-10-17 16:38 ` [dpdk-dev] [PATCH v4 4/5] event/dpaa2: support event eth adapter Nipun Gupta
2017-10-17 16:38 ` Nipun Gupta [this message]
2017-10-23 12:37 ` [dpdk-dev] [PATCH v5 1/5] drivers: add queue parameter in event processing callback Nipun Gupta
2017-10-23 12:37 ` [dpdk-dev] [PATCH v5 2/5] net/dpaa2: add API's to support event eth adapter Nipun Gupta
2017-10-23 12:37 ` [dpdk-dev] [PATCH v5 3/5] drivers: add net as dependency for event drivers Nipun Gupta
2017-10-23 6:24 ` Jerin Jacob
2017-10-23 12:37 ` [dpdk-dev] [PATCH v5 4/5] event/dpaa2: support event eth adapter Nipun Gupta
2017-10-23 12:37 ` [dpdk-dev] [PATCH v5 5/5] event/dpaa2: improve the err handling and log msg Nipun Gupta
2017-10-23 17:49 ` [dpdk-dev] [PATCH v5 1/5] drivers: add queue parameter in event processing callback Jerin Jacob
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1508258314-11151-5-git-send-email-nipun.gupta@nxp.com \
--to=nipun.gupta@nxp.com \
--cc=dev@dpdk.org \
--cc=hemant.agrawal@nxp.com \
--cc=jerin.jacob@caviumnetworks.com \
--cc=nikhil.rao@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).