1
0
mirror of https://github.com/GOSTSec/sgminer synced 2025-01-23 04:54:26 +00:00

Add a noop function for driver detect when it's missing.

This commit is contained in:
ckolivas 2013-09-28 13:52:13 +10:00
parent 372c40956a
commit df54b76855

View File

@ -7434,6 +7434,9 @@ static void noop_thread_enable(struct thr_info __maybe_unused *thr)
{ {
} }
static void noop_null(void)
{
}
#define noop_flush_work noop_reinit_device #define noop_flush_work noop_reinit_device
#define noop_queue_full noop_get_stats #define noop_queue_full noop_get_stats
@ -7442,6 +7445,8 @@ void fill_device_drv(struct cgpu_info *cgpu)
{ {
struct device_drv *drv = cgpu->drv; struct device_drv *drv = cgpu->drv;
if (!drv->drv_detect)
drv->drv_detect = &noop_null;
if (!drv->reinit_device) if (!drv->reinit_device)
drv->reinit_device = &noop_reinit_device; drv->reinit_device = &noop_reinit_device;
if (!drv->get_statline_before) if (!drv->get_statline_before)