Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Feb 2010 15:27:07 +0000 (UTC)
From:      Ivan Voras <ivoras@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r204249 - head/sys/dev/syscons/snake
Message-ID:  <201002231527.o1NFR7TT004652@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ivoras
Date: Tue Feb 23 15:27:07 2010
New Revision: 204249
URL: http://svn.freebsd.org/changeset/base/204249

Log:
  The New and Improved snake_server - Service Pack 1: now even more
  sensitive to load average variations!

Modified:
  head/sys/dev/syscons/snake/snake_saver.c

Modified: head/sys/dev/syscons/snake/snake_saver.c
==============================================================================
--- head/sys/dev/syscons/snake/snake_saver.c	Tue Feb 23 15:12:41 2010	(r204248)
+++ head/sys/dev/syscons/snake/snake_saver.c	Tue Feb 23 15:27:07 2010	(r204249)
@@ -114,7 +114,7 @@ snake_saver(video_adapter_t *adp, int bl
 		savs[0] += dirx + diry;
 		if (FANCY_SNAKE) {
 			update_msg();
-			load = LOAD_HIGH(averunnable.ldavg[0]) * 100;
+			load = ((averunnable.ldavg[0] * 100 + FSCALE / 2) >> FSHIFT);
 			if (load == 0)
 				color = FG_LIGHTGREY | BG_BLACK;
 			else if (load / mp_ncpus <= 50)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201002231527.o1NFR7TT004652>