Commit Graph

169260 Commits

Author SHA1 Message Date
ad 88a55035c6 Oops... EVCNT_TYPE_IPI -> EVCNT_TYPE_INTR. 2008-04-29 00:44:58 +00:00
ad ffc4969f6e Don't count many items as EVCNT_TYPE_INTR because they clutter up the
systat vmstat display.
2008-04-28 23:00:22 +00:00
ad 104cf0ae89 Add support for kernel preeemption to the i386 and amd64 ports. Notes:
- I have seen one isolated panic in the x86 pmap, but otherwise i386
  seems stable with preemption enabled.

- amd64 is missing the FPU handling changes and it's not yet safe to
  enable it there.

- The usual level for kern.sched.kpreempt_pri will be 128 once enabled
  by default. For testing, setting it to 0 helps to shake out bugs.
2008-04-28 22:47:37 +00:00
ad 678e546158 -defflag PREEMPTION 2008-04-28 22:46:40 +00:00
ad 3802ad0f7c 4.99.62 - struct lwp changed for kernel preemption 2008-04-28 22:44:18 +00:00
ad ca24210d8c EVCNT_TYPE_INTR -> EVCNT_TYPE_MISC 2008-04-28 22:15:47 +00:00
matt d22fb7c7d0 More forgotten changes from matt-armv6. 2008-04-28 22:00:01 +00:00
ad b96eb5aec9 Make the preemption switch a __HAVE instead of an option. 2008-04-28 21:17:16 +00:00
martin ce099b4099 Remove clause 3 and 4 from TNF licenses 2008-04-28 20:22:51 +00:00
jdc 313a56c040 Set (and display) the chip revision.
Set the GEM_SUN_GEM flag.
2008-04-28 20:07:39 +00:00
jdc 06662e01eb Replace "User's Guide" URL with one that is current. 2008-04-28 19:48:56 +00:00
ad 0cb8674c03 Make the trap stubs preemption safe. 2008-04-28 19:47:36 +00:00
ad 9c1818760e - Make some entry/exit points preemption safe.
- Try to avoid mispredicted bracnhes in Xsyscall.
- Interrupts were being enabled in Xsyscall _after_ checking for ASTs,
  while could have resulted in ugly behaviour like delayed signals or
  context switches. Fix it.
2008-04-28 19:35:56 +00:00
pooka 2d66ed28b9 Unbreak recent breakage. 2008-04-28 19:31:45 +00:00
garbled 01fba5909d Add floppy support to prep (the croud goes wild)
Add an additional argument to pnpbus_intr_establish to allow overriding of
the pnp interrupt type, because some devices lie.
Change how the pnpbus match routine works, to avoid attaching it when we
are probing for cpu's.
Fix a few stray printf's in the autoconf output.
2008-04-28 19:01:45 +00:00
ad 50ca4969ff Noisy printf. 2008-04-28 18:49:40 +00:00
garbled fcdfd014d7 Minor fixes to some of these files:
Add recognition for the CS4232C revision chip. (0xa2)
Make ic/ad1848.c compile with AUDIO_DEBUG
Add a needed machine/bus.h include to ic/cs4231.c
Add a few additional register defines to ic/cs4231reg.h
2008-04-28 18:49:27 +00:00
drochner efdfaa4756 fix error handling after m_pullup() 2008-04-28 18:33:31 +00:00
ad 25a2492fa0 Make kernel pagefault handling preeemption safe. 2008-04-28 18:32:12 +00:00
ad 6adfffcd49 - Make these preemption safe.
- Try to avoid mispredicted branches.
2008-04-28 18:31:15 +00:00
ad 53368c2808 Noisy printf. 2008-04-28 18:26:57 +00:00
ad 2d7dbb9788 +L_NOPREEMPT, L_DOPREEMPT 2008-04-28 18:20:51 +00:00
ad d8fdbaf5b4 Make pagefaults in kernel mode preemption safe. 2008-04-28 18:17:40 +00:00
ad 67d2c7edc1 Make FPU handling preemption safe. 2008-04-28 18:15:39 +00:00
ad 64bcc9bd8b Make this preemption safe. 2008-04-28 18:13:58 +00:00
degroote bb588cd930 Fix a stupid typo. In ipsec6_process_packet, reinject the packet in AF_INET6,
nor in AF_INET.
2008-04-28 17:40:11 +00:00
ad 836973f68b KASSERT(l->l_nopreempt == 0) 2008-04-28 17:18:41 +00:00
ad 3d504986e5 Stray kpreempt_disable with no matching kpreempt_enable. 2008-04-28 17:18:19 +00:00
ad 1f959cb4ab Use symbolic names for -C. 2008-04-28 16:52:17 +00:00
ad 7d4d52d5aa sbspace: return 'long', otherwise signed comparisons will be promoted
to unsigned.
2008-04-28 16:37:15 +00:00
ad 343816f86a defopt PREEMPTION 2008-04-28 15:46:48 +00:00
ad 499f0dfad6 Even if PREEMPTION is defined, disable it by default until any preemption
safety issues have been ironed out. Can be enabled at runtime with sysctl.
2008-04-28 15:38:03 +00:00
ad 4c7ba24481 Add MI code to support in-kernel preemption. Preemption is deferred by
one of the following:

