diff mbox series

[U-Boot] driver: fsl-mc: MC object cleanup when DPL not loaded

Message ID 1511844074-27205-1-git-send-email-yogeshnarayan.gaur@nxp.com
State Accepted
Commit 73fa206aefe0d27f71929da0c35dbce879205f20
Delegated to: York Sun
Headers show
Series [U-Boot] driver: fsl-mc: MC object cleanup when DPL not loaded | expand

Commit Message

Yogesh Narayan Gaur Nov. 28, 2017, 4:41 a.m. UTC
For case when MC is loaded but DPL is not deployed perform MC
object [DPBP, DPIO, DPNI and DPRC] cleanup.

Signed-off-by: Yogesh Gaur <yogeshnarayan.gaur@nxp.com>
---
 drivers/net/fsl-mc/mc.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

York Sun Dec. 8, 2017, 4:51 p.m. UTC | #1
On 11/27/2017 08:41 PM, Yogesh Gaur wrote:
> For case when MC is loaded but DPL is not deployed perform MC
> object [DPBP, DPIO, DPNI and DPRC] cleanup.
> 
> Signed-off-by: Yogesh Gaur <yogeshnarayan.gaur@nxp.com>
> ---
>  drivers/net/fsl-mc/mc.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)


Applied to fsl-qoriq master. Thanks.

York
diff mbox series

Patch

diff --git a/drivers/net/fsl-mc/mc.c b/drivers/net/fsl-mc/mc.c
index 9d25cd1..618818b 100644
--- a/drivers/net/fsl-mc/mc.c
+++ b/drivers/net/fsl-mc/mc.c
@@ -1436,12 +1436,13 @@  int fsl_mc_ldpaa_exit(bd_t *bd)
 	 */
 	if (bd && mc_boot_status && !is_dpl_apply_status) {
 		printf("fsl-mc: DPL not deployed, DPAA2 ethernet not work\n");
-		return 0;
+		goto mc_obj_cleanup;
 	}
 
 	if (bd && mc_boot_status && is_dpl_apply_status)
 		return 0;
 
+mc_obj_cleanup:
 	err = dpbp_exit();
 	if (err < 0) {
 		printf("dpbp_exit() failed: %d\n", err);