@@ -40,11 +40,11 @@ enum {
int mclink_probe(void)
{
unsigned int k;
- unsigned int ctr = 0;
int slaves = 0;
for (k = 0; k < CONFIG_SYS_MCLINK_MAX; ++k) {
int timeout = 0;
+ unsigned int ctr = 0;
if (!(fpga_get_reg(k, REG(mc_status)) & (1 << 15)))
break;
@@ -53,7 +53,7 @@ int mclink_probe(void)
while (!(fpga_get_reg(k, REG(mc_status)) & (1 << 14))) {
udelay(100);
- if (ctr++ > 3) {
+ if (ctr++ > 500) {
timeout = 1;
break;
}
@@ -61,6 +61,8 @@ int mclink_probe(void)
if (timeout)
break;
+ printf("waited %d us for mclink %d to come up\n", ctr * 100, k);
+
slaves++;
}
Signed-off-by: Dirk Eibach <eibach@gdsys.de> --- board/gdsys/common/mclink.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)