Browse Source

Bugfix: cpu: Update device "kernel name" with auto-selected algorithm

Luke Dashjr 12 years ago
parent
commit
24368a0bf0
2 changed files with 4 additions and 1 deletions
  1. 3 0
      driver-cpu.c
  2. 1 1
      libblkmaker

+ 3 - 0
driver-cpu.c

@@ -790,12 +790,15 @@ static uint64_t cpu_can_limit_work(struct thr_info __maybe_unused *thr)
 static bool cpu_thread_init(struct thr_info *thr)
 {
 	const int thr_id = thr->id;
+	struct cgpu_info *cgpu = thr->cgpu;
 
 	mutex_lock(&cpualgo_lock);
 	if (opt_algo == ALGO_AUTO)
 		opt_algo = pick_fastest_algo();
 	mutex_unlock(&cpualgo_lock);
 
+	cgpu->kname = algo_names[opt_algo];
+	
 	/* Set worker threads to nice 19 and then preferentially to SCHED_IDLE
 	 * and if that fails, then SCHED_BATCH. No need for this to be an
 	 * error if it fails */

+ 1 - 1
libblkmaker

@@ -1 +1 @@
-Subproject commit 5f3ad2a1edc37ef2745634fea6bfc5b4d9bfdf9a
+Subproject commit 8f4bb3ee9f43405203fef6f64ca938dc7933a060