|
|
@ -94,6 +94,7 @@ extern char *opt_api_allow; |
|
|
|
extern int opt_api_listen; /* port */ |
|
|
|
extern int opt_api_listen; /* port */ |
|
|
|
extern uint32_t accepted_count; |
|
|
|
extern uint32_t accepted_count; |
|
|
|
extern uint32_t rejected_count; |
|
|
|
extern uint32_t rejected_count; |
|
|
|
|
|
|
|
extern uint32_t opt_work_adds; |
|
|
|
extern int num_cpus; |
|
|
|
extern int num_cpus; |
|
|
|
extern struct stratum_ctx stratum; |
|
|
|
extern struct stratum_ctx stratum; |
|
|
|
extern char* rpc_user; |
|
|
|
extern char* rpc_user; |
|
|
@ -887,10 +888,13 @@ void apiReportThroughput(int thr_id, uint32_t throughput) |
|
|
|
while (ws > 1 && i++ < 32) |
|
|
|
while (ws > 1 && i++ < 32) |
|
|
|
ws = ws >> 1; |
|
|
|
ws = ws >> 1; |
|
|
|
cgpu->intensity_int = i; |
|
|
|
cgpu->intensity_int = i; |
|
|
|
|
|
|
|
cgpu->intensity = (float) i; |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
cgpu->intensity_int = (uint8_t) opt_intensity; |
|
|
|
cgpu->intensity_int = (uint8_t) opt_intensity; |
|
|
|
|
|
|
|
cgpu->intensity = (float) opt_intensity; |
|
|
|
|
|
|
|
if (opt_work_adds) { |
|
|
|
|
|
|
|
cgpu->intensity += ((float) opt_work_adds / (1U << opt_intensity)); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
// dec. part to finish...
|
|
|
|
|
|
|
|
cgpu->intensity = (float) cgpu->intensity_int; |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |