Commit Graph

1073 Commits

Author SHA1 Message Date
tsutsui
0f22466110 Use #define<tab> consistently. 2009-04-05 00:57:56 +00:00
tsutsui
47fb91c8ba Remove __HAVE_UFS2_BOOT since it belongs to sysinst for now.
"Feel free to change it" by ad@.
2009-04-05 00:54:21 +00:00
ad
95e4ccac55 +__HAVE_UFS2_BOOT 2009-04-04 10:36:08 +00:00
enami
09fcc8b316 So that profile kernel runs again,
- Adjust the size of functions used to patch.
- Fix the jump offset of mcount call when patching functions.

Approved by Andrew Doran.
2009-04-02 00:19:02 +00:00
rmind
44170e3c3a Merge i386 and amd64 ipifuncs.c into x86. No functional changes intended.
XXX: fpu #ifdefs are ugly (should be revisited at some point).
2009-03-30 22:28:39 +00:00
rmind
70456c4d9e Merge i386 and amd64 vm_machdep.c into x86. No functional changes intended.
Note: some #ifdefs will be removed with macros.
2009-03-30 22:20:55 +00:00
rmind
74a033c8eb Merge/move core_machdep.c into x86, no difference between i386 and amd64. 2009-03-30 22:13:42 +00:00
ad
ead83a47c8 _lwp_setprivate: provide the value to MD code if a hook is present.
This will be used to support TLS. The MD method must match the ELF TLS spec
for that CPU architecture (if there is a spec).

At this time it is only implemented for i386, where it means setting the
per-thread base address for %gs. Please implement this for your platform!
2009-03-29 09:24:52 +00:00
rmind
a3e23c67f6 Reduce some differences between i386 and amd64.
Mainly cosmetical changes - no functional changes intended.
2009-03-29 01:10:28 +00:00
rmind
ee70d529c3 Change amd64 fault handler to check instruction pointer for copyin/out et al
functions, like in i386.  Avoids setting pcb_onfault, saves few instructions.
2009-03-28 22:56:19 +00:00
rmind
1ce95d231e x86_64_ipi_halt: unset CPU as running (sync with i386). 2009-03-28 22:03:27 +00:00
rmind
0d4fdf8b96 kvtop: change return type to paddr_t. 2009-03-28 21:34:17 +00:00
rmind
eefc2d042b mmrw: add missing pmap_update(). 2009-03-28 21:23:44 +00:00
rmind
a7fde9e6fa cpu_coredump: pass UIO_SYSSPACE to coredump_write(), not UIO_USERSPACE. 2009-03-28 21:21:29 +00:00
cegger
8d8839858d catch up with i386 xen kernels:
enable cgd by default
2009-03-25 06:26:44 +00:00
ad
dabb2cae17 Set up module_map correctly so that the system does not panic if it
becomes full.
2009-03-22 19:57:11 +00:00
ad
d16d704d62 PR port-i386/40143 Viewing an mpeg transport stream with mplayer causes crash
Fix numerous problems:

1. LDT updates are not atomic.

2. Number of processes running with private LDTs and/or I/O bitmaps
   is not capped. System with high maxprocs can be paniced.

3. LDTR can be leaked over context switch.

4. GDT slot allocations can race, giving the same LDT slot to two procs.

5. Incomplete interrupt/trap frames can be stacked.

6. In some rare cases segment faults are not handled correctly.
2009-03-21 14:41:29 +00:00
cegger
e2cb85904d bcopy -> memcpy 2009-03-18 17:06:41 +00:00
cegger
5c4da6d6bc ansify function definitions 2009-03-15 14:21:48 +00:00
dsl
82357f6d42 ANSIfy another 1261 function definitions.
The only ones left in sys are beyond by sed script!
(or in sys/dist or sys/external)
Mostly they have function pointer parameters.
2009-03-14 21:04:01 +00:00
dsl
454af1c0e8 Change about 4500 of the K&R function definitions to ANSI ones.
There are still about 1600 left, but they have ',' or /* ... */
in the actual variable definitions - which my awk script doesn't handle.
There are also many that need () -> (void).
(The script does handle misordered arguments.)
2009-03-14 15:35:58 +00:00
dsl
02cdf4d2c8 Remove all the __P() from sys (excluding sys/dist)
Diff checked with grep and MK1 eyeball.
i386 and amd64 GENERIC and sys still build.
2009-03-14 14:45:51 +00:00
yamt
aa75a65af2 add a missing _KERNEL_OPT ifdef. 2009-03-11 04:16:43 +00:00
joerg
f5b0fec0e0 Remove SHMMAXPGS from all kernel configs. Dynamically compute the
initial limit as 1/4 of the physical memory. Ensure the limit is at
least 1024 pages, the old default on most platforms.
2009-03-06 20:31:46 +00:00
cegger
61b1fbae0d add options COMPAT_50 2009-03-06 10:48:27 +00:00
cegger
8e35c3d94f add age(4) and atphy(4) 2009-03-06 09:58:14 +00:00
bouyer
2c02d488fa Add pciback device to XEN3 dom0 kernels 2009-03-05 19:51:49 +00:00
nisimura
ff2a35dca2 comment out NFS_BOOT_BOOTSTATIC. It will be useful when a valid set of
NFS_BOOTSTATICs are specfied.
2009-03-04 07:31:33 +00:00
jmcneill
7d16528c20 PR# port-i386/40751: power button does not work after halt
PR# kern/37506: Have to hold power button for 5 seconds to turn off Laptop
    after "halt" command.

