diff options
author | 2014-11-11 21:02:06 +0000 | |
---|---|---|
committer | 2014-11-11 21:02:06 +0000 | |
commit | f5a9ebed12c4580ec18c5773f3e33938678b98d5 (patch) | |
tree | 8d837cbd504f2baaae301c258db128f46ef78250 | |
parent | When a bus is explored, do not probe the ports which status hasn't (diff) | |
download | wireguard-openbsd-f5a9ebed12c4580ec18c5773f3e33938678b98d5.tar.xz wireguard-openbsd-f5a9ebed12c4580ec18c5773f3e33938678b98d5.zip |
Do not held the kernel lock when calling hardclock() and statclock().
This is not necessary, as confirmed by tedu@ and kettenis@.
Solve the major contention problem seen on my Dual G5. Reduce the
build time of a kernel with two jobs from 5h+ to 18min and expose more
easily pmap/memroy corruptions 8)
ok kettenis@
-rw-r--r-- | sys/arch/macppc/macppc/clock.c | 5 | ||||
-rw-r--r-- | sys/arch/socppc/socppc/clock.c | 5 |
2 files changed, 2 insertions, 8 deletions
diff --git a/sys/arch/macppc/macppc/clock.c b/sys/arch/macppc/macppc/clock.c index 327d66fc340..d46728c56e5 100644 --- a/sys/arch/macppc/macppc/clock.c +++ b/sys/arch/macppc/macppc/clock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clock.c,v 1.38 2014/10/08 10:12:41 mpi Exp $ */ +/* $OpenBSD: clock.c,v 1.39 2014/11/11 21:02:06 mpi Exp $ */ /* $NetBSD: clock.c,v 1.1 1996/09/30 16:34:40 ws Exp $ */ /* @@ -227,8 +227,6 @@ decr_intr(struct clockframe *frame) if (ci->ci_cpl >= IPL_CLOCK) { ci->ci_statspending += nstats; } else { - KERNEL_LOCK(); - nstats += ci->ci_statspending; ci->ci_statspending = 0; @@ -258,7 +256,6 @@ decr_intr(struct clockframe *frame) /* if a tick has occurred while dealing with these, * dont service it now, delay until the next tick. */ - KERNEL_UNLOCK(); } } diff --git a/sys/arch/socppc/socppc/clock.c b/sys/arch/socppc/socppc/clock.c index 4eba2210892..c1ebef574ef 100644 --- a/sys/arch/socppc/socppc/clock.c +++ b/sys/arch/socppc/socppc/clock.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clock.c,v 1.11 2014/10/08 10:12:41 mpi Exp $ */ +/* $OpenBSD: clock.c,v 1.12 2014/11/11 21:02:06 mpi Exp $ */ /* $NetBSD: clock.c,v 1.1 1996/09/30 16:34:40 ws Exp $ */ /* @@ -208,8 +208,6 @@ decr_intr(struct clockframe *frame) if (ci->ci_cpl >= IPL_CLOCK) { ci->ci_statspending += nstats; } else { - KERNEL_LOCK(); - nstats += ci->ci_statspending; ci->ci_statspending = 0; @@ -239,7 +237,6 @@ decr_intr(struct clockframe *frame) /* if a tick has occurred while dealing with these, * dont service it now, delay until the next tick. */ - KERNEL_UNLOCK(); } } |