mirror of
https://github.com/GOSTSec/sgminer
synced 2025-01-26 22:44:21 +00:00
Only debug and move ram if spare bytes exist in avalon buffer.
This commit is contained in:
parent
9f59e9a6d6
commit
1f08809a7f
@ -652,9 +652,12 @@ static void avalon_parse_results(struct cgpu_info *avalon, struct avalon_info *i
|
|||||||
spare = *offset - AVALON_READ_SIZE;
|
spare = *offset - AVALON_READ_SIZE;
|
||||||
else
|
else
|
||||||
spare = AVALON_READ_SIZE + i;
|
spare = AVALON_READ_SIZE + i;
|
||||||
|
if (spare) {
|
||||||
applog(LOG_WARNING, "Avalon: Discarding %d bytes from buffer", spare);
|
applog(LOG_WARNING, "Avalon: Discarding %d bytes from buffer", spare);
|
||||||
*offset -= spare;
|
*offset -= spare;
|
||||||
memmove(buf, buf + spare, *offset);
|
memmove(buf, buf + spare, *offset);
|
||||||
|
}
|
||||||
|
|
||||||
if (!found) {
|
if (!found) {
|
||||||
mutex_lock(&info->lock);
|
mutex_lock(&info->lock);
|
||||||
info->no_matching_work++;
|
info->no_matching_work++;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user