1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-02-03 18:44:29 +00:00

Check enough work is queued before queueing more in avalon_fill.

This commit is contained in:
Con Kolivas 2013-04-05 18:51:20 +11:00
parent f0806c6828
commit 23fa953bfc

View File

@ -768,6 +768,8 @@ static bool avalon_fill(struct cgpu_info *avalon)
if (unlikely(!work)) if (unlikely(!work))
return false; return false;
if (avalon->queued == avalon_info[avalon->device_id]->miner_count)
return true;
avalon->works[avalon->queued++] = work; avalon->works[avalon->queued++] = work;
if (avalon->queued == avalon_info[avalon->device_id]->miner_count) if (avalon->queued == avalon_info[avalon->device_id]->miner_count)
return true; return true;