summaryrefslogtreecommitdiffstats
path: root/sys/sys/pcpu.h
diff options
context:
space:
mode:
authorjb <jb@FreeBSD.org>2006-11-30 04:17:05 +0000
committerjb <jb@FreeBSD.org>2006-11-30 04:17:05 +0000
commitda35e3e55f3d5d5ed5bc5018536e8b0a54ddc767 (patch)
tree6035effd6306a4201ed68eedced59e87c3965546 /sys/sys/pcpu.h
parent5727c5a0587e28c774bfc229e96707fe6fbd96ad (diff)
downloadFreeBSD-src-da35e3e55f3d5d5ed5bc5018536e8b0a54ddc767.zip
FreeBSD-src-da35e3e55f3d5d5ed5bc5018536e8b0a54ddc767.tar.gz
Turn console printf buffering into a kernel option and only on
by default for sun4v where it is absolutely required. This change moves the buffer from struct pcpu to the stack to avoid using the critical section which created a LOR in a couple of cases due to interaction with the tty code and kqueue. The LOR can't be fixed with the critical section and the pcpu buffer can't be used without the critical section. Putting the buffer on the stack was my initial solution, but it was pointed out that the stress on the stack might cause problems depending on the call path. We don't have a way of creating tests for those possible cases, so it's best to leave this as an option for the time being. In time we may get enough data to enable this option more generally.
Diffstat (limited to 'sys/sys/pcpu.h')
-rw-r--r--sys/sys/pcpu.h5
1 files changed, 0 insertions, 5 deletions
diff --git a/sys/sys/pcpu.h b/sys/sys/pcpu.h
index fa54bc4..00a3cac 100644
--- a/sys/sys/pcpu.h
+++ b/sys/sys/pcpu.h
@@ -48,9 +48,6 @@
struct pcb;
struct thread;
-/* Size of the per-cpu console buffer for printf(). */
-#define PCPU_CONS_BUFR 128
-
/*
* This structure maps out the global data that needs to be kept on a
* per-cpu basis. The members are accessed via the PCPU_GET/SET/PTR
@@ -74,8 +71,6 @@ struct pcpu {
int pc_ktr_idx; /* Index into trace table */
char *pc_ktr_buf;
#endif
- char pc_cons_bufr[PCPU_CONS_BUFR];
- /* Console buffer */
PCPU_MD_FIELDS;
struct vmmeter pc_cnt; /* VM stats counters */
struct device *pc_device;
OpenPOWER on IntegriCloud