From a4e95cfa424084b26a900d3e31f5ec6e5152b70c Mon Sep 17 00:00:00 2001 From: Kano Date: Sun, 6 Jan 2013 01:00:18 +1100 Subject: [PATCH] device_drv missing drv for cpu and incorrect test --- cgminer.c | 2 +- driver-cpu.c | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/cgminer.c b/cgminer.c index adf7db45..177f61c4 100644 --- a/cgminer.c +++ b/cgminer.c @@ -5904,7 +5904,7 @@ static void *watchdog_thread(void __maybe_unused *userdata) continue; #ifdef WANT_CPUMINE - if (cgpu->drv->drv != DRIVER_CPU) + if (cgpu->drv->drv == DRIVER_CPU) continue; #endif if (cgpu->status != LIFE_WELL && (now.tv_sec - thr->last.tv_sec < WATCHDOG_SICK_TIME)) { diff --git a/driver-cpu.c b/driver-cpu.c index 99c5a3fa..eb46f3d8 100644 --- a/driver-cpu.c +++ b/driver-cpu.c @@ -844,6 +844,7 @@ CPUSearch: } struct device_drv cpu_drv = { + .drv = DRIVER_CPU, .dname = "cpu", .name = "CPU", .drv_detect = cpu_detect,