Commit Graph

189 Commits

Author SHA1 Message Date
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