From 5d581cb5d7234328eafd6eb52ad98f98f18d9e78 Mon Sep 17 00:00:00 2001 From: Con Kolivas Date: Sat, 9 Feb 2013 19:27:57 +1100 Subject: [PATCH] Use blank_get_statline_before for GPU devices that don't support adl monitoring. --- cgminer.c | 2 +- driver-opencl.c | 3 ++- miner.h | 2 ++ 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/cgminer.c b/cgminer.c index ef7efa6c..acf3880c 100644 --- a/cgminer.c +++ b/cgminer.c @@ -6370,7 +6370,7 @@ static void noop_reinit_device(struct cgpu_info __maybe_unused *cgpu) { } -static void blank_get_statline_before(char *buf, struct cgpu_info __maybe_unused *cgpu) +void blank_get_statline_before(char *buf, struct cgpu_info __maybe_unused *cgpu) { tailsprintf(buf, " | "); } diff --git a/driver-opencl.c b/driver-opencl.c index 9e9e4015..8580b221 100644 --- a/driver-opencl.c +++ b/driver-opencl.c @@ -1287,7 +1287,8 @@ static void get_opencl_statline_before(char *buf, struct cgpu_info *gpu) else tailsprintf(buf, " "); tailsprintf(buf, "| "); - } + } else + gpu->drv->get_statline_before = &blank_get_statline_before; } #endif diff --git a/miner.h b/miner.h index 0902228a..58d125fd 100644 --- a/miner.h +++ b/miner.h @@ -268,6 +268,8 @@ struct gpu_adl { }; #endif +extern void blank_get_statline_before(char *buf, struct cgpu_info __maybe_unused *cgpu); + struct api_data; struct thr_info; struct work;