- Holding kernel_lock (indicating that the code is not MT safe).
- Bracketing critical sections with kpreempt_disable/kpreempt_enable.
- Holding the interrupt priority level above IPL_NONE.

Statistics on kernel preemption are reported via event counters, and
where preemption is deferred for some reason, it's also reported via
lockstat. The LWP priority at which preemption is triggered is tuneable
via sysctl.
2008-04-28 15:36:01 +00:00
ad ccd06c9a6a key_usrreq: set in a lock on PRU_ATTACH. Spotted by yamt@. 2008-04-28 15:18:43 +00:00
yamt 89ee456bc7 as softint network processing is now safe to block,
make some mutexes adaptive.
2008-04-28 15:06:51 +00:00
yamt fb7535aecb udp6_init: fix a comment. 2008-04-28 15:01:39 +00:00
ad 1d11e457d5 Fix hang with atalkd. PR kern/38513. 2008-04-28 14:31:46 +00:00
ad b04b9c7a9b Set in a lock on new sockets. I don't know how this was missed before. 2008-04-28 13:24:38 +00:00
ad 5668836100 MUTEX_SPIN_SPLRAISE: add another __insn_barrier() for safety. 2008-04-28 13:18:50 +00:00
ad a52d138523 cpu_idle: assert ilevel == IPL_NONE. 2008-04-28 13:10:22 +00:00
ad 7c334139cd - mutex_spin_enter: avoid SPL NOT LOWERED... errors when running with
preemption. This could also fix similar errors seen with softints.
- Adjust code slightly to try and avoid mispredicted branches. The branch
  hint prefixes are apparently of little use.
2008-04-28 13:09:00 +00:00
christos 29c39f7ad5 Add -lc when -shared so that all shared libraries built by the compiler
have a dependency to -lc. To avoid adding that dependency in -lc and -lgcc*
we add -nostdlib to the compile rules.
2008-04-27 23:49:27 +00:00
christos a9587bb896 now that gcc adds -lc, reverse the logic and explain. 2008-04-27 23:48:10 +00:00
ad 5be927ae20 Make preemption safe. 2008-04-27 22:43:08 +00:00
ad c76bdbff23 Sprinkle more assertions / preemption paranoia. 2008-04-27 22:41:15 +00:00
ad a93682b7c8 - Make some entry/exit points preemption safe.
- Avoid mispredicted branches in Xsyscall.
2008-04-27 22:40:09 +00:00
ad 2993a9569e Wrap kpreempt stuff in _KERNEL, since bool is only exposed in userspace
via stdbool.h.
2008-04-27 22:38:12 +00:00
ad 992544b3e9 Fix build error. 2008-04-27 22:34:49 +00:00
christos 17a5e23949 Make sure the current message (dot) is set correctly when changing the
display state, i.e., hidden/exposed tags or threads.  This fixes at
least two problems:

- If the current message is a duplicate that is deleted by the "deldups"
  command, then the dot was invalid making all messages appear to have
  been deleted.  It is now set to the surviving duplicate message.

- If the current message is tagged, the "hidetags" command would leave
  the dot invalid and the dislay would reset it at the top of the
  current screen.  It is now set the the first untagged (and
  not deleted) message after the previous (tagged) dot message.

From Anon Ymous
2008-04-27 22:26:50 +00:00
bouyer 0fef0ddf92 xengnt_more_entries(): fix memory leak, noticed by Jean-Yves Migeon 2008-04-27 19:28:45 +00:00