* [dpdk-dev] [PATCH] pdump: fix log message to display correct error number
@ 2016-11-10 16:29 Reshma Pattan
2016-11-10 16:47 ` Mcnamara, John
2016-11-10 16:48 ` De Lara Guarch, Pablo
0 siblings, 2 replies; 4+ messages in thread
From: Reshma Pattan @ 2016-11-10 16:29 UTC (permalink / raw)
To: dev; +Cc: Reshma Pattan
The ethdev Rx/Tx remove callback apis doesn't set rte_errno during
failures, instead they just return negative error number, so using
that number in logs instead of rte_errno upon Rx and Tx callback
removal failures.
Fixes: 278f9454 ("pdump: add new library for packet capture")
Signed-off-by: Reshma Pattan <reshma.pattan@gmail.com>
---
lib/librte_pdump/rte_pdump.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/librte_pdump/rte_pdump.c b/lib/librte_pdump/rte_pdump.c
index 504a1ce..5968683 100644
--- a/lib/librte_pdump/rte_pdump.c
+++ b/lib/librte_pdump/rte_pdump.c
@@ -269,7 +269,7 @@ pdump_regitser_rx_callbacks(uint16_t end_q, uint8_t port, uint16_t queue,
if (ret < 0) {
RTE_LOG(ERR, PDUMP,
"failed to remove rx callback, errno=%d\n",
- rte_errno);
+ -ret);
return ret;
}
cbs->cb = NULL;
@@ -324,7 +324,7 @@ pdump_regitser_tx_callbacks(uint16_t end_q, uint8_t port, uint16_t queue,
if (ret < 0) {
RTE_LOG(ERR, PDUMP,
"failed to remove tx callback, errno=%d\n",
- rte_errno);
+ -ret);
return ret;
}
cbs->cb = NULL;
--
2.7.4
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] pdump: fix log message to display correct error number
2016-11-10 16:29 [dpdk-dev] [PATCH] pdump: fix log message to display correct error number Reshma Pattan
@ 2016-11-10 16:47 ` Mcnamara, John
2016-11-10 16:48 ` De Lara Guarch, Pablo
1 sibling, 0 replies; 4+ messages in thread
From: Mcnamara, John @ 2016-11-10 16:47 UTC (permalink / raw)
To: Pattan, Reshma, dev; +Cc: Reshma Pattan
> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Reshma Pattan
> Sent: Thursday, November 10, 2016 4:30 PM
> To: dev@dpdk.org
> Cc: Reshma Pattan <reshma.pattan@gmail.com>
> Subject: [dpdk-dev] [PATCH] pdump: fix log message to display correct
> error number
>
> The ethdev Rx/Tx remove callback apis doesn't set rte_errno during
> failures, instead they just return negative error number, so using that
> number in logs instead of rte_errno upon Rx and Tx callback removal
> failures.
>
> Fixes: 278f9454 ("pdump: add new library for packet capture")
>
> Signed-off-by: Reshma Pattan <reshma.pattan@gmail.com>
Acked-by: John McNamara <john.mcnamara@intel.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] pdump: fix log message to display correct error number
2016-11-10 16:29 [dpdk-dev] [PATCH] pdump: fix log message to display correct error number Reshma Pattan
2016-11-10 16:47 ` Mcnamara, John
@ 2016-11-10 16:48 ` De Lara Guarch, Pablo
2016-11-12 21:29 ` Thomas Monjalon
1 sibling, 1 reply; 4+ messages in thread
From: De Lara Guarch, Pablo @ 2016-11-10 16:48 UTC (permalink / raw)
To: Pattan, Reshma, dev; +Cc: Reshma Pattan
> -----Original Message-----
> From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Reshma Pattan
> Sent: Thursday, November 10, 2016 4:30 PM
> To: dev@dpdk.org
> Cc: Reshma Pattan
> Subject: [dpdk-dev] [PATCH] pdump: fix log message to display correct error
> number
>
> The ethdev Rx/Tx remove callback apis doesn't set rte_errno during
> failures, instead they just return negative error number, so using
> that number in logs instead of rte_errno upon Rx and Tx callback
> removal failures.
>
> Fixes: 278f9454 ("pdump: add new library for packet capture")
>
> Signed-off-by: Reshma Pattan <reshma.pattan@gmail.com>
Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] pdump: fix log message to display correct error number
2016-11-10 16:48 ` De Lara Guarch, Pablo
@ 2016-11-12 21:29 ` Thomas Monjalon
0 siblings, 0 replies; 4+ messages in thread
From: Thomas Monjalon @ 2016-11-12 21:29 UTC (permalink / raw)
To: Pattan, Reshma; +Cc: dev, De Lara Guarch, Pablo, Reshma Pattan
> > The ethdev Rx/Tx remove callback apis doesn't set rte_errno during
> > failures, instead they just return negative error number, so using
> > that number in logs instead of rte_errno upon Rx and Tx callback
> > removal failures.
> >
> > Fixes: 278f9454 ("pdump: add new library for packet capture")
> >
> > Signed-off-by: Reshma Pattan <reshma.pattan@gmail.com>
>
> Acked-by: Pablo de Lara <pablo.de.lara.guarch@intel.com>
Applied, thanks
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2016-11-12 21:29 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-10 16:29 [dpdk-dev] [PATCH] pdump: fix log message to display correct error number Reshma Pattan
2016-11-10 16:47 ` Mcnamara, John
2016-11-10 16:48 ` De Lara Guarch, Pablo
2016-11-12 21:29 ` Thomas Monjalon
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).