mirror of
https://github.com/GOSTSec/sgminer
synced 2025-01-24 05:24:23 +00:00
Add hashfast detection driver calls to cgminer startup.
This commit is contained in:
parent
78932aa1ed
commit
3777ed288d
37
cgminer.c
37
cgminer.c
@ -62,6 +62,10 @@
|
||||
#include "driver-bflsc.h"
|
||||
#endif
|
||||
|
||||
#ifdef USE_HASHFAST
|
||||
#include "driver-hashfast.h"
|
||||
#endif
|
||||
|
||||
#if defined(unix) || defined(__APPLE__)
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
@ -1561,6 +1565,9 @@ static char *opt_verusage_and_exit(const char *extra)
|
||||
#ifdef HAVE_OPENCL
|
||||
"GPU "
|
||||
#endif
|
||||
#ifdef USE_HASHFAST
|
||||
"hashfast "
|
||||
#endif
|
||||
#ifdef USE_ICARUS
|
||||
"icarus "
|
||||
#endif
|
||||
@ -7317,6 +7324,10 @@ extern struct device_drv bflsc_drv;
|
||||
extern struct device_drv bitforce_drv;
|
||||
#endif
|
||||
|
||||
#ifdef USE_HASHFAST
|
||||
extern struct device_drv hashfast_drv;
|
||||
#endif
|
||||
|
||||
#ifdef USE_ICARUS
|
||||
extern struct device_drv icarus_drv;
|
||||
#endif
|
||||
@ -7615,6 +7626,10 @@ static void *hotplug_thread(void __maybe_unused *userdata)
|
||||
bitforce_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
#ifdef USE_HASHFAST
|
||||
hashfast_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
#ifdef USE_MODMINER
|
||||
modminer_drv.drv_detect();
|
||||
#endif
|
||||
@ -7833,37 +7848,37 @@ int main(int argc, char *argv[])
|
||||
gpu_threads = 0;
|
||||
#endif
|
||||
|
||||
if (!opt_scrypt) {
|
||||
#ifdef USE_ICARUS
|
||||
if (!opt_scrypt)
|
||||
icarus_drv.drv_detect();
|
||||
icarus_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
#ifdef USE_BFLSC
|
||||
if (!opt_scrypt)
|
||||
bflsc_drv.drv_detect();
|
||||
bflsc_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
#ifdef USE_BITFORCE
|
||||
if (!opt_scrypt)
|
||||
bitforce_drv.drv_detect();
|
||||
bitforce_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
#ifdef USE_HASHFAST
|
||||
hashfast_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
#ifdef USE_MODMINER
|
||||
if (!opt_scrypt)
|
||||
modminer_drv.drv_detect();
|
||||
modminer_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
#ifdef USE_ZTEX
|
||||
if (!opt_scrypt)
|
||||
ztex_drv.drv_detect();
|
||||
#endif
|
||||
|
||||
/* Detect avalon last since it will try to claim the device regardless
|
||||
* as detection is unreliable. */
|
||||
#ifdef USE_AVALON
|
||||
if (!opt_scrypt)
|
||||
avalon_drv.drv_detect();
|
||||
avalon_drv.drv_detect();
|
||||
#endif
|
||||
}
|
||||
|
||||
if (opt_display_devs) {
|
||||
applog(LOG_ERR, "Devices detected:");
|
||||
|
Loading…
x
Reference in New Issue
Block a user