Transfer the system from ACPI to Legacy mode if RB_HALT is set.
2009-02-26 13:56:46 +00:00
yamt
4b64c2cb3d - rewrite x86 nmi dispatcher so that establish and disesablish are safe
on a running system.
- adapt existing users of the api.  (elan)
- adapt tprof_pmi driver to use the api.
2009-02-24 06:03:54 +00:00
rmind
f7d3fa20ef Add ucas (CAS for user-space address) support for i386 and amd64.
API provides ucas_int() and ucas_ptr() for now.

Reviewed by <ad>.
2009-02-23 20:27:59 +00:00
jmcneill
e56c8e7c79 Make SMBIOS rev. message use aprint_debug (matches i386) 2009-02-17 12:23:33 +00:00
jmcneill
a0e45b868c Just like i386 cpu_startup, for console drivers that require uvm and pmap
to be initialized, call consinit for a third time here.
2009-02-17 01:39:25 +00:00
cegger
914a0b8bf0 nuke unused global variable 2009-02-17 00:09:50 +00:00
jmcneill
77fe169e3d Add and enable genfb(4) 2009-02-16 22:41:32 +00:00
cube
df0059e2e8 Don't set version deep in the source tree if it's older than the one in
conf/files.
2009-02-14 20:22:59 +00:00
apb
0cc72e51ac Use "defopt MODULAR" in sys/conf/files, and #include "opt_modular.h"
in all kernel sources that use the MODULAR option.
Proposed in tech-kern on 18 Jan 2009.
2009-02-13 22:41:00 +00:00
bouyer
24584a19d8 Add commented out PCI pass-through support:
#xpci* at xenbus ?                      #Xen3 PCI front end driver
#pci* at xpci ?
2009-02-13 21:18:43 +00:00
bouyer
40dab4ba52 Prepare for PCI frontend support in Xen3 domUs:
call x86_bus_space_init() and x86_bus_space_mallocok() if we have ISA or PCI
  devices configured; not only for non-Xen or dom0 Xen
On Xen, always call PHYSDEVOP_SET_IOPL on context switch
on amd64, also call PHYSDEVOP_SET_IOPL from x86_64_proc0_tss_ldt_init()
2009-02-13 20:42:24 +00:00
jym
92ae85d18e Changes to MEMORY_RBFLAGS option:
- renamed to MEMORY_DISK_RBFLAGS to better fit the rest of the
MEMORY_DISK options(4)
- change default value to RB_AUTOBOOT instead of RB_SINGLE, and adapt
the config(5) files accordingly
- document this option inside options(4)

See also http://mail-index.netbsd.org/tech-kern/2008/12/25/msg003924.html

Reviewed by abs@ in private mail.
2009-02-06 18:50:26 +00:00
ad
12cbb1b52b Enable BUFQ_PRIOCSCAN by default. 2009-01-29 21:48:13 +00:00
joerg
e8d52a0a38 Match mem.c's extern for __data_start. 2009-01-29 14:22:09 +00:00
joerg
ae7be29c97 x86/pmap.c declares vmmap as void *, match. 2009-01-29 14:20:50 +00:00
joerg
5f5aa3e6ea Match declaration of trap_type in trap.c. 2009-01-29 13:52:20 +00:00
christos
e5b8d3235c remove extra variable 2009-01-27 22:00:12 +00:00
christos
decf940784 factor out common reset code. 2009-01-27 21:59:24 +00:00
ad
454c144aec Make previous compile. 2009-01-27 21:13:57 +00:00
christos
55113bafff Attempt to force resets using two more methods:
1. Reset Control register at I/O port 0xcf9
2. Fast A20 and Init register at I/O port 0x92

Requested by ad@
2009-01-27 16:13:13 +00:00
cegger
969541a563 buildfix: re-adapt to major()/minor() returning a 32bit value. 2009-01-21 09:43:40 +00:00
joerg
99bea28aa2 Fix typo in comment. 2009-01-15 19:03:31 +00:00