Browse Source

Merge commit 'fb34cb1' into update_avalon_20130524

Luke Dashjr 13 years ago
parent
commit
e6e778835d
1 changed files with 2 additions and 2 deletions
  1. 2 2
      driver-avalon.c

+ 2 - 2
driver-avalon.c

@@ -807,7 +807,7 @@ static int64_t avalon_scanhash(struct thr_info *thr)
 {
 {
 	struct cgpu_info *avalon;
 	struct cgpu_info *avalon;
 	struct work **works;
 	struct work **works;
-	int fd, ret, full;
+	int fd, ret = AVA_GETS_OK, full;
 
 
 	struct avalon_info *info;
 	struct avalon_info *info;
 	struct avalon_task at;
 	struct avalon_task at;
@@ -930,7 +930,7 @@ static int64_t avalon_scanhash(struct thr_info *thr)
 			       elapsed.tv_sec, elapsed.tv_usec);
 			       elapsed.tv_sec, elapsed.tv_usec);
 		}
 		}
 	}
 	}
-	if (result_wrong >= info->miner_count) {
+	if (result_wrong >= info->miner_count && ret != AVA_GETS_RESTART) {
 		/* This mean FPGA controller gave all wrong results, so
 		/* This mean FPGA controller gave all wrong results, so
 		 * try to reset the Avalon */
 		 * try to reset the Avalon */
 		do_avalon_close(thr);
 		do_avalon_close(thr);