Commit Graph

46177 Commits

Author SHA1 Message Date
ad
4b293a84e1 Interrupt handling changes, in discussion since February:
- Reduce available SPL levels for hardware devices to none, vm, sched, high.
- Acquire kernel_lock only for interrupts at IPL_VM.
- Implement threaded soft interrupts.
2007-12-03 15:33:00 +00:00
rafal
7b4886ba60 Clear interrupts as they are established, rearrange interrupt-mapping code
to make sure PCI slot 0 interrupt doesn't accidentally match the (unused)
PCI error interrupt.

Fixes kern/25462 at least on my Netra T1 ac200.
From OpenBSD; ok martin@
2007-12-03 14:13:18 +00:00
ad
685aa3baed DIAGNOSTIC is only one of many debugging options. 2007-12-02 23:51:22 +00:00
rumble
f06a64e97b Fix two minor bugs:
1) If ODCM is disabled (ODCM_ENABLE not set), clockmod_getstate() should
    return the maximum level (7), not the lowest (0), as the levels are
    defined as duty cycles where the highest implies no ODCM. Now sysctl
    machdep.clockmod.current doesn't lie upon init.

 2) Make the sysctl handler ensure that no disabled levels are permitted.
    Previously, a level disabled due to errata could be passed to
    clockmod_setstate(), which would search through the state array,
    skipping the unusable value. Consequently our index would be out of
    range and badness could ensue.

