* [PATCH] staging: fsl-mc/dpio: Propagate error code
@ 2017-06-15 8:55 Ioana Radulescu
2017-06-15 8:58 ` Bogdan Purcareata
0 siblings, 1 reply; 2+ messages in thread
From: Ioana Radulescu @ 2017-06-15 8:55 UTC (permalink / raw)
To: gregkh
Cc: devel, linux-kernel, agraf, arnd, linux-arm-kernel,
bogdan.purcareata, stuyoder, laurentiu.tudor, ruxandra.radulescu,
roy.pledge, haiying.wang
dpaa2_io_service_register() returns zero even if
qbman_swp_CDAN_set() encountered an error. Fix this
by propagating the error code so the caller is informed
data availability notifications are not properly set
for a channel.
Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
---
drivers/staging/fsl-mc/bus/dpio/dpio-service.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/fsl-mc/bus/dpio/dpio-service.c b/drivers/staging/fsl-mc/bus/dpio/dpio-service.c
index e5d66749614c..762f045f53f7 100644
--- a/drivers/staging/fsl-mc/bus/dpio/dpio-service.c
+++ b/drivers/staging/fsl-mc/bus/dpio/dpio-service.c
@@ -260,9 +260,9 @@ int dpaa2_io_service_register(struct dpaa2_io *d,
/* Enable the generation of CDAN notifications */
if (ctx->is_cdan)
- qbman_swp_CDAN_set_context_enable(d->swp,
- (u16)ctx->id,
- ctx->qman64);
+ return qbman_swp_CDAN_set_context_enable(d->swp,
+ (u16)ctx->id,
+ ctx->qman64);
return 0;
}
EXPORT_SYMBOL(dpaa2_io_service_register);
--
2.11.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* RE: [PATCH] staging: fsl-mc/dpio: Propagate error code
2017-06-15 8:55 [PATCH] staging: fsl-mc/dpio: Propagate error code Ioana Radulescu
@ 2017-06-15 8:58 ` Bogdan Purcareata
0 siblings, 0 replies; 2+ messages in thread
From: Bogdan Purcareata @ 2017-06-15 8:58 UTC (permalink / raw)
To: Ruxandra Ioana Radulescu, gregkh
Cc: devel, linux-kernel, agraf, arnd, linux-arm-kernel, stuyoder,
Laurentiu Tudor, Ruxandra Ioana Radulescu, Roy Pledge,
Haiying Wang
> -----Original Message-----
> From: Ioana Radulescu [mailto:ruxandra.radulescu@nxp.com]
> Sent: Thursday, June 15, 2017 11:55 AM
> To: gregkh@linuxfoundation.org
> Cc: devel@driverdev.osuosl.org; linux-kernel@vger.kernel.org;
> agraf@suse.de; arnd@arndb.de; linux-arm-kernel@lists.infradead.org; Bogdan
> Purcareata <bogdan.purcareata@nxp.com>; stuyoder@gmail.com; Laurentiu Tudor
> <laurentiu.tudor@nxp.com>; Ruxandra Ioana Radulescu
> <ruxandra.radulescu@nxp.com>; Roy Pledge <roy.pledge@nxp.com>; Haiying Wang
> <haiying.wang@nxp.com>
> Subject: [PATCH] staging: fsl-mc/dpio: Propagate error code
>
> dpaa2_io_service_register() returns zero even if
> qbman_swp_CDAN_set() encountered an error. Fix this
> by propagating the error code so the caller is informed
> data availability notifications are not properly set
> for a channel.
>
> Signed-off-by: Ioana Radulescu <ruxandra.radulescu@nxp.com>
Acked-by: Bogdan Purcareata <bogdan.purcareata@nxp.com>
> ---
> drivers/staging/fsl-mc/bus/dpio/dpio-service.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/staging/fsl-mc/bus/dpio/dpio-service.c
> b/drivers/staging/fsl-mc/bus/dpio/dpio-service.c
> index e5d66749614c..762f045f53f7 100644
> --- a/drivers/staging/fsl-mc/bus/dpio/dpio-service.c
> +++ b/drivers/staging/fsl-mc/bus/dpio/dpio-service.c
> @@ -260,9 +260,9 @@ int dpaa2_io_service_register(struct dpaa2_io *d,
>
> /* Enable the generation of CDAN notifications */
> if (ctx->is_cdan)
> - qbman_swp_CDAN_set_context_enable(d->swp,
> - (u16)ctx->id,
> - ctx->qman64);
> + return qbman_swp_CDAN_set_context_enable(d->swp,
> + (u16)ctx->id,
> + ctx->qman64);
> return 0;
> }
> EXPORT_SYMBOL(dpaa2_io_service_register);
> --
> 2.11.0
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2017-06-15 8:58 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-15 8:55 [PATCH] staging: fsl-mc/dpio: Propagate error code Ioana Radulescu
2017-06-15 8:58 ` Bogdan Purcareata
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).