From 79756384d43eb9cd7d307665ca8470dbf7f0af16 Mon Sep 17 00:00:00 2001 From: nelisky Date: Mon, 19 Mar 2012 11:19:16 +0000 Subject: [PATCH] ztex Mhz reporting --- ztex.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ztex.c b/ztex.c index fa68fdc9..2ec5ce4b 100644 --- a/ztex.c +++ b/ztex.c @@ -268,6 +268,12 @@ static uint64_t ztex_scanhash(struct thr_info *thr, struct work *work, return noncecnt > 0 ? noncecnt : 1; } +static void ztex_statline_before(char *buf, struct cgpu_info *cgpu) +{ + tailsprintf(buf, "%dMhz", cgpu->device->freqM1 * (cgpu->device->freqM + 1)); + tailsprintf(buf, "| "); +} + static bool ztex_prepare(struct thr_info *thr) { struct timeval now; @@ -303,6 +309,7 @@ static void ztex_disable (struct thr_info *thr) struct device_api ztex_api = { .name = "ZTX", .api_detect = ztex_detect, + .get_statline_before = ztex_statline_before, .thread_prepare = ztex_prepare, .scanhash = ztex_scanhash, .thread_shutdown = ztex_shutdown,