Okay'd by xtraeme@.
2007-12-02 22:44:57 +00:00
dsl
cd39f2272a Improve the likelyhood of the 'oosyscall' code (ie that for system call entry
via a call gate for i386 netbsd 1.0 and ibcs2) doing the right thing.
Untested because I've failed to get an a.out netbsd 1.0 binary to load.
2007-12-02 21:43:11 +00:00
ad
6bd016935d Use the softint API. 2007-12-02 20:46:53 +00:00
ad
6a310e099d Back out part of patch that got merged accidentally. 2007-12-02 20:34:41 +00:00
ad
3ce0f72397 Use atomics to adjust ci_flags. 2007-12-02 19:33:31 +00:00
ad
dc58e180fd Remove unused cpp goo 2007-12-02 19:28:32 +00:00
ad
3c392fd114 Bump SYMTAB_SPACE 2007-12-02 19:25:43 +00:00
bouyer
eae5f92d0c IOCTL_PRIVCMD_MMAP*: instead of brutally enterring the new entries in
the process page table, properly uvm_unmap1() the VA range and enter a new
uvm_map backed by an object. There is a know race between uvm_unmap1() and
uvm_map(), where another thread could get our VA range; in practice
I think none of the softwares using this interface are multithreaded (or at
last they are single-threaded when using it).
2007-12-02 18:29:54 +00:00
jmcneill
479b0a0816 CRMFB_VT_VCMAP and CRMFB_VT_HCMAP register definitions were transposed.
From jsing@openbsd in private mail.
2007-12-02 17:36:57 +00:00
ad
7960b954d7 Don't clear ci_want_resched in MD code; it's done in mi_switch(). 2007-12-02 16:37:58 +00:00
skrll
e151146b60 Provide a _C_LABEL 2007-12-02 15:55:09 +00:00
jmcneill
e501c34199 SILENCE! I kill you! 2007-12-02 06:51:52 +00:00
tsutsui
71a975f6f6 - add ffsv2 ops
- use __arraycount()
2007-12-02 05:40:25 +00:00
tsutsui
71921eec1b Use __arraycount(). 2007-12-02 05:36:46 +00:00
kiyohara
a1297d6f3f Add bcsp(4). 2007-12-02 05:19:11 +00:00
christos
c9ef94469d busfunc needs assym.h too. 2007-12-02 04:24:44 +00:00
mhitch
9d6e1af583 Initializing the callout structure while it's in use is bad.
Only do it on the first call to iteinit().
2007-12-02 04:21:22 +00:00
ad
f8e6fbe610 Xintr_lapic_tlb_bcast: saving and restoring %ds may take up to 100 cycles.
Just access the globals using %ss.
2007-12-01 22:34:28 +00:00
tsutsui
59777a7842 Add ext2fs support. 2007-12-01 18:13:16 +00:00
tsutsui
a65243be7c Include both ffsv1 and ffsv2 supports. 2007-12-01 17:05:11 +00:00
jmcneill
ad3709398d aprintify 2007-12-01 16:59:13 +00:00
ad
204846883c Noisy printf 2007-12-01 16:49:56 +00:00
ad
4e780c2f88 Shh 2007-12-01 16:45:35 +00:00
ad
2d3a70d6e4 Quiten a noisy printf. 2007-12-01 16:07:20 +00:00
jmcneill
a0d3b0d7a8 aprintify 2007-12-01 14:35:51 +00:00
bouyer
e13d04bb9f Use __define__ instead of define, pointed out by christos. 2007-12-01 12:57:09 +00:00
bouyer
e1353de789 Back out previous, majors.amd64 in files.amd64 is inside ifndef xen/endif 2007-12-01 12:52:20 +00:00
tsutsui
6e5ce03f0b - update a comment
- use __func__ to print function names
- some KNF
2007-12-01 11:41:20 +00:00
tsutsui
c35536aa0c - use __arraycount()
- some KNF
- use __func__ to print function names
2007-12-01 11:25:26 +00:00
tsutsui
d58e6ad66b - some KNF
- use __func__ to print function names
2007-12-01 11:24:41 +00:00
tsutsui
c9df1c18a5 - update a comment
- use __func__ to print function names
- some KNF
2007-12-01 11:23:44 +00:00
marty
d8b9a7ea7c Increase SYMTAB_SPACE to 264000 so the release kernel will compile 2007-12-01 06:52:12 +00:00
jmcneill
1b940a02fa aprintify 2007-12-01 06:05:18 +00:00
jmcneill
4fbe23fdd0 aprintify 2007-12-01 04:50:50 +00:00
dsl
2d7e52ccd2 Don't pull in majors.amd64 here, we get another copy from files.amd64
and config bleats like mad.
2007-11-30 22:56:05 +00:00
tsutsui
06ae954501 Pass correct size to allocate struct obmem_softc.
Fix an occasional panic on my 3/80.
2007-11-30 13:22:37 +00:00
ad
0b8a0d143c Drop text alignment back to 16 - the usual size of blocks the instruction
decoder works with.
2007-11-29 22:03:48 +00:00
ad
890e076b1a Pending review by uwe@:
- Make _lock_cas() do "compare and swap", not "compare and set".
- Add aliases for atomic_cas_ulong() and friends.
2007-11-29 17:33:09 +00:00
ad
ad40d74014 - Change lock_cas from "compare and set" to "compare and swap".
- Add aliases for atomic_cas_ulong(), etc.

Ok skrll@
2007-11-29 16:14:28 +00:00
ad
afb9be47ba - Change _lock_cas() to do compare-and-swap instead of compare-and-set.
- Add aliases for atomic_cas_ulong() and friends.
2007-11-29 15:17:45 +00:00
ad
ccbc7a4bd9 Add 'bool returning' argument to cpu_switchto (unused). 2007-11-29 14:30:32 +00:00
yamt
d0f12a6ad9 instead of setting pcb_onfault on every calls of copyin and friends,
make the fault handler investigate program counter of faulting code.
inspired from linux.
2007-11-29 09:53:33 +00:00
nisimura
5155a3ee9b comment-out lpt0 since EnCorePP1 experiences occasional irq 7 flood
regardless of the special care to disable LPT function in VIA 686SB.
May not revive anytime soon as it's considered little use.
2007-11-29 06:50:37 +00:00
nisimura
e511172428 add preliminary wm.c, a lot of fixes to make other NIC more sensible. 2007-11-29 04:00:17 +00:00
ad
92d7e73c2a Add alias for atomic_cas_64() if available. 2007-11-29 01:04:20 +00:00
ad
f5474801b3 __HAVE_ATOMIC64_OPS if 64-bit 2007-11-29 00:58:03 +00:00
ad
32c745d42e __HAVE_ATOMIC64_OPS 2007-11-29 00:56:53 +00:00