]> Gitweb @ Texas Instruments - Open Source Git Repositories - git.TI.com/gitweb - keystone-rtos/ibl.git/blobdiff - src/ethboot/ethboot.c
c64x: Add Multi Boot Support
[keystone-rtos/ibl.git] / src / ethboot / ethboot.c
index 8042707b125f896ccecae54fa8e77d47f0a1cb0a..163a411b1133e81a85d9e0e3a6e49eb0954fff14 100644 (file)
@@ -114,7 +114,7 @@ void iblEthBoot (Int32 eIdx)
     void    (*exit)();
     uint8   buf[16];
     char    *ext;
-
+    unsigned int i,j;
 
     /* Power up the device. No action is taken if the device is already powered up */
     if (devicePowerPeriph (TARGET_PWR_ETH(ibl.bootModes[eIdx].port)) < 0)
@@ -125,11 +125,13 @@ void iblEthBoot (Int32 eIdx)
         hwMdio (ibl.mdioConfig.nMdioOps, ibl.mdioConfig.mdio, 
                 ibl.mdioConfig.mdioClkDiv, ibl.mdioConfig.interDelay);
 
+    for (j = 0; j < 0x100; j++)
+       for (i = 0; i < 0x1000000; i++);
 
     /* SGMII configuration. If sgmii is not present this statement is defined
      * to void in target.h */
     for (n = 0; n < ibl_N_ETH_PORTS; n++)  {
-        if (ibl.sgmiiConfig[eIdx].configure == TRUE)
+        if (ibl.sgmiiConfig[n].configure == TRUE)
             hwSgmiiConfig (n, &ibl.sgmiiConfig[n]);
     }