diff mbox series

[v2,1/2] ls1012a, pfe_eth: correction in delay implementation

Message ID 1599736854-11054-1-git-send-email-chaitanya.sakinam@nxp.com
State Accepted
Commit 0649ab496a0b40ef96c91c1619b92a4e2360c983
Delegated to: Priyanka Jain
Headers show
Series [v2,1/2] ls1012a, pfe_eth: correction in delay implementation | expand

Commit Message

Chaitanya Sakinam Sept. 10, 2020, 11:20 a.m. UTC
correction in delay implementation before we exit out of tx timeout.

Signed-off-by: Chaitanya Sakinam <chaitanya.sakinam@nxp.com>
---
 drivers/net/pfe_eth/pfe_eth.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/drivers/net/pfe_eth/pfe_eth.c b/drivers/net/pfe_eth/pfe_eth.c
index 6e22041..5bfcaa4 100644
--- a/drivers/net/pfe_eth/pfe_eth.c
+++ b/drivers/net/pfe_eth/pfe_eth.c
@@ -174,9 +174,10 @@  static int pfe_eth_send(struct udevice *dev, void *packet, int length)
 
 		udelay(100);
 		i++;
-		if (i == 30000)
+		if (i == 30000) {
 			printf("Tx timeout, send failed\n");
-		break;
+			break;
+		}
 	}
 
 	return 0;