Commit b3bc506d9a081bf4cc03185988acf48cc847370e

Con Kolivas 2012-05-05T09:31:48

Move a pool to POOL_REJECTING to be disabled only after 3 minutes of continuous rejected shares.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
diff --git a/cgminer.c b/cgminer.c
index 21d90d1..cf42784 100644
--- a/cgminer.c
+++ b/cgminer.c
@@ -1723,13 +1723,13 @@ static bool submit_upstream_work(const struct work *work, CURL *curl)
 		}
 
 		/* Once we have more than a nominal amount of sequential rejects,
-		 * at least 10 and more than the current utility rate per minute,
+		 * at least 10 and more than 3 mins at the current utility,
 		 * disable the pool because some pool error is likely to have
 		 * ensued. */
 		if (pool->seq_rejects > 10 && opt_disable_pool && total_pools > 1) {
 			double utility = total_accepted / ( total_secs ? total_secs : 1 ) * 60;
 
-			if (pool->seq_rejects > utility) {
+			if (pool->seq_rejects > utility * 3) {
 				applog(LOG_WARNING, "Pool %d rejected %d sequential shares, disabling!",
 				       pool->pool_no, pool->seq_rejects);
 				pool->enabled = POOL_REJECTING;