* [U-Boot] [PATCH] driver: net: fsl-mc: Return from DPAA_exit if boot_status !=0
@ 2016-03-18 10:44 Prabhakar Kushwaha
2016-03-18 16:15 ` york sun
0 siblings, 1 reply; 2+ messages in thread
From: Prabhakar Kushwaha @ 2016-03-18 10:44 UTC (permalink / raw)
To: u-boot
return value of get_mc_boot_status() in case of failure is not necessary
to be -1.
So update the error condition check.
Signed-off-by: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
Reported-by: Yao Yuan <yao.yuan@nxp.com>
---
drivers/net/fsl-mc/mc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/fsl-mc/mc.c b/drivers/net/fsl-mc/mc.c
index 53c4966..7ae619d 100644
--- a/drivers/net/fsl-mc/mc.c
+++ b/drivers/net/fsl-mc/mc.c
@@ -1147,7 +1147,7 @@ int fsl_mc_ldpaa_exit(bd_t *bd)
{
int err = 0;
- if (bd && get_mc_boot_status() == -1)
+ if (bd && get_mc_boot_status() != 0)
return 0;
if (bd && !get_mc_boot_status() && get_dpl_apply_status() == -1) {
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [U-Boot] [PATCH] driver: net: fsl-mc: Return from DPAA_exit if boot_status !=0
2016-03-18 10:44 [U-Boot] [PATCH] driver: net: fsl-mc: Return from DPAA_exit if boot_status !=0 Prabhakar Kushwaha
@ 2016-03-18 16:15 ` york sun
0 siblings, 0 replies; 2+ messages in thread
From: york sun @ 2016-03-18 16:15 UTC (permalink / raw)
To: u-boot
On 03/18/2016 03:44 AM, Prabhakar Kushwaha wrote:
> return value of get_mc_boot_status() in case of failure is not necessary
> to be -1.
>
> So update the error condition check.
>
> Signed-off-by: Prabhakar Kushwaha <prabhakar.kushwaha@nxp.com>
> Reported-by: Yao Yuan <yao.yuan@nxp.com>
> ---
> drivers/net/fsl-mc/mc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/fsl-mc/mc.c b/drivers/net/fsl-mc/mc.c
> index 53c4966..7ae619d 100644
> --- a/drivers/net/fsl-mc/mc.c
> +++ b/drivers/net/fsl-mc/mc.c
> @@ -1147,7 +1147,7 @@ int fsl_mc_ldpaa_exit(bd_t *bd)
> {
> int err = 0;
>
> - if (bd && get_mc_boot_status() == -1)
> + if (bd && get_mc_boot_status() != 0)
> return 0;
>
A comment would be helpful to understand why 0 is returned here.
York
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-03-18 16:15 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-18 10:44 [U-Boot] [PATCH] driver: net: fsl-mc: Return from DPAA_exit if boot_status !=0 Prabhakar Kushwaha
2016-03-18 16:15 ` york sun
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.