Browse Source

klondike add new nonecount only once

nfactor-troky
Kano 11 years ago committed by Con Kolivas
parent
commit
d7db1e8a2b
  1. 3
      driver-klondike.c

3
driver-klondike.c

@ -519,10 +519,11 @@ static int64_t klondike_scanwork(struct thr_info *thr)
newhashdev += klninfo->status[dev].hashcount - klninfo->devinfo[dev].lasthashcount; newhashdev += klninfo->status[dev].hashcount - klninfo->devinfo[dev].lasthashcount;
klninfo->devinfo[dev].lasthashcount = klninfo->status[dev].hashcount; klninfo->devinfo[dev].lasthashcount = klninfo->status[dev].hashcount;
klninfo->hashcount += (newhashdev << 32) / klninfo->status[dev].maxcount; klninfo->hashcount += (newhashdev << 32) / klninfo->status[dev].maxcount;
newhashcount += 0xffffffffull * (uint64_t)klninfo->noncecount;
// todo: check stats for critical conditions // todo: check stats for critical conditions
} }
newhashcount += 0xffffffffull * (uint64_t)klninfo->noncecount;
klninfo->noncecount = 0;
rd_unlock(&(klninfo->stat_lock)); rd_unlock(&(klninfo->stat_lock));
} }
return newhashcount; return newhashcount;

Loading…
Cancel
Save