Commit 9bb1f17a62e1b419c60584170d1fcf96f2a64867

Con Kolivas 2013-11-12T20:42:27

Break out of the avalon idle loop if we get a send error.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
diff --git a/driver-avalon.c b/driver-avalon.c
index 1372093..68bc456 100644
--- a/driver-avalon.c
+++ b/driver-avalon.c
@@ -576,7 +576,8 @@ static void avalon_idle(struct cgpu_info *avalon, struct avalon_info *info)
 		avalon_init_task(&at, 0, 0, info->fan_pwm, info->timeout,
 				 info->asic_count, info->miner_count, 1, 1,
 				 info->frequency);
-		avalon_send_task(&at, avalon, info);
+		if (avalon_send_task(&at, avalon, info) == AVA_SEND_ERROR)
+			break;
 	}
 	applog(LOG_WARNING, "%s%i: Idling %d miners", avalon->drv->name, avalon->device_id, i);
 	wait_avalon_ready(avalon);