jdolecek
fc181f91c6
use EMUL_GETPID_PASS_PPID or EMUL_GETID_PASS_EID to find out if one should
...
pass parent pid for getpid() or effective id for get[ug]id(), instead
of compile-time dependency
2000-12-01 20:34:17 +00:00
jdolecek
d06ce6de86
set the EMUL_HAS_SYS___syscall flag for emul_netbsd
2000-12-01 19:41:49 +00:00
jdolecek
30760da04a
no need to define emul_osf1, <compat/osf1/osf1_exec.h> defines it for us now
...
set execsw[] entrys' priority to appropriate values
2000-12-01 12:57:55 +00:00
jdolecek
01040d97a2
add e_path (emulation path) to struct emul, which replaces emulation-specific
...
*_emul_path variables
change macros CHECK_ALT_{CREAT|EXIST} to use that, 'root' doesn't need
to be passed explicitly any more and *_CHECK_ALT_{CREAT|EXIST} are removed
change explicit emul_find() calls in probe functions to get the emulation
path from the checked exec switch entry's emulation
remove no longer needed header files
add e_flags and e_syscall to struct emul; these are unsed and empty for now
2000-12-01 12:28:30 +00:00
nathanw
be487a2752
Set doreallocblks=1 here.
2000-11-30 20:56:53 +00:00
jdolecek
7d3a48b31d
recognize ^if and ^endif in input master syscall file specially - output it
...
like #if and #endif to sysdcl; this can be used to insert ifdefs
to generated *sysent.c
2000-11-29 22:09:05 +00:00
thorpej
aa77dea4c2
No need to play silly name trickery when we know we're talking about
...
64-bit ELF binaries.
2000-11-28 21:58:12 +00:00
mrg
51858ad725
backout part of execsw/LKM changes: netbsd_elf32_signature() is used by
...
the compat/netbsd32 code so de-static it again.
2000-11-28 13:10:41 +00:00
mrg
b4e53bf009
wrap newly introduced >80 char lines.
2000-11-28 12:24:34 +00:00
jdolecek
e650ecc818
prototype netbsd_elf64_probe() ifdef EXEC_ELF64, not for if !defined(EXEC_ELF32)
2000-11-27 18:04:32 +00:00
jdolecek
414f0ac116
netbsd32 emulation doesn't exec 64bit binaries
2000-11-27 17:21:22 +00:00
chs
69ad0d84c0
regen.
2000-11-27 09:04:59 +00:00
chs
aeda8d3b77
Initial integration of the Unified Buffer Cache project.
2000-11-27 08:39:39 +00:00
nisimura
10571faa84
Introduce uvm_km_valloc_align() and use it to glab process's USPACE
...
aligned on USPACE boundary in kernel virutal address. It's benefitial
for MIPS R4000's paired TLB entry design.
2000-11-27 04:36:40 +00:00
takemura
3c9d9276dc
Add new powerhook argument values, PWR_SOFTSUSPEND, PWR_SOFTSTANDBY and
...
PWR_SOFTRESUME. Apm calls powerhook with the values in normal interrupt
priority level while others are protected with splhigh().
2000-11-26 11:08:57 +00:00
jdolecek
d9a0883770
define COMPAT_OLDSOCK unconditionally - the code is used virtually for all
...
emulations besides NetBSD, and this way it's LKM-safe
2000-11-24 21:38:28 +00:00
chs
55a751c9d5
add ddb commands "show uvmexp" and "show ncache".
...
the former used to be "call uvm_dump", the latter is new.
2000-11-24 07:25:50 +00:00
chs
ab077e1ed4
change cache_purgevfs() from O(N^2) to O(N).
...
use queue.h macros where possible.
2000-11-24 05:02:23 +00:00
chs
fa19fe52db
adjust the spinlock macros in the non-MULTIPROCESSOR, non-LOCKDEBUG case
...
so that gcc will think that static spinlock are used.
this allows us to remove the ugly conditionalization of
static spinlock declarations.
2000-11-24 03:59:07 +00:00
chs
22d140fd0b
ifdef DEBUG, increase the max size we'll overwrite in freed memory blocks
...
to detect modifications after frees from 32 bytes to 1 page.
2000-11-24 00:34:32 +00:00
thorpej
113dd58233
Add a LOCKDEBUG check for a r/w spinlock spinning out of control.
...
Partially from Bill Sommerfeld.
2000-11-22 06:31:22 +00:00
itojun
6c7e531e99
make COMPAT_OSF1 to compile. not tested (could someone review?).
2000-11-22 03:48:33 +00:00
enami
29f1bcd8e2
Unlock mutex before jumping off from the critical region instead of
...
testing if locked.
2000-11-21 03:53:27 +00:00
jdolecek
baae0324b9
restructure struct emul and execsw, in preparation to make emulations LKMable:
...
* move all exec-type specific information from struct emul to execsw[] and
provide single struct emul per emulation
* elf:
- kern/exec_elf32.c:probe_funcs[] is gone, execsw[] how has one entry
per emulation and contains pointer to respective probe function
- interp is allocated via MALLOC() rather than on stack
- elf_args structure is allocated via MALLOC() rather than malloc()
* ecoff: the per-emulation hooks moved from alpha and mips specific code
to OSF1 and Ultrix compat code as appropriate, execsw[] has one entry per
emulation supporting ecoff with appropriate probe function
* the makecmds/probe functions don't set emulation, pointer to emulation is
part of appropriate execsw[] entry
* constify couple of structures
2000-11-21 00:37:49 +00:00
jdolecek
e5b244c609
disable the LM_EXEC stuff for now, it doesn't work anyway
...
this will be fixed 'soon'
2000-11-21 00:11:38 +00:00
thorpej
3075dec01a
Allow machine dependent code to specify a hook to be run when a
...
spinlock's interlock is released.
Idea from Bill Sommerfeld.
2000-11-20 20:04:49 +00:00
veego
a174b8a595
simple_lock_held is only defined when you use LOCKDEBUG.
...
Put it for now in an ifdef LOCKDEBUG.
2000-11-20 06:36:02 +00:00
simonb
f104ee65be
Add a sysctl_rdminstruct() function - same as sysctl_rdstruct() but
...
can return short data if *oldlenp is less than len.
2000-11-20 01:46:56 +00:00
jdolecek
26fe6166ed
check_pty(): simple_unlock() might have been called even if the lock was
...
not locked previously in some cases; unlock only if the lock is held
2000-11-19 22:34:56 +00:00
sommerfeld
0cc75528c8
If MULTIPROCESSOR, count cpus and use that for hw.ncpu
2000-11-19 01:46:26 +00:00
sommerfeld
89b4aa9918
Preliminary MULTIPROCESSOR support:
...
- for CP_TIME, sum the times across all processors.
- for kinfo_proc2, fill in cpu_id.
2000-11-19 01:34:58 +00:00
sommerfeld
f276315e1c
In pool_setlowat(), only call pool_catchup() if the pool is under the
...
low water mark. (Avoids annoying warning when you setlowat a static
pool).
2000-11-19 00:29:51 +00:00
simonb
3f9e6ed0b8
Don't use alloca() - breaks compile on alpha (alloca is not prototyped
...
anywhere).
2000-11-18 15:58:13 +00:00
jdolecek
4ba9d75b97
pass pointer to used exec_package to emulation-specific exec hook -
...
emulation code may make decisions based on e.g. exec format
2000-11-16 20:04:33 +00:00
enami
c4c6285008
Don't allow t_linesw to be NULL.
2000-11-15 01:47:14 +00:00
enami
c816e13706
Adjust nlinesw correctly.
2000-11-15 01:42:53 +00:00
enami
54f723723a
Cosmetic changes.
2000-11-15 01:41:22 +00:00
thorpej
be14fd9db1
Use round_page() instead of roundup(..., NBPG).
2000-11-14 22:23:06 +00:00
thorpej
e39f7bbe1c
NBPG -> PAGE_SIZE
2000-11-14 22:16:38 +00:00
thorpej
38ee35826a
NBPG -> PAGE_SIZE.
2000-11-14 22:14:53 +00:00
thorpej
b7d004daa6
Use round_page() instead of roundup(..., NBPG).
2000-11-14 22:13:20 +00:00
itojun
68f0fe3840
make sure every m_aux will be freed.
...
there are direct use of MFREE() from sys/kern.
(we experienced no memory leak so far, but if we use m_aux for other purposes,
we will need this change)
2000-11-14 20:05:28 +00:00
jdolecek
78b866e95a
change the type of *syscallnames[] array to 'const char * const foo[]'
2000-11-13 21:32:15 +00:00
jdolecek
ab8c5177be
use SIGACTION() macro to get on appropriate sigaction
...
structure
2000-11-12 18:17:56 +00:00
eeh
df87630144
Add console magic sequence framework.
2000-11-08 22:41:58 +00:00
ad
642267bcc7
Update for hashinit() change.
2000-11-08 14:28:12 +00:00
ad
5fcf59fd7c
Allow for creation of both LIST and TAILQ based hashes by adding a `hash
...
type' argument to hashinit().
2000-11-08 14:25:23 +00:00
chs
ff1e758c8c
use round_page(...) instead of roundup(..., NBPG).
2000-11-08 05:53:10 +00:00
chs
a74393b970
remove unneeded includes.
2000-11-08 05:47:56 +00:00
chs
a284236c04
in fork1(), only add make the new proc visible (by giving it a pid
...
and adding it to allproc) after it's fully initialized.
this prevents the scheduler from coming in via a clock interrupt
and tripping over a partially-initialized proc.
2000-11-08 05:16:23 +00:00