simonb
99cad24ec6
GC this file - it should have been removed during the ppcoea-renovation
...
merge.
2008-01-08 11:54:47 +00:00
he
943b531346
Remove a no-longer-used local variable.
2008-01-08 07:59:23 +00:00
matt
e1adc2881b
Add IPL_SOFT* defined at IPL_NONE.
...
Change _ARM32_INTR_H to _ACORN32_INTR_H
2008-01-08 06:30:22 +00:00
matt
306d43c5bf
Remove unused variable.
2008-01-08 06:29:39 +00:00
matt
6d2503c7a9
Don't do arithmetic on void pointers.
2008-01-08 06:28:29 +00:00
dyoung
e0b21313b6
In device_foreach_child(), use a safe idiom for walking a list
...
whose elements we might be deleting. This stops us from crashing
in config_detach_children().
2008-01-08 06:27:46 +00:00
matt
2414d5854f
Make sys_swapctl match syscallargs.h
2008-01-08 06:25:55 +00:00
dyoung
b202d18acd
Use aprint_*_dev(), device_xname(), and device_t. Join a line.
2008-01-08 04:47:44 +00:00
dyoung
f384d52f35
Delete an unnecessary cast.
2008-01-08 03:37:45 +00:00
matt
6bc0c58216
As of this commit, all arm32 kernel now build.
2008-01-08 02:07:50 +00:00
matt
f4f1c6c970
More kernels SYMTAB_SPACE increased.
2008-01-08 02:06:43 +00:00
matt
04a4a202ed
include "conf/std"
2008-01-08 02:05:30 +00:00
uwe
71fc6881ec
In general_exception() in do_panic case print error message *before*
...
we drop into ddb.
2008-01-08 01:25:13 +00:00
gdt
1424adf410
Support FIONBIO.
...
Support non-blocking reads from USB printers. With this, escputil can
query the printer model, and I can print a test page with gutenprint
5.1 and cups. Add many comments explaining why the support is not
quite right. (This change is quite a bit less invasive than a
"correct" fix, and thus more reasonable to pull up to netbsd-4.)
Rototill debugging, so that all DPRINTFN have a level, and so that the
message is printed if the debug level is >= the number in the source
code. Document debug level plan.
Fix bug where only one status change would be printed (by inspection,
not tested).
Document scheme for reading/discarding data when ulpt(4) is opened for
write only.
Delete dead code.
Plan and patch posted on tech-kern without objections.
2008-01-08 00:58:09 +00:00
ad
c0187a5323
pmap_destroy: cast return of atomic_dec_uint_nv to (int) to avoid leaking
...
pmaps. The refcount can be zero due to pmap_remove_all. Problem found by
tnn@.
2008-01-08 00:45:23 +00:00
pooka
72b3924d8b
Set stacksize to minimum acceptable (two pages, one for cc, one
...
for actual stack) to mimic kernel stack size better.
2008-01-08 00:23:15 +00:00
elad
964f16c2b9
Make fork use kauth.
...
Been running in my tree for over a month at least.
Reviewed and okay yamt@, and special thanks to him as well as rittera@
for making this possible through fixing NDIS to not call fork1() with
l1 != curlwp.
2008-01-07 23:51:06 +00:00
dsl
0b5d0f6802
Actually copy the ras list onto the child process during fork() - hi ad.
...
Might fix the 'ras' part of kern/37650.
For some reason the itimers aren't inherited either.
2008-01-07 20:56:32 +00:00
ad
574389c2a0
Fix build if !MODULAR. Reported by elad@.
2008-01-07 20:42:48 +00:00
rittera
c22be27a3d
Added elad's changes to ndis_kthread_create. Setting the stack size in fork1 apparently has no effect in the kernel. Note: needs testing
2008-01-07 19:10:58 +00:00
ad
b7dafc15be
Don't both about module name / ksyms until the name is known for sure.
2008-01-07 18:25:56 +00:00
joerg
e47a5502a7
Use gettimeofday as timecounter.
2008-01-07 17:27:12 +00:00
joerg
0a53bb0b5b
x86 always has timecounter support.
2008-01-07 16:58:09 +00:00
ad
52603a7d6d
Fix 'panic: softdep_update_inodeblock: update failed'.
2008-01-07 16:56:27 +00:00
joerg
ebd253a526
Garbage collect !__HAVE_TIMECOUNTER code.
2008-01-07 16:55:15 +00:00
christos
2937b71b26
Add PaX ASLR for testing
2008-01-07 16:46:59 +00:00
joerg
7e82e3084b
Timecounter support for VAX. Basic testing in simh done on a backported
...
version to netbsd-4.
2008-01-07 16:40:16 +00:00
ad
72506c7508
Regen.
2008-01-07 16:16:38 +00:00
ad
fe8aceeb5e
More MPSAFE syscalls.
2008-01-07 16:15:36 +00:00
ad
8b52263cd1
Hold kernel_lock across IFNET_FOREACH().
2008-01-07 16:13:49 +00:00
ad
77e0b2120f
Patch up sysctl locking:
...
- Lock processes, credentials, filehead etc correctly.
- Acquire a read hold on sysctl_treelock if only doing a query.
- Don't wire down the output buffer. It doesn't work correctly and the code
regularly does long term sleeps with it held - it's not worth it.
- Don't hold locks other than sysctl_lock while doing copyout().
- Drop sysctl_lock while doing copyout / allocating memory in a few places.
- Don't take kernel_lock for sysctl.
- Fix a number of bugs spotted along the way
2008-01-07 16:12:52 +00:00
ad
eb4920235a
Don't drop vnode refs until we are done with the mount.
2008-01-07 16:08:46 +00:00
tsutsui
2b341ae01b
Add timecounter(9) support for mvme68k.
...
Based on a patch from Garrett D'Amore and several tweaks by me.
Compile tested only, but reviewed by joerg@ and
no objection from scw@ on port-mvme68k.
2008-01-07 14:39:28 +00:00
joerg
7f4f83c80c
Shared clock.c with amiga, so it supports generic time counter.
2008-01-07 13:55:36 +00:00
ad
a32939fca4
bwrite, bdwrite: bufcache_lock must be held for reassignbuf.
2008-01-07 12:50:38 +00:00
ad
297c776822
Make VFS_SYNC() and friends functions, and have them acquire kernel_lock
...
if the FS is not marked MPSAFE.
2008-01-07 12:34:12 +00:00
njoly
e5e170b198
Regen.
2008-01-07 12:12:12 +00:00
njoly
0dbd478087
Remove wrong linux32_sys_mmap2_args define.
2008-01-07 12:11:52 +00:00
yamt
2e8a5bee68
lwp_ctl_alloc: fix error handling.
2008-01-07 11:41:29 +00:00
simonb
cfde7482cd
Actually return the computed uptime in microuptime(). Fixes many
...
wierd timing issues on non-timecounter ports (tested on sbmips, and
omap ARM by Marty Fouts).
Also move the microtime() inside the splclock() block in the same
function - it may be possible for the "time" variable to be updated
after the call to microtime() but before we use it to calculate the
offset from mono_time.
2008-01-07 10:28:07 +00:00
martti
7e40665ceb
Fixed indentation, it should be
...
option<space><tab>
makeoption<space><tab>
2008-01-07 08:39:03 +00:00
martti
a678f921c8
Fixed option indentation, it should be
...
option<space><tab>
makeoption<space><tab>
2008-01-07 08:30:03 +00:00
dyoung
73b30d3cfe
Define some "special" values of register MMCR_WPVMAP.
2008-01-07 08:01:45 +00:00
dyoung
40fec83596
Delete unused mips_ipl_si_to_sr[].
2008-01-07 07:28:14 +00:00
dyoung
cb1ed32e14
Update AR5312 interrupt masks along the same lines as the AR5315.
2008-01-07 07:14:37 +00:00
dyoung
b82c6f8442
Cosmetic: re-number the comments on elements of ipl_sr_bits[].
2008-01-07 07:12:06 +00:00
dyoung
189256ad32
Make this compile again by making changes similar to the changes
...
that ad@ made to arch/mips/alchemy/au_icu.c. Compiles and runs,
but this probably deserves a looksie by someone with more MIPS
clue.
2008-01-07 06:55:32 +00:00
dyoung
b82e361f77
Use pmf(9). Use device_t and device_private().
2008-01-07 06:53:08 +00:00
tnn
303f9ebb5b
Make the ACPI_MADT_DEBUG code compile again.
2008-01-07 06:04:07 +00:00
tnn
51f964a289
softdep_freefile: don't acquire ufsmount lock twice.
2008-01-07 05:20:25 +00:00
uwe
e97e9077cc
Note landisk import date.
2008-01-07 05:02:38 +00:00
uwe
f38b1e35de
Now that sh3 has didicated interrupt stack we can check for cpu_intr_p
...
with simple sp comparison, so we can drop ci_idepth.
2008-01-07 05:00:12 +00:00
uwe
b786c078f9
Add endif comment for __HAVE_FAST_SOFTINTS.
2008-01-07 04:43:54 +00:00
uwe
1e0e088d60
cpu_intr_p - we can simply check if we are running on the interrupt stack.
2008-01-07 04:41:40 +00:00
ad
d534bbfa2e
Really, remove last vestiges of simplelock debugging.
2008-01-07 01:55:15 +00:00
ad
907a6a54db
Fix dodgy assertions. From Anders Hjalmarsson.
2008-01-07 00:43:27 +00:00
ad
b439191858
Remove vestiges of simplelock debugging.
2008-01-07 00:27:35 +00:00
ad
de5c0b29ed
Build kobj_machdep.c if MODULAR.
2008-01-07 00:26:32 +00:00
bjs
521d96c676
The stamp mutex is not unsafe, so remove this comment so people don't get the wrong idea. ok ad@
2008-01-07 00:25:19 +00:00
ad
9202b67eca
Overzealous; pull in machine/lock.h again.
2008-01-07 00:20:18 +00:00
uwe
d8f0d4be74
Catch up with new option to dev/pckbport/wskbdmap_mfii.c
2008-01-07 00:19:08 +00:00
ad
80f35bef49
#include <sys/mutex.h>
2008-01-06 20:53:06 +00:00
christos
d879c8360a
defflag one moe variable.
2008-01-06 19:42:33 +00:00
christos
d1b79165fa
clamp min/max values properly.
2008-01-06 19:42:03 +00:00
mhitch
c04c9a55d0
Add timecounter support and borrow counter-based delay from i386.
...
From joerg; testing and final tweaks by me.
2008-01-06 18:50:29 +00:00
martin
890508dbe9
argh, I did not intend to remove all declarations of physmem.
2008-01-06 18:35:24 +00:00
martin
ae4518d415
Remove superflouse extern decls.
2008-01-06 18:24:06 +00:00
martin
fb8f17133f
Move the mutex_init of pmap_lock even later into pmap_init().
...
This makes LOCKDEBUG kernels work again.
2008-01-06 18:07:16 +00:00
ad
0805a9416a
Add MODULAR option. Include kernel linker stuff if MODULAR.
2008-01-06 18:03:58 +00:00
martin
9a2bbccfc7
Load the next cpu_info pointer with LDPTR instead of ld.
2008-01-06 17:22:15 +00:00
jmcneill
bf49138bfc
Fix off-by-one in kobj_read range checking for case KT_MEMORY
2008-01-06 15:13:07 +00:00
ad
b9e6d93835
- Allow loading ELF objects from memory. Based on a patch from jmcneill.
...
- Allow for changing object name later, once known.
- Split open/load of the objects.
2008-01-06 14:47:26 +00:00
ad
dff5d8444c
Only do the xcall if !cold.
2008-01-06 14:33:27 +00:00
dsieger
55cdd729c2
Fix a typo: s/Kgdb_dev/kgdb_dev/
2008-01-06 13:54:01 +00:00
martin
2a8b08575b
We can not mutex_init() before setting up the per-CPU mappings needed
...
by curcpu() - a LOCKDEBUG kernel will die otherwise.
2008-01-06 13:41:28 +00:00
kent
9602a50eb5
recognized the names of Sigmatel STAC9227-9230
2008-01-06 13:33:21 +00:00
ad
67cc6c4e0d
Update curcpu()->ci_idepth, not the (left over) local.
2008-01-06 13:28:17 +00:00
dsl
b6e6554ace
include sys/simplelock.h
2008-01-06 13:25:22 +00:00
dsl
f3df4c2289
include sys/simplock.h
2008-01-06 13:18:19 +00:00
kent
86e51d72d1
fix a bug of S/PDIF audio format selection
...
PR/36493 by Arcady Antipin
2008-01-06 12:56:20 +00:00
bouyer
4507f75dd0
Fix fallout from vmlocking2: in xbdback_co_io_loop(), return the right object.
2008-01-06 12:43:42 +00:00
chris
941409f5f4
curcpu()->ci_depth is now updated in irq_dispatch.S, remove duplication
...
from footbridge.
2008-01-06 12:17:13 +00:00
he
eb14906cb2
Include <sys/device.h> explicitly to pull in needed definitions.
2008-01-06 10:33:24 +00:00
matt
d9322458cc
Truly kill current_intr_depth once and for all.
2008-01-06 03:45:26 +00:00
matt
940cdbb355
current_intr_depth is dead. Make sure we don't use it anymore.
2008-01-06 03:11:42 +00:00
matt
ace1262f40
current_intr_depth is dead. kill it off for good.
2008-01-06 03:01:59 +00:00
martin
258a4b78cf
With the new IPL world, things are easier for us: if we can get the
...
nell hardware interrupt handler run at IPL_VM, we can call the socket
drivers interrupt handler directly.
This is always possible on sparc64, but on sparc we might have to fall
back to the old softint bounce. Since this uses arbitrary IPLs, we
can not use the new softint_* for this - we'll have to use the old
sparc_softintr_* functions.
2008-01-06 02:29:58 +00:00
matt
0c0de8072e
Cleanup softint lossage.
2008-01-06 01:37:53 +00:00
matt
3ef8cd67cc
Increase SYMTAB_SPACE because of more kernel bloat.
2008-01-06 01:35:34 +00:00
matt
e7574fcb84
Make sure interrupt handler is updating curcpu()->ci_depth
2008-01-06 01:19:42 +00:00
ad
503fb6483e
A quick hack to make cpu_intr_p() work on shark. Needs to be fixed
...
properly by someone who does arm assembly.
2008-01-06 00:56:18 +00:00
ad
e5942a85c1
Missing lock acquire.
2008-01-05 23:54:24 +00:00
ad
58dc3540b0
Add fgetdummy/fputdummy: allocate and free dummy 'struct file' entries
...
to be used when traversing filehead.
2008-01-05 23:53:21 +00:00
martin
798130646c
Add missing include
2008-01-05 22:50:12 +00:00
yamt
bb81964965
allocate dedicated stacks for NMI. PR/37662.
2008-01-05 22:48:31 +00:00
martin
d5681ba54e
Add missing include.
2008-01-05 22:45:22 +00:00
yamt
55ac8a439e
remove a stale comment.
2008-01-05 21:59:33 +00:00
yamt
f98ad43750
remove no longer necessary cpu_maxproc.
2008-01-05 21:52:01 +00:00
yamt
35f1be57b4
- make amd64 use per-cpu tss.
...
- fix iopl syscall for amd64+xen.
2008-01-05 21:47:18 +00:00
yamt
f44110bb2a
move IOMAP_INVALOFF from cpu.h to tss.h
2008-01-05 21:45:00 +00:00
yamt
e9a50f2e86
g/c unused members
2008-01-05 21:40:57 +00:00
yamt
a0958af97a
g/c ci_idle_pcb_paddr
2008-01-05 21:37:25 +00:00
jdc
f42ce09a9c
Add bmtphy* (for gem*).
2008-01-05 20:38:31 +00:00
jdc
bb4a0543ee
Updates from OpenBSD:
...
-- r1.15
Add some DSP init code for BCM5221's.
Values derived from Apple's GMAC driver, same init
code also exists in Linux's sungem_phy driver.
tested by miod@ pedro@ and otto@ on a few systems.
-- r1.16
Always explicitly set IFM_HDX for half-duplex.
From brad@
--
2008-01-05 20:33:29 +00:00
jdc
6055efa604
Add support for Sun PCI X1141A (SX fibre) cards.
...
Add support for GEM cards on non-OFW machines.
2008-01-05 20:30:22 +00:00
jdc
196789ac55
Add support for Sun PCI X1141A (SX fibre) cards, based on the GEM
...
documentation, experimentation and a previous patch from John Heasley.
Add improvements to the driver based on the GEM documentation and
from FreeBSD if_gem.c (rev 1.45).
2008-01-05 20:27:44 +00:00
christos
adf68778f6
Add PaX stuff for testing.
2008-01-05 20:14:01 +00:00
bouyer
f8a26c5d3c
Wrap test for debug_port in __predict_false()
2008-01-05 19:29:26 +00:00
apb
4ee202cfe2
If a menu line in boot.cfg has an empty description, then re-use the
...
command as the description. For example,
menu=:boot netbsd -s
now works like
menu=boot netbsd -s:boot netbsd -s
2008-01-05 19:29:16 +00:00
bouyer
81873269e4
Make sure debug_port isn't used before initialized by setting it to -1.
2008-01-05 19:16:07 +00:00
dsl
95a195791a
Use FILE_LOCK() and FILE_UNLOCK().
...
Attempt to fix all the code paths so that the 'fp' returned by fd_getfile()
isn't left locked, and is always unlocked (and ref-counted) before
doing anything that might sleep.
2008-01-05 19:14:07 +00:00
dsl
902612f1f5
Use the new names (_REG_RFLAGS and _REG_RSP) for the indexes of __gregs[]
...
which match the names of in the trapframe and .S code.
2008-01-05 19:11:53 +00:00
dsl
8a62c0f2a5
Use FILE_LOCK() and FILE_UNLOCK()
2008-01-05 19:08:48 +00:00
dsl
482bdf6cb9
Add FILE_LOCK() and FILE_UNLOCK() defines.
...
Change a comment to make it clear that if code doesn't call FILE_USE()
it should call FILE_UNLOCK() instead.
2008-01-05 18:52:16 +00:00
christos
d4fda54fa5
PR/37696: Paul Ripke: add large read / readahead support (Introduce run-length
...
detection to msdosfs_bmap(), from FreeBSD)
2008-01-05 18:42:14 +00:00
ad
21946bba05
Make acct_lock a rwlock.
2008-01-05 18:23:30 +00:00
ad
63baaccb6d
Serialize calls to tc_windup().
2008-01-05 18:00:37 +00:00
ad
a5edcb2c82
Missing arg to cv_timedwait().
2008-01-05 17:38:50 +00:00
dsl
8d35d4af30
Remove #define DISK_DEBUG left in by mistake
2008-01-05 15:28:43 +00:00
ad
4eefe3e642
Export log_lock.
2008-01-05 14:07:26 +00:00
martin
b432cf5a27
Include lock.h, as we are using memory barrier macros defined there.
2008-01-05 13:27:27 +00:00
dsl
b8bcdbe9e6
Don't pass 'curlwp' into trace_enter() and trace_exit().
2008-01-05 12:53:52 +00:00
ad
31ef469fe7
Work around com hangs with pcmcia. PR kern/37462.
2008-01-05 12:44:13 +00:00
dsl
463af8509e
Don't pass curlwp into process_stoptrace()
2008-01-05 12:41:43 +00:00
ad
fbed3be26c
Make compile.
2008-01-05 12:40:34 +00:00
ad
212c50dd1b
Need sys/lock.h for SPINLOCK_SPIN_HOOK.
2008-01-05 12:39:27 +00:00
ad
ac85866313
simple_lock_only_held() is gone.
2008-01-05 12:31:39 +00:00
dsl
c9848793d9
Don't pass l (== curlwp) into the system call trace code.
...
Delete inclusion of opt_syscall_debug.h into systm.h, every kernel object
file doesn't need to depend on opt_syscall_debug.h!
2008-01-05 12:30:47 +00:00
dsl
ba7a604397
Reorder the amd64 trapframe (swap rcx/r10 and add 4 spare slots after r9).
...
This allows the syscall code to pass the syscall args directly from the
trapframe instead of copying them to a separate structure.
It is still possible that some lurking code still assumes that
'struct trapframe', 'struct mcontext' and 'struct reg' all have the
registers in the same order, but I've fixed enough of them to get gdb working.
2008-01-05 12:08:50 +00:00
dsl
77fe68004d
Do not assume that 'struct reg' and 'struct trapframe' have the same
...
layout. Instead copy the fields individually.
2008-01-05 12:01:34 +00:00
he
30542539fe
Now that compat/hpux is gone, this has no chance of building, so
...
remove it as well.
2008-01-05 10:24:11 +00:00
dan
6b2d0ee56c
use more includes, take them from the right place
...
xtraemok
2008-01-05 04:50:05 +00:00
riz
f28eb587da
Add #include <sys/simplelock.h>
2008-01-05 04:03:01 +00:00
matt
acb0b175a3
Add #include <sys/simplelock.h>
2008-01-05 02:47:03 +00:00
ad
c29520cb1a
Fix includes.
2008-01-05 00:31:50 +00:00
ad
0c8143169b
Fix includes
2008-01-05 00:22:34 +00:00
ad
fee5b86dc3
Don't need sys/lock.h
2008-01-05 00:19:46 +00:00
dyoung
1c6cf449e1
Constify.
2008-01-04 23:35:00 +00:00
dsl
c18b957cb0
Repeat after me, don't edit files (even to update comments) between test
...
build and committing.
2008-01-04 23:29:54 +00:00
dyoung
f9c1ba02ee
Constify a bit.
2008-01-04 23:28:07 +00:00
dyoung
a4455600d4
Replace rtcache_down() with rtcache_validate() and update rtcache_down()
...
uses.
2008-01-04 23:26:44 +00:00
dsl
abceae9908
Change the way that the trap/intr/syscall frames and the __gregset_t[]
...
indexes are defined so that only a single list of the registers is used.
The code no longer relies on the two structures matching.
There should be no binary change.
2008-01-04 23:04:53 +00:00
ad
87a9501131
Fix includes.
2008-01-04 22:54:46 +00:00
joerg
700e393dca
time.tv_sec -> time_second
2008-01-04 22:43:45 +00:00
dyoung
46aba2a3d0
Remove superfluous #if (NPCPPI > 0).
2008-01-04 22:28:20 +00:00
ad
8c68ad876e
Fix headers.
2008-01-04 22:17:04 +00:00
ad
0fbfbb4408
Correct headers.
2008-01-04 22:15:58 +00:00
ad
c9e4f09710
Pull in the right headers.
2008-01-04 22:15:08 +00:00
ad
fb1e16b417
Need sys/device.h
2008-01-04 22:13:55 +00:00
dyoung
482c583bd7
Move #endif to the place where it belongs. Thanks, Chavdar Ivanov,
...
for noticing this.
2008-01-04 22:10:34 +00:00