Commit Graph

365 Commits

Author SHA1 Message Date
chs
94622623d8 in pmap_enter(), preset the mod/ref bits based on the flags argument.
fixes 25640.
2005-05-29 15:56:59 +00:00
kleink
4a6a03b162 Include <sys/cdefs.h> for __signed; related to lib/30072. 2005-05-25 20:58:00 +00:00
fvdl
a893ac9f67 If p->emul->e_usertrap is set, call it for T_USER|T_PAGEFAULT traps to
do possible work.
2005-05-20 12:49:14 +00:00
fvdl
0f3ab60285 Get the pcb_flags test right for the 64bit FS base case. 2005-05-17 15:14:47 +00:00
fvdl
bce752852d Translate linux errno in the syscall_fancy case as well. 2005-05-17 13:47:17 +00:00
fvdl
5e91d058da Translate error numbers in the COMPAT_LINUX case. 2005-05-16 11:55:24 +00:00
fvdl
631e44f47d Move linux_trap.c from sys/arch/i386/i386 to sys/arch/x86/x86, and share
it. Remove the amd64 linux_trap.c (which was just a stub with a printf
anyway).
2005-05-15 22:20:23 +00:00
fvdl
7d91366682 Fix up COMPAT_LINUX support for amd64. Still a work in progress, not
usable yet ("Hello World" runs, but many other things do not work).
2005-05-15 21:44:41 +00:00
fvdl
2f9b8a3b68 Start at implementing USER_LDT. Doesn't compile yet (but it didn't previously
either).
2005-05-15 21:42:01 +00:00
fvdl
eeb59b85ad New definitions for LDT system call arguments, amd64 version. Compatible
with the Linux interface. As yet unused.
2005-05-15 21:39:56 +00:00
fvdl
69aa2aa9e8 Optionally include saving and restoring the 64bit %gs and %fs base register
values in the PCB. Do this in pmap_activate for now (XXX not a good place
for it, but a convenient one).
2005-05-15 21:37:46 +00:00
manu
89647c7ca6 First work on COMPAT_LINUX/amd64
Process startup and dynamiclinking work, but processes hang due to
Linux arch_prctl(2) not being really supported yet.
2005-05-03 16:26:27 +00:00
lukem
3fd1802e62 Move the MI printing of `copyright' to the MD cpu_startup() code
where the printing of `version' is already performed.
This has the benefit of allowing the copyright to be available
via dmesg(8) on platforms which need the `msgbuf' to be setup
in cpu_startup() before printed output is remembered.
2005-04-25 15:02:02 +00:00
yamt
1d12c53188 add files which i forgot to add with arch/x86/x86/bus_dma.c rev.1.21. 2005-04-16 08:53:09 +00:00
itohy
d665949330 Add ukyopon(4). 2005-04-15 17:27:20 +00:00
tron
7b5f51876d Comment out options for PPP compression and active filtering. They are not
necessary in an installation kernel but increase the size considerably.
This fixes PR port-amd64/29928.
2005-04-10 07:53:06 +00:00
tron
e84fd6c37d Comment out some wscons(4) options which are only required to run a
X11 server.
2005-04-09 13:07:23 +00:00
yamt
6b2d8b66a4 merge yamt-km branch.
- don't use managed mappings/backing objects for wired memory allocations.
  save some resources like pv_entry.  also fix (most of) PR/27030.
- simplify kernel memory management API.
- simplify pmap bootstrap of some ports.
- some related cleanups.
2005-04-01 11:59:21 +00:00
fvdl
c487efe4a7 Fix some things regarding COMPAT_NETBSD32 and limits/VM addresses.
* For sparc64 and amd64, define *SIZ32 VM constants.
* Add a new function pointer to struct emul, pointing at a function
  that will return the default VM map address. The default function
  is uvm_map_defaultaddr, which just uses the VM_DEFAULT_ADDRESS
  macro. This gives emulations control over the default map address,
  and allows things to be mapped at the right address (in 32bit range)
  for COMPAT_NETBSD32.
* Add code to adjust the data and stack limits when a COMPAT_NETBSD32
  or COMPAT_SVR4_32 binary is executed.
* Don't use USRSTACK in kern_resource.c, use p_vmspace->vm_minsaddr
  instead (emulations might have set it differently)
* Since this changes struct emul, bump kernel version to 3.99.2

Tested on amd64, compile-tested on sparc64.
2005-03-26 05:12:34 +00:00
cube
78f44cbe4f Add attimer(4) configurations everywhere pcppi(4) exists, with the
following rule:
  If a pcppi device is enabled for an attachment, enable an attimer for the
  same attachement, otherwise comment it.
2005-03-25 23:28:43 +00:00
xtraeme
f9dbeebf6f Add "pcppi* at acpi?" commented out. 2005-03-21 14:15:27 +00:00
cgd
382487d844 correctly alphabetize bce, skc/sk, inphy relative to their neighbors.
devices.  correct typo in bce comment.
2005-03-21 01:57:54 +00:00
fvdl
486492d83a Check the passed in address as well as determining the maximum length
using VM_MAXUSER_ADDRESS in copyinstr and copyoutstr.

Problem originally fixed in OpenBSD/i386.
This fix suggested by Charles Hannum (mycroft at netbsd dot org).
2005-03-14 21:50:59 +00:00
matt
bffeda4273 Add cpu* at mainbus0 2005-03-11 16:44:31 +00:00
matt
038bc7aa3a Add disasm support for amd64 (x86-64).
From Cliff Neighbors.
2005-03-01 18:08:42 +00:00
dsl
b3675ff77c Enable FFS_NO_SNAPSHOT in the INSTALL kernel so that it fits into 2 floppies 2005-02-27 12:38:42 +00:00
simonb
ff8f0b23c9 Add COMPAT_20 (and COMPAT_16 in some cases) to kernel config files
that didn't have those options but had other earlier compat options.
2005-02-25 13:46:48 +00:00
jdolecek
e60805c699 add ciphy(4) and vge(4) 2005-02-20 18:49:26 +00:00
dsl
4822cbaae2 Invert FFS_SNAPSHOT to FFS_NO_SNAPSHOT 2005-02-18 21:05:50 +00:00
ws
b2bdc38871 Prevent integer overflow.
Fixes PR29332.
2005-02-11 11:01:10 +00:00
dsl
05e2f6ebdb Add 'option FFS_SNAPSHOT' to most of the config files.
Commented out for kernels that appear to hace space constraints.
2005-02-11 08:25:53 +00:00
ws
5964df620b Increase max data size, now that the Xserver can grok it.
(It was the only program that couldn't.)
2005-02-10 10:42:04 +00:00
fvdl
6851058ed5 if 0 out the parts of the code that allocated VM space per CPU for GDTs.
Seperate GDTs are not used on amd64 because it doesn't need any seperate
descriptors per CPU.
2005-02-08 09:02:01 +00:00
hannken
d5fbb6936f Add file system snapshots to kernel configs.
- Ffs internal snapshots get compiled in unconditionally.

- File system snapshot device fss(4) added to all kernel configs that
  have a disk.  Device is commented out on all non-GENERIC kernels.

Reviewed by: Jason Thorpe <thorpej@netbsd.org>
2005-01-31 16:54:32 +00:00
rumble
de81c2c878 Sprinkle options UFS_DIRHASH on GENERIC kernels. It's presently
commented out and labeled experimental pending further review and
testing.
2005-01-28 03:19:49 +00:00
scw
4db6edf008 Add "options PMS_SYNAPTICS_TOUCHPAD", commented out by default. 2005-01-18 10:30:11 +00:00
cube
ec53a61e98 Add tap(4) support to a random^Wcarefully chosen set of kernel configs.
All those kernels have a line for both tun and bridge, and if either is
commented out, tap is commented out also.  With the exception of i386's
GENERIC_TINY.

XXX:  we _need_ some way of making this more simple.
2005-01-17 15:28:51 +00:00
yamt
1207308b90 for in-kernel maps,
- allocate kva for vm_map_entry from the map itsself and
  remove the static limit, MAX_KMAPENT.
- keep merged entries for later splitting to fix allocate-to-free problem.
  PR/24039.
2005-01-01 21:00:06 +00:00
christos
2819137180 change the definition of va_start for lint. 2004-12-30 18:08:20 +00:00
xtraeme
76025558e1 Add ACPI joy(4) attachment, based on lpt_acpi.c by jmcneill@,
reviewed and ok'ed by cube@ and martin@.
2004-12-02 14:33:31 +00:00
xtraeme
347378fc9f Add ACPI mpu(4) attachment, based on lpt_acpi.c by jmcneill@,
reviewed by christos@, cube@ and martin@.

While here, remove a printf() in mpu_attach() (ic/mpu.c) to remove
an empty line in some frontends (mpu_isa.c, etc).
2004-12-02 09:50:41 +00:00
bouyer
fe4d81db48 pdcsata(4), a driver for the Promise SATA150 (aka PDC203xx) serie of
controllers. Tested with a PDC20375 (2 SATA, one PATA) controller on sparc64.
Added to all kernel config file which had pdcide(4).
2004-11-24 20:49:17 +00:00
christos
30fc143afa Add COMPAT_BSDPTY to the rest of the config files. 2004-11-10 17:54:02 +00:00
christos
eec07087aa Add COMPAT_BSDPTY on all the kernels that have COMPAT options. 2004-11-10 17:25:21 +00:00
yamt
6e71418936 use __insn_barrier rather than homegrown equivalents. 2004-10-31 10:39:34 +00:00
yamt
fa29ea9740 to determine if an interrupt needs to grab the kernel lock or not,
check interrupt's own ipl rather than cpu's current ipl.
2004-10-23 21:24:05 +00:00
thorpej
dc2f2fbe74 Centralize the declaration of booted_device and booted_partition. 2004-10-23 17:07:37 +00:00
augustss
0c21c79cc5 s/uax/axe/ 2004-10-23 14:00:50 +00:00
fvdl
5febc5eef5 Fix thread context switching to take the stack ABI into account.
From Wolfgang Solfrank.
2004-10-21 16:49:47 +00:00
thorpej
42b8fac3b8 Move boot device detection code from i386 and amd64 ports to x86_autoconf.c.
Rename i386_alldisks and x86_64_alldisks to x86_alldisks, adjust other
references to compensate.
2004-10-20 04:20:05 +00:00
thorpej
32ca684d72 match_harddisk(): Open RAW_PART, not the booted partition; we're
only performing the ioctl to fetch the disklabel.
2004-10-15 06:18:47 +00:00
yamt
7c63ceab48 don't expose cpu_info and friends to userland. 2004-09-25 11:08:47 +00:00
yamt
17dfcbf73e fix a typo in a comment. 2004-09-25 03:05:23 +00:00
yamt
d2fe4b34bb move some per-cpu data definitions to MI place so that they can be modified
without touching all ports.  discussed on tech-kern@.
2004-09-22 11:32:02 +00:00
skrll
f7155e40f6 There's no need to pass a proc value when using UIO_SYSSPACE with
vn_rdwr(9) and uiomove(9).

OK'd by Jason Thorpe
2004-09-17 14:11:20 +00:00
fvdl
2a1aa1e67d Remove some devices (sync with i386). 2004-09-13 22:33:47 +00:00
manu
6e3c639957 IPv4 PIM support, based on a submission from Pavlin Radoslavov posted on
tech-net@
2004-09-04 23:29:44 +00:00
drochner
070747cba1 remove the (superfluous) definition of "cpu" as an interface attribute 2004-08-30 15:35:20 +00:00
drochner
46289e1fef Phase out the use of a string as first "attach args" member to control
which bustype should be attached with a specific call to config_found()
(from a "mainbus" or a bus bridge).
Do it for isa/eisa/mca and pci/agp for now. These buses all attach to
an mi interface attribute "isabus", "eisabus" etc., and the autoconf
framework now allows to specify an interface attribute on config_found()
and config_search(), which limits the search of matching config data
to these which attach to that specific attribute.
So we basically have to call config_found_ia(..., "foobus", ...) where
such a bus is attached.
As a consequence, where a "mainbus" or alike also attaches other
devices (eg CPUs) which do not attach to a specific attribute yet,
we need at least pass an attribute name (different from "foobus") so
that the foo bus is not found at these places. This made some minor
changes necessary which are not obviously related to the mentioned buses.
2004-08-30 15:05:15 +00:00
thorpej
6c08646cb8 Garbage-collect pagemove(); nothing use it anymore (YAY!!!) 2004-08-28 22:12:40 +00:00
jdolecek
64969161df use uvm_grow() to update stack segment size on stack page fault instead
of MD code
2004-08-28 17:53:00 +00:00
drochner
5a11f34433 The amd64 address space layout is different.
We can't assume that kernel addresses are below
VM_MAX_KERNEL_ADDRESS.
2004-08-10 18:57:09 +00:00
yamt
9cc3176930 kvtopte: use a correct base addr for LARGEPAGES. 2004-08-08 09:47:05 +00:00
yamt
a37fba2a04 correct VAs in a comment. 2004-08-08 09:40:48 +00:00
yamt
b606f3e999 reduce gratuitous whitespace/comment differences from i386. 2004-08-08 09:38:50 +00:00
cube
3cdea73b10 boothowto is already available through sys/systm.h, and is actually
declared elsewhere;  don't duplicate it.
2004-08-05 13:31:38 +00:00
atatat
f68a9f1ff2 Add "options SYSCTL_INCLUDE_DESCR" to a lot of configs, but commented
out in most of them.
2004-07-15 03:53:44 +00:00
drochner
2706519f5d add a <machine/joystick.h> which just includes the new common one 2004-07-02 17:02:24 +00:00
fvdl
029ca90566 Updaing ci_ilevel and testing ci_ipending must be done with all interrupts
off, or priority inversion can occur, which can lead to IPI deadlocks.
Leaves interrupts off for a bit longer, sadly, but with no noticeable
effects on the systems I tested on.

From YAMAMOTO Takashi.
2004-06-28 09:13:11 +00:00
fvdl
07a2b21f39 Set the double fault stack pointer at the end of the stack. 2004-06-28 08:23:21 +00:00
abs
bd8eb3b5ed Add (commented out) ALTQ options to all GENERIC-like files 2004-06-26 07:32:05 +00:00
toshii
792bff8d3c Add re; Realtek GbE. 2004-06-22 15:31:38 +00:00
toshii
a9b9fd4313 Add re; Realtek GbE. 2004-06-22 15:18:33 +00:00
itojun
596aec9a47 have pf and pflog pseudo-device (commented out).
reviewed by matt, perry, christos
2004-06-22 14:09:49 +00:00
christos
c22e4ed8cd ptm is now mandatory, depends on pty, and can be disabled with -DNO_DEV_PTM 2004-06-18 15:02:29 +00:00
jmc
a901947b0f Pull in machine/fpu.h to pick up fxsave64 2004-06-18 04:09:29 +00:00
fvdl
26759c3afa When converting GDT length units from segment structures to bytes for the
amd64 port, I converted MINGDTSIZ wrongly; it was not page aligned, causing
gdt_grow to corrupt the GDT. Fix this, and remove the extraneous definitions
of the sizes from gdt.c.

From OpenBSD.
2004-06-16 17:45:03 +00:00
christos
0399e839cf Add pseudo-device ptm on all the generic flavored kernels. 2004-06-16 15:07:39 +00:00
fvdl
2c51ec74d3 Start at the top of the double fault stack, not the bottom. 2004-06-16 10:13:46 +00:00
fvdl
f24cbf3372 Remove IDT protection while doing unsetgate too. 2004-06-16 10:01:31 +00:00
fvdl
5c568543d4 Make the IDT read-only. It's only mapped R/W when really needed. Could
catch disasters such as overwriting it. Should probably be made
conditional on DIAGNOSTIC later, but there's no time-critical code
involved here.

Move the double fault stack away from the IPI stack. It's now shared
between CPUs, but that's not a big deal; double faults are fatal
and can't be recovered from.
2004-06-15 11:35:27 +00:00
fvdl
45692cb944 A double fault always pushes a 0. 2004-06-15 11:28:23 +00:00
fvdl
3f3313c442 Implement pmap_changeprot_local 2004-06-15 11:28:04 +00:00
fvdl
3b31d7b8a5 Add a prototype for pmap_changeprot_local, a function that changes
protection for a page and doesn't care about TLB shootdowns.
2004-06-15 11:27:38 +00:00
kleink
c004d32eb8 Reflect <sys/endian.h> rev. 1.4: make htonl() et al. arguments and
results uint{16,32}_t.  Noted by Ian Zagorskih.
2004-06-10 16:01:39 +00:00
kochi
96f8bc3637 Add ACPICA_PEDANTIC/ACPI_DISABLE_ON_POWEROFF options; follow the i386
changes.
2004-06-07 15:36:22 +00:00
sekiya
f7212a9a5d Use the SPLAY_* macros. Copied from the i386 pmap, okay'ed by fvdl@ 2004-06-04 07:42:33 +00:00
thorpej
e33c2bb5d5 Add the %MAKEOPTIONSAPPEND token at the end of the file, after the
common Makefile.kern.inc has been included.
2004-06-04 04:45:49 +00:00
sekiya
4ae860025d Make pmap_collect() a NOP -- due to the way we deal with the four-level pte,
invalidating the entire address space results in multi-minute system hangs.

Okay'ed by fvdl@
2004-05-31 13:42:27 +00:00
kleink
8b9e7c1154 Change {u,}int_fast{8,16}_t to 32-bit types.
Note: While this is technically an ABI change I believe it is a
change that we can afford at this time (and to be pulled up to
2.0, which will be the first release for amd64).  The types are
not widely used yet, and a survey of pkgsrc has not shown uses
that would be adversely affected by it.
2004-05-23 22:17:10 +00:00
thorpej
07a9ee32ba Don't need cz or cy devices in INSTALL kernel, and they put space
pressure on install media.
2004-05-11 17:36:43 +00:00
drochner
19f047f8d0 SIGTRAMP_VALID() should not pollute the user namespace 2004-05-10 21:51:49 +00:00
kleink
7b3b647647 Factor out W{CHAR,INT}_{MAX,MIN} into their own header file. 2004-05-08 21:51:47 +00:00
toshii
46c8f26134 #include acpi.h and some others to be able to powerdown via acpi. 2004-05-03 08:59:38 +00:00
toshii
a73f92f0e2 Compile TSC support code when __x86_64__ is defined. 2004-04-30 17:58:04 +00:00
itojun
6123043789 pass string length (= boundary info) to pci_devinfo so that we do not run over
the end of memory region
2004-04-23 21:13:05 +00:00
fvdl
07fd2b039b Adapt for new aapic.c location. 2004-04-18 18:36:56 +00:00
fvdl
9a03155b3f Move these files to x86, so that the i386 port can use them too
(for booting i386 kernels on amd64 machines).
2004-04-18 18:33:33 +00:00
fvdl
7a44f0ad1f Make tracing work better (through interrupts, etc). Essentially a synch
with i386.
2004-04-16 14:21:56 +00:00
drochner
568386df44 We should ensure stack alignment _after_ subtracting sizeof(sigframe).
Should fix PR bin/24948 by Wolfgang S. Rupprecht.
(nuke getframe() completely because its interface doesn't support this,
and it it used at one place only anyway)
2004-03-28 15:46:14 +00:00
drochner
c83eb997b8 nothing cares about __HAVE_SIGINFO anymore, so nuke it 2004-03-26 21:39:57 +00:00
drochner
88a4abdbd2 the whole sigcode business is COMPAT_16 only 2004-03-26 18:44:36 +00:00
drochner
cb0991ae18 Native code doesn't need sigcode. Never.
So replace it by a dummy setting sigcode=esigcode=0, just to get
COMPAT_16+COMPAT_NETBSD32 kernels linking.
2004-03-25 18:33:17 +00:00
drochner
967b985e5b clean up the .globl confusion 2004-03-25 15:47:12 +00:00
drochner
be80b39cd6 remove sigcontext-style signal delivery code 2004-03-25 15:32:27 +00:00
drochner
e2afc3a3d8 always use siginfo-style signal delivery for native programs 2004-03-25 15:29:26 +00:00
drochner
badd642235 only accept signal trampoline version 2, and remove "struct sigcontext" 2004-03-25 15:27:26 +00:00
atatat
19af35fd0d Tango on sysctl_createv() and flags. The flags have all been renamed,
and sysctl_createv() now uses more arguments.
2004-03-24 15:34:46 +00:00
drochner
ab2eb6de06 put the old and the very old syscall glue into appropriate
COMPAT_ conditionals
2004-03-23 19:39:42 +00:00
drochner
35b8d1d3ff initialize the old "int 0x80" syscall only for COMPAT_16/NETBSD32,
and the very old callgate for COMPAT_10/IBCS2
2004-03-23 19:35:16 +00:00
drochner
be0359e629 -don't refer to oosyscall() unless COMPAT_10 or COMPAT_IBCS2 is defined
-improve diagnostic message on bus errors in the TRAP_SIGDEBUG case
2004-03-23 19:09:01 +00:00
drochner
ea5ee473a8 bump default data size to 256M, enough to build a "-g" kernel 2004-03-23 18:54:32 +00:00
cl
ea5ec0212d add kernel part of concurrency support for SA on MP systems
- move per VP data into struct sadata_vp referenced from l->l_savp
  * VP id
  * lock on VP data
  * LWP on VP
  * recently blocked LWP on VP
  * queue of LWPs woken which ran on this VP before sleep
  * faultaddr
  * LWP cache for upcalls
  * upcall queue
- add current concurrency and requested concurrency variables
- make process exit run LWP on all VPs
- make signal delivery consider all VPs
- make timer events consider all VPs
- add sa_newsavp to allocate new sadata_vp structure
- add sa_increaseconcurrency to prepare new VP
- make sys_sa_setconcurrency request new VP or wakeup idle VP
- make sa_yield lower current concurrency
- set sa_cpu = VP id in upcalls
- maintain cached LWPs per VP
2004-03-14 01:08:47 +00:00
bjh21
dff5222d3a Abstract the interface between pckbc(4), and the pckbd(4) and pms(4)
drivers that attach to it.  This allows for other host interface chips
that use the same keyboards and mice, such as the ones in the ARM
IOMD20, ARM7500, and SA-1111.  The PC-compatible driver is still
called pckbc(4), and the new abstraction layer is "pckbport", so the
child devices have moved from sys/dev/pckbc to sys/dev/pckbport, which
also contains some code shared between all host controllers.  To avoid
incompatibility, pckbdreg.h is still installed in
/usr/include/dev/pckbc.

In theory, this shouldn't cause any behavioural changes in the drivers
concerned.  Thy just use rather more function pointers than before.  Tested
on i386 and (with a new host driver) acorn32.  Compiled on several other
affected architectures.
2004-03-13 17:31:33 +00:00
drochner
d56da55ea4 -oops - correct the x87 si_code reporting to use the current fsw
-for XMM traps, report mxcsr in si_trap
2004-03-05 21:21:14 +00:00
drochner
571265fc35 deal with XMM exceptions
(I'm not sure whether it is right to clear the "sticky"
exception bits here, but in the i387 case even the whole
FPU is initialized...)
2004-03-05 17:20:13 +00:00
drochner
302b606369 fix some problems with lazy fpu context handling:
-if a new process gets a CPU with an FPU state of another process, it
 needs to initialize it to a clean state
 (actually, put the "fninit" where it belongs logically)
-initialize mxcsr as well
minor cleanup/optimization
Signal delivery after unmasking some cause is still broken - it doesn't
care about xmm exceptions. For now, set at least si_code to something
positive so that it doesn't look like a user generated asynchonous signal.
2004-03-03 20:27:53 +00:00
drochner
98dbb9f046 on (fast) syscall exit, force %ds to its standard value --
it might have been modified by a netbsd32 process
2004-03-01 12:10:41 +00:00
drochner
7925327e58 set MDP_IRET in cpu_setmcontext() - the normal (fast)
syscall exit is not able to propagate all register
arguments
2004-03-01 12:06:02 +00:00
drochner
972fe86c42 Provide a dummy cpu_exec_aout_makecmds() to make a kernel
with COMPAT_NETBSD32+COMPAT_AOUT link.
netbsd-1.3/i386 binaries are running now.
2004-02-20 18:11:16 +00:00
drochner
289fa68010 provide a definition NETBSD32_MID_MACHINE which tells for the a.out MID
to look for in 32-bit emulation
2004-02-20 16:11:44 +00:00
drochner
2982fa170d use no-execute page permissions if supported 2004-02-19 17:18:38 +00:00
thorpej
e1e9cfd40a Comment out some SYSV* and *VERBOSE options to shrink these down so
they fit in the current boot floppies.
2004-02-16 02:43:53 +00:00
drochner
8d3cefb29e grab the kernel lock during 32-bit syscalls too 2004-02-13 17:07:56 +00:00
wiz
d20841bb64 Uppercase CPU, plural is CPUs. 2004-02-13 11:36:08 +00:00
matt
b820eb3ad3 32-bit corefiles should use a MID for i386, not xf86_64. 2004-02-11 01:01:37 +00:00
mrg
719a671e87 back out previous; it was only required for a dead function. 2004-01-21 11:31:20 +00:00
jdolecek
46fdc63ac8 add register64_t which appears to be necessary for COMPAT_NETBSD32 nowadays 2004-01-20 20:30:41 +00:00
jdolecek
6c14651ea0 cleanup old lpt(4) attachment, and glue ppbus in so that they can coexist:
* lpt device is defined in MI place (dev/ppbus/files.ppbus), dev/ic/lpt.c
  is included there too; dev/ic/lpt.c is not included if ppbus is
  configured or if there is alternative platform lpt (like for pc532)
* g/c MD lpt definitions and custom puc/upc attachments,
  glue moved to conf/files and dev/pci/files.pci respectively; remove
  device lpt definition from dev/isa/files.isa
* add ppbus parport attribute, atppc device attachments, adjust plip and lpt
  glue
2004-01-20 19:58:00 +00:00
martin
da4e67accc Do not export __HAVE_RAS to userland. Applications are supposed to try
rasctl() and detect failure with EOPNOTSUPP.
2004-01-18 18:23:19 +00:00
jonathan
abb59e6f0c Add support for opencrypto, PCI accelerators to sys/arch/*/conf/GENERIC
files for machines I know to have genuine PCI slots.  As sent to tech-kern
for feedback in December 2003. Based on feedback, opencrypto is commented
out in the macppc GENERIC (due to absense of GENERIC_SOFTINT support),
and added to the sparc64 config (sys/arch/sparc64/conf/GENERIC32).
2004-01-14 22:29:03 +00:00
yamt
7246e2cc80 issue memory read barrier for BUS_DMASYNC_POSTREAD operation.
PR/21665 from Stephan Uphoff.
2004-01-14 11:31:55 +00:00
jdolecek
0ee51a3dec finish previous (removal of 'reaper' kernel thread):
* move tss_free() call to the new cpu_lwp_free()
* g/c cpu_wait()

fixes PR kern/24067 by Nicolas Joly
2004-01-12 14:31:46 +00:00
jdolecek
089abdad44 Rearrange process exit path to avoid need to free resources from different
process context ('reaper').

From within the exiting process context:
* deactivate pmap and free vmspace while we can still block
* introduce MD cpu_lwp_free() - this cleans all MD-specific context (such
  as FPU state), and is the last potentially blocking operation;
  all of cpu_wait(), and most of cpu_exit(), is now folded into cpu_lwp_free()
* process is now immediatelly marked as zombie and made available for pickup
  by parent; the remaining last lwp continues the exit as fully detached
* MI (rather than MD) code bumps uvmexp.swtch, cpu_exit() is now same
  for both 'process' and 'lwp' exit

uvm_lwp_exit() is modified to never block; the u-area memory is now
always just linked to the list of available u-areas. Introduce (blocking)
uvm_uarea_drain(), which is called to release the excessive u-area memory;
this is called by parent within wait4(), or by pagedaemon on memory shortage.
uvm_uarea_free() is now private function within uvm_glue.c.

MD process/lwp exit code now always calls lwp_exit2() immediatelly after
switching away from the exiting lwp.

g/c now unneeded routines and variables, including the reaper kernel thread
2004-01-04 11:33:29 +00:00
pk
70f20a1217 Replace the traditional buffer memory management -- based on fixed per buffer
virtual memory reservation and a private pool of memory pages -- by a scheme
based on memory pools.

This allows better utilization of memory because buffers can now be allocated
with a granularity finer than the system's native page size (useful for
filesystems with e.g. 1k or 2k fragment sizes).  It also avoids fragmentation
of virtual to physical memory mappings (due to the former fixed virtual
address reservation) resulting in better utilization of MMU resources on some
platforms.  Finally, the scheme is more flexible by allowing run-time decisions
on the amount of memory to be used for buffers.

On the other hand, the effectiveness of the LRU queue for buffer recycling
may be somewhat reduced compared to the traditional method since, due to the
nature of the pool based memory allocation, the actual least recently used
buffer may release its memory to a pool different from the one needed by a
newly allocated buffer. However, this effect will kick in only if the
system is under memory pressure.
2003-12-30 12:33:13 +00:00
thorpej
2f2ca9e66b Split the Intel i31244 SATA controller ("Artisea") driver out of piixide
into its own driver (artsata).
2003-12-14 01:32:01 +00:00
thorpej
98f7d12017 Split out the Silicon Image SATALink support into its own driver,
"satalink".
2003-12-13 23:13:40 +00:00
jmc
695a2a2f9f Change reference at bottom from sys/dev/majors to sys/conf/majors to match
reality
2003-12-10 02:04:00 +00:00
fvdl
e16473e240 Segment registers are only 16 bits wide, so only check 16 bits worth of
them for validity in check_mcontext.
2003-12-06 17:35:44 +00:00
atatat
13f8d2ce5f Dynamic sysctl.
Gone are the old kern_sysctl(), cpu_sysctl(), hw_sysctl(),
vfs_sysctl(), etc, routines, along with sysctl_int() et al.  Now all
nodes are registered with the tree, and nodes can be added (or
removed) easily, and I/O to and from the tree is handled generically.

Since the nodes are registered with the tree, the mapping from name to
number (and back again) can now be discovered, instead of having to be
hard coded.  Adding new nodes to the tree is likewise much simpler --
the new infrastructure handles almost all the work for simple types,
and just about anything else can be done with a small helper function.

All existing nodes are where they were before (numerically speaking),
so all existing consumers of sysctl information should notice no
difference.

PS - I'm sorry, but there's a distinct lack of documentation at the
moment.  I'm working on sysctl(3/8/9) right now, and I promise to
watch out for buses.
2003-12-04 19:38:21 +00:00
keihan
29c72c57f0 netbsd.org -> NetBSD.org
All "netbsd.org" is now gone from src/sys/arch.
2003-12-04 13:05:15 +00:00
fvdl
c7242676d3 Don't use an alternate stack for the trace/breakpoint trap. It can be
called from userspace, and that messes things up.

Thanks to Mark Kettenis to pointing out that not using an alt stack
solved the "loop on gdb sig continuation" issue.
2003-12-01 00:00:07 +00:00
fvdl
22bb1f01c7 Reenable interrupts sooner in the idle_exit case. 2003-11-30 23:58:51 +00:00
fvdl
d8ec3cb507 Keep mxcsr and mxcsr_mask across the fake init in process_read_fpregs.
From Mark Kettenis.
2003-11-30 12:59:30 +00:00
fvdl
ebc6dbad07 Define the mcount function in assembler, and have it save all registers
used for argument passing, plus %rax (used to pass the number of float
arguments to varargs functions), to avoid having it clobber caller-saved
registers. mcount is emitted "under the radar", so the compiler doesn't
know it should do this.

Change the kernel mcount entry/exit macros to use plain cli/sti, like on i386.
2003-11-28 23:22:45 +00:00
christos
a21fdf3b43 bye, bye _MCONTEXT_TO_SIGCONTEXT and vice versa. 2003-11-25 23:11:52 +00:00
fvdl
6f7ba6556b Add and enable sk/skc drivers. 2003-11-22 14:20:47 +00:00
wiz
ee1b406595 Spell address with two d's. Inspired by similar changes in OpenBSD,
originating from Jonathon Gray and forwarded by jmc@openbsd.
2003-11-10 08:51:51 +00:00
fvdl
0a3fa4cdb1 Trim ramdisk and remove some unneeded options. 2003-11-10 00:52:28 +00:00
fvdl
f601ca945b Add POSIX 1003.1b semaphores. 2003-11-08 21:38:18 +00:00