From: cheloha Date: Sun, 18 Sep 2022 20:47:09 +0000 (+0000) Subject: timecounting: tc_reset_quality: print notice if active counter changes X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=4c0ab4286c30ae2a8da7bc291ee43621c4231618;p=openbsd timecounting: tc_reset_quality: print notice if active counter changes Give the user a hint as to what happened if they boot up and the TSC is not the active counter. "sure" deraadt@ --- diff --git a/sys/kern/kern_tc.c b/sys/kern/kern_tc.c index b89170a573a..3509b8f2bd9 100644 --- a/sys/kern/kern_tc.c +++ b/sys/kern/kern_tc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_tc.c,v 1.77 2022/08/12 02:20:36 cheloha Exp $ */ +/* $OpenBSD: kern_tc.c,v 1.78 2022/09/18 20:47:09 cheloha Exp $ */ /* * Copyright (c) 2000 Poul-Henning Kamp @@ -486,6 +486,8 @@ tc_reset_quality(struct timecounter *tc, int quality) if (best != tc) { enqueue_randomness(best->tc_get_timecount(best)); timecounter = best; + printf("timecounter: active counter changed: %s -> %s\n", + tc->tc_name, best->tc_name); } } }