Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 20 Oct 2017 04:02:53 +0000 (UTC)
From:      Mateusz Guzik <mjg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r324789 - in head/sys: kern sys
Message-ID:  <201710200402.v9K42rFP029260@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mjg
Date: Fri Oct 20 04:02:53 2017
New Revision: 324789
URL: https://svnweb.freebsd.org/changeset/base/324789

Log:
  Mark kdb_active as __read_frequently and switch to bool to eat less space.

Modified:
  head/sys/kern/subr_kdb.c
  head/sys/sys/kdb.h

Modified: head/sys/kern/subr_kdb.c
==============================================================================
--- head/sys/kern/subr_kdb.c	Fri Oct 20 03:38:58 2017	(r324788)
+++ head/sys/kern/subr_kdb.c	Fri Oct 20 04:02:53 2017	(r324789)
@@ -50,7 +50,7 @@ __FBSDID("$FreeBSD$");
 #include <machine/smp.h>
 #endif
 
-int kdb_active = 0;
+bool __read_frequently kdb_active = 0;
 static void *kdb_jmpbufp = NULL;
 struct kdb_dbbe *kdb_dbbe = NULL;
 static struct pcb kdb_pcb;

Modified: head/sys/sys/kdb.h
==============================================================================
--- head/sys/sys/kdb.h	Fri Oct 20 03:38:58 2017	(r324788)
+++ head/sys/sys/kdb.h	Fri Oct 20 04:02:53 2017	(r324789)
@@ -59,7 +59,7 @@ struct kdb_dbbe {
 	};						\
 	DATA_SET(kdb_dbbe_set, name##_dbbe)
 
-extern int kdb_active;			/* Non-zero while in debugger. */
+extern bool kdb_active;			/* Non-zero while in debugger. */
 extern int debugger_on_panic;		/* enter the debugger on panic. */
 extern struct kdb_dbbe *kdb_dbbe;	/* Default debugger backend or NULL. */
 extern struct trapframe *kdb_frame;	/* Frame to kdb_trap(). */



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