|
|
|
@ -3658,15 +3658,6 @@ static void rebuild_hash(struct work *work)
@@ -3658,15 +3658,6 @@ static void rebuild_hash(struct work *work)
|
|
|
|
|
scrypt_regenhash(work); |
|
|
|
|
else |
|
|
|
|
regen_hash(work); |
|
|
|
|
|
|
|
|
|
work->share_diff = share_diff(work); |
|
|
|
|
if (unlikely(work->share_diff >= current_diff)) { |
|
|
|
|
work->block = true; |
|
|
|
|
work->pool->solved++; |
|
|
|
|
found_blocks++; |
|
|
|
|
work->mandatory = true; |
|
|
|
|
applog(LOG_NOTICE, "Found block for pool %d!", work->pool->pool_no); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
static bool cnx_needed(struct pool *pool); |
|
|
|
@ -6045,6 +6036,7 @@ bool submit_nonce(struct thr_info *thr, struct work *work, uint32_t nonce)
@@ -6045,6 +6036,7 @@ bool submit_nonce(struct thr_info *thr, struct work *work, uint32_t nonce)
|
|
|
|
|
|
|
|
|
|
cgtime(&tv_work_found); |
|
|
|
|
*work_nonce = htole32(nonce); |
|
|
|
|
work->share_diff = 0; |
|
|
|
|
|
|
|
|
|
/* Do one last check before attempting to submit the work */ |
|
|
|
|
rebuild_hash(work); |
|
|
|
@ -6060,6 +6052,8 @@ bool submit_nonce(struct thr_info *thr, struct work *work, uint32_t nonce)
@@ -6060,6 +6052,8 @@ bool submit_nonce(struct thr_info *thr, struct work *work, uint32_t nonce)
|
|
|
|
|
goto out; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
work->share_diff = share_diff(work); |
|
|
|
|
|
|
|
|
|
mutex_lock(&stats_lock); |
|
|
|
|
total_diff1 += work->device_diff; |
|
|
|
|
thr->cgpu->diff1 += work->device_diff; |
|
|
|
|