Commit Graph

6706 Commits

Author SHA1 Message Date
mycroft f85e332440 Use pmap_kenter_pa() to map pages to dump, not pmap_enter(), so that it's more
resistant to VM lossage.
2004-07-22 15:12:46 +00:00
tron ad1499aa47 Enable ehci(4) by default. 2004-07-19 14:23:59 +00:00
christos 935764b9b1 catch up with darwin new functions 2004-07-16 04:56:30 +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
atatat 1ce3b064a0 Make uudecode into a tool that can be used to build a kernel and redo
the athhal-elf.o handling to take advantage of it.  This means that
bsd.files.mk is no longer included by Makefile.i386 so CFLAGS won't be
duplicated.
2004-07-15 03:35:20 +00:00
msaitoh 38e0720545 Add Dothan 2004-07-11 15:22:05 +00:00
nathanw 7e753fcf97 cyrix6x86_cpu_setup: Save and restore the original value of CCR3
across the "coma bug" workaround to avoid clearing the MAPEN bit if it
was originally set by firmware. This appears necessary for proper
functioning of SMM on Geode CPUs, and thus for proper emulation (ugh)
of access to certain PCI configuration registers or VGA register
spaces. With this change, VGA and soundblaster emulation work on Geode
NX1 systems.

This was also the underlying problem that led to the introduction of
the PCI_QUIRK_SKIP_FUNCn quirks in pci_quirks.c, which are no longer
necessary (and counterproductive if you want to use VGA or a
Geode-specific audio driver). See the thread "pci probe" on port-i386
in August 2003 (The Soekris 4801, apparantly the most popular
Geode-based NetBSD box, has neither VGA nor audio, which may explain
why this wasn't noticed at the time).
2004-07-10 21:25:53 +00:00
cube 120187b856 Add commented out EST_FREQ_USERWRITE to GENERIC_LAPTOP too. 2004-07-10 18:52:30 +00:00
cube ca1f4e2485 Add an option to allow any user to write to machdep.est.frequency.target,
which is very handy on a laptop to control EST through another program that
you don't necessarily want to run as root (in my case, gkrellm).

The option's name is EST_FREQ_USERWRITE, and is disabled by default.
2004-07-10 18:51:01 +00:00
bouyer 8e03c54653 Add geodeide(4), a driver for the AMD Geode CS5530A IDE controller.
Tested by Ian Zagorskih (ianzag at megasignal.com).
2004-07-09 18:38:37 +00:00
drochner af0dfbe584 don't need md timing functions for joystick anymore 2004-07-08 22:07:47 +00:00
christos daf173e8a5 follow suit and fix copyright attribution. 2004-07-08 11:46:55 +00:00
christos 663957c46f make this compile again. 2004-07-07 23:28:28 +00:00
mycroft d539198300 Minor adjustment so that it is safe for an interrupt handler to unregister
itself.  Fixes a potential problem with PCMCIA IRQ probing.  See PR 9928.
2004-07-07 01:03:57 +00:00
mycroft c8a3263cbf Remove XSERVER and XSERVER_DDB from all config files. wscons does not use
these, and pccons is rapidly heading for the guillotine.
2004-07-06 22:53:36 +00:00
mycroft 1e3cb7e7ec Back out part of the changes in rev 1.86. Remove npxdna_notset(), and instead
have the DNA trap handler point to npxdna_empty() by default.  This way, if
there are no npx devices found and MATH_EMULATE is not configured, we go back
to the old behavior of issuing a SIGKILL and printing:
pid XXX killed due to lack of floating point
rather than panicking.
2004-07-06 01:30:08 +00:00
abs 1a06ef7694 Remove accidently added UMASS_DEBUG. Thanks to kimmo for spotting. 2004-07-05 22:30:38 +00:00
mycroft 6ad727416a Attempt to handle unknown ServerWorks chips, although I wouldn't bet on it
working cleanly.
2004-07-05 19:15:05 +00:00
yamt 201fdee01b for uniprocessor, splvm() is enough to protect tlb flush queue. 2004-07-05 11:19:46 +00:00
christos 7c328d9858 add a skeleton that defines the symbols we need; no implementation 2004-07-04 15:24:30 +00:00
christos a3eca3bd01 Add USRSTACK definitions 2004-07-04 15:22:29 +00:00
christos 0122ef6740 add darwin_commpage_machdep.S [does nothing for now, and the name is too long] 2004-07-04 15:22:03 +00:00
tron 16e9e90a52 Add re(4). There are laptops with an onboard Realtek 8169 Gigabit LAN. 2004-07-04 13:16:56 +00:00
mycroft 2b9d3e39a0 Fix confusion between index numbers in one table and node numbers in another
table, that was causing PNPBIOS to fail on some machines.  Should fix PR 18610.
2004-07-04 06:18:26 +00:00
mycroft 58a7151020 Update Serverworks chip names, and add a few more. 2004-07-04 05:53:55 +00:00
mycroft 88bac700e0 Be more careful about what ServerWorks devices we attempt to map PCI buses
behind.
This should address PR 21458 and PR 25670.
2004-07-04 04:55:18 +00:00
mycroft cd5dfd5c5c Rebuild. This primarily updates NGDT. 2004-07-04 03:35:01 +00:00
mycroft 15eb49718a s/PAGE_SIZE/NBPG/ to make this compile again. 2004-07-04 03:21:53 +00:00
mycroft 66760f9d8c Change MAXDRV to 0x8f, to fix El Torito booting problems on some machines.
See PR 22647.
2004-07-04 00:38:51 +00:00
mycroft 5f1cbe539c If apm_set_powstate() fails, make sure we run apm_resume() so that run any
powerhooks we have.  From PR 13671 (but applied to both standby and suspend).
2004-07-03 22:29:13 +00:00
mycroft 6343f6f6ee Per PR 8120, put back the reloading of the IDT in cpu_reset(). (Presumably
this overrides some descriptor caching in the CPU.)
2004-07-03 21:02:09 +00:00
yamt eb3fe82f73 i8254_initclocks: fix an integer overflow problem in rev.1.83.
a patch provided by FUKAUMI Naoki.  PR/26152.
2004-07-03 18:24:37 +00:00
drochner 12abfacf0b just include <sys/joystick.h> 2004-07-02 17:15:10 +00:00
yamt 38cdafcad1 {i8254,lapic}_initclocks: try to be more precise using fixtick. 2004-07-01 13:00:39 +00:00
itojun b140dfa763 s/options\t\t/options \t/. (whether UMASS_DEBUG is appropriate for everyone's
GENERIC is a different issue.  i'm not sure)
2004-06-29 04:51:29 +00:00
bouyer 21e9a36edc Add options P1003_1B_SEMAPHORE
to all GENERIC-like kernel config files where SYSV* options were already
present (commented out if the SYSV* options are commented out).
Fix lib/25897 and lib/25898.
2004-06-28 21:07:47 +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
martin f142712a67 Add mtd (Myson MTD803 3-in-1 Ethernet) driver. 2004-06-27 16:47:06 +00:00
dsl 5cf67adbc4 Change interface between bootxx.S and boot1() - always linked together.
This allows boot1() to change the sector number (of the boot partition)
that bootxx.S passes through to boot2().
This means that boot2() will find the correct partition when boot1()
reads /boot from the 'a' partition instead of the mbr boot partition.
This all happens when you update a system that used a small 'wd0h' partition
to boot a raid1 set to the new bootcode.  Deleting /boot from the 'wd0h'
partition will make the new bootcode find /boot and the root filesystem
inside the raid set.
2004-06-27 15:37:11 +00:00
abs bd8eb3b5ed Add (commented out) ALTQ options to all GENERIC-like files 2004-06-26 07:32:05 +00:00
yamt 9a1474eb02 remove a prototype for a function which doesn't exist. (npxdna) 2004-06-23 12:24:01 +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
jmc 84fafa3db5 Ignore errors on some rm -rf's for platforms that aren't quite
POSIX compliant
and return errors on r/o source (FreeBSD) for -rf. Fixes PR#25022
2004-06-21 18:20:08 +00:00
thorpej 82c52d4891 Add COMPAT_20. 2004-06-20 03:24:04 +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
christos 0399e839cf Add pseudo-device ptm on all the generic flavored kernels. 2004-06-16 15:07:39 +00:00
tshiozak 0d08b7cade Make sure to restore curproc's PTD before calling AcpiEnterSleepState().
Leaving the PTD inconsistent may crash the kernel.
2004-06-14 18:09:35 +00:00
lukem b88c3a1555 Use "options<SPACE><TAB>".
(`egrep -l '(^|[^e])options<TAB>'` is your friend...)
2004-06-14 01:27:59 +00:00
tshiozak 1b7c9e7222 - make sure to use proc0's PTD for the ACPI wakecode.
- add re-initialization for npx while resuming.
2004-06-11 19:45:55 +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 d29c4e62c3 Fix typo:
ACPI = Advanced *Configuration* and Power Interface
2004-06-08 12:46:11 +00:00
kochi 7e55bddc3a Add ACPI_DISABLE_ON_POWEROFF option. 2004-06-07 15:33:52 +00:00
christos ff64927ee9 Don't include the rnd device; it makes us too big. 2004-06-06 07:04:27 +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
augustss df613458d1 Use SPC-TAB after the word "options". 2004-06-01 16:29:36 +00:00
christos 5369712097 PR/19925: David Ferlier: Add scrolling support to wscons 2004-05-28 21:44:51 +00:00
christos bf3905ed0c Add ptm device. 2004-05-27 02:57:24 +00:00
thorpej 2ecdd552dc Add the notion of "shadow registers" to the wdc driver. These shadow
registers are registers that overlap with others on many controllers, but
which may actually be distinct on some controllers.  Right now, the two
shadows are:

- wd_status (usually overlaps wd_command)
- wd_features (usually overlaps wd_error)

Add a new helper function, wdc_init_shadow_regs(), used to initialize
the shadow register handles on controllers where they do actually overlap.

Partially from Jordan Rhody @ Wasabi Systems, Inc.
2004-05-25 20:42:40 +00:00
tsarna f7fae574cc add uep driver 2004-05-24 23:50:11 +00:00
yamt 9080a4b746 instead of blindly set IF in MCOUNT_EXIT,
save eflags in MCOUNT_ENTER and restore it.
2004-05-24 14:01:10 +00:00
christos 0b36703edc put back SIZEOF_HEADERS now that bfd is fixed; you will need to recompile
libbfd...
2004-05-23 18:09:44 +00:00
christos d70a6522f9 Use 1024 instead of SIZEOF_HEADERS, so that we can include a note section. 2004-05-22 22:06:54 +00:00
kleink a8f9b18e52 Bring back {u,}int_fast8_t back to 8 bits, as I had misunderstood Charles. 2004-05-22 14:16:59 +00:00
grant e26fd850ec add `scsibus* at umass?' so usb mass storage devices which attach to
sd@scsibus can be used out of the box.

whitespace tweak for wd* at umass?
2004-05-22 03:16:26 +00:00
kleink dd80e25e65 Change {u,}int_fast{8,16}_t to 32-bit types, as the previous minimum-
width implementation was a rather poor choice.  Per discussion with
Charles Hannum.

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).  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-21 22:52:06 +00:00
atatat a1296cdfe4 Whitespace nits 2004-05-21 03:30:40 +00:00
yamt 8956861179 curcpu: fix a typo. (cpuinfo -> cpu_info)
no functional difference.
2004-05-16 12:32:53 +00:00
yamt 66b2ec5ff7 fix a compile error in the case DDB && !GPROF.
the problem pointed by Jaka Jejcic on current-users@ and
by several others privately.
2004-05-13 20:30:39 +00:00
yamt d94ff45112 call mcount in Xspllower. 2004-05-13 12:27:38 +00:00
yamt ed15986b95 pmap_load: assert that being able to take ipis. 2004-05-13 12:24:05 +00:00
yamt a87499d4ea witch_return: call Xspllower only when there're pending interrupts. 2004-05-13 12:15:01 +00:00
yamt 6b9fd4bdc5 npxsave_lwp: issue pause in a busy loop. 2004-05-13 12:13:20 +00:00
yamt d55112e112 add a comment to note that INTRFASTEXIT and trap() should be in sync. 2004-05-12 20:03:06 +00:00
yamt 5dac5f5d40 add a comment on mp_attrs. 2004-05-12 09:11:03 +00:00
wiz 8785cb8fb1 Add commented out entries for ioat* and nsclpcsio*;
from Sergey Svishchev in private mail.
2004-05-11 23:07:35 +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
dsl 17bfe85dd3 Make mbr_bootsel boot active partition if/when no menu items are output.
Stops users sitting in front of a system that is waiting for a keypress.
Just don't ask how I added more functionality AND got an extra 7 free bytes!
2004-05-08 21:18:22 +00:00
lukem 191597b042 move machdep.est.cpu_brand to machdep.cpu_brand 2004-05-03 16:38:28 +00:00
kochi b616cd6b52 don't use large stuff on stack.
(char devinfo[256] -> char *devinfo)
2004-05-03 07:08:46 +00:00
kochi beb4a7fe16 specify static where appropriate. 2004-05-01 12:03:27 +00:00
kochi 32cdfb5cac Enhance debug output for ICHx (with PIIX_DEBUG)
from Masanori Kanaoka
2004-05-01 06:35:10 +00:00
gendalia ec36bf86ae Uncomment 'wd* at umass?' in GENERIC, add to GENERIC_LAPTOP.
supports the ISD's ATA protocol over Bulk-Only, used with the Archos studio
and Archos Jukebox products, among others.
2004-04-30 17:41:19 +00:00
fredb 2c8270471f - - "options" should be followed by <SPACE><TAB>.
- - restore "options COMPAT_20", no doubt commented out by mistake.
2004-04-30 15:55:10 +00:00
christos b657953b30 Add and document PCIBIOS_LIBRETTO_FIXUP 2004-04-30 02:47:16 +00:00
christos 4eac397f2f Add code to deal with the losing Libretto L2/L3 pcibios. From Masanori
Kanaoka. I've been sitting on this code for 3 years, and have not done
anything better with it. It is ugly, it needs to be handled better, but
it is better to have it #ifdef'ed out rather than nothing.
2004-04-30 02:45:37 +00:00
christos f117f546d1 Deal with edge versus level interrupts properly. From Masanori Kanaoka. 2004-04-30 02:44:03 +00:00
lukem 59fdcaadf2 add ENHANCED_SPEEDSTEP 2004-04-30 02:08:17 +00:00
lukem 2df026b026 Integrate support for Enhanced SpeedStep Technology (est) that
Michael Eriksson posted to port-i386 on 20031102, with various
modifications by me to work in the new sysctl(9) framework.

The code is enabled with 'options ENHANCED_SPEEDSTEP', and if
the CPU supports EST the following sysctl(8) nodes appear
(with the values that a Dell Inspiron 8600 + WUXGA with a
1.4GHz Pentium M CPU supports):
	machdep.est.cpu_brand = Intel(R) Pentium(R) M processor 1400MHz
	machdep.est.frequency.target = 1400
	machdep.est.frequency.current = 1400
	machdep.est.frequency.available = 1400 1200 1000 800 600

If EST support isn't available, the "machdep.est" sysctl sub-MIB
is not created.

Once we have a more general "CPU frequency" control API we can
migrate this code to using that.

Thanks to Michael Erikkson for providing this code!
2004-04-30 02:05:42 +00:00
lukem 3da1e3206a Add driver for Enhanced SpeedStep (in Pentium M processors),
written by Michael Eriksson and posted to port-i386 on 20031102.
(This is the driver "as is" - I'll commit the code to integrate it
into -current separately)
2004-04-30 01:56:12 +00:00
gendalia 6c64abac77 add raidframe and raid autoconfig support to the INSTALL kernel. 2004-04-29 20:42:39 +00:00
minoura 3a9e37fe76 Comment out ichlpcib.
There are at least 2 reports that it freezes upon startup.
http://mail-index.netbsd.org/current-users/2004/04/19/0016.html
2004-04-29 11:54:24 +00:00
uwe 33c262357e Adapt to pci_devinfo signature change. 2004-04-24 15:09:54 +00:00
minoura d75fa2749f Move misplaced debug code.
This should make it compile w/o pcppi and w/ CLOCKDEBUG.
2004-04-24 13:38:36 +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
dsl 5d3e088ee0 Put the 'mbr has bootselect table' marker into all versions of the mbr code.
Having the table in the 'standard' mbr allows fdisk to write in bootsel
menu items and only ask about updating the mbr code before exit.
Sysinst validates that the mbr code contains the bootselect table for
all the mbr code variants it reads - because it might want to write the table
and doesn't really want to make the validation dependant on what it is
going to do later.
Fixes install/25235, but sysinst needs some changes (like reporting the
failure to write the mbr) before the pr itself is closed.
2004-04-23 06:21:21 +00:00
itojun 8bcb745d7c sprintf -> snprintf 2004-04-22 00:31:00 +00:00
christos 6bd1d6d4db Replace the statfs() family of system calls with statvfs().
Retain binary compatibility.
2004-04-21 01:05:31 +00:00
yamt c13fd66a5d syscall_fancy/plain: add assertions to detect PHOLD leaks. 2004-04-20 12:00:02 +00:00
yamt 88005c19af add '.L' prefixes to local labels. 2004-04-20 11:59:20 +00:00
fvdl 07fd2b039b Adapt for new aapic.c location. 2004-04-18 18:36:56 +00:00
he a1182cdd25 We need to also clean out athhal-elf-o, so that "make clean; make"
after an initial "make" will also (re)build athhal-elf.o.
2004-04-15 15:02:17 +00:00
mrg 47a36b2bdc when we have a P4 or a MP system, don't enable performance monitoring.
this fixes PR#25014.  i386 GENERIC can re-enable PERFCTRS by default now
(it was disabled with x86 SMP support was commited to the trunk.)

XXX:  should add P4 support
XXX:  should add MP support
2004-04-15 13:56:32 +00:00
yamt faedfe8895 - keep cr3 register and its copy in TSS synchronized.
otherwise an interrupt vector using a task gate (ie. ddbipi) messes it up.
- defer LDTR loading as well as cr3.
- tweak comments to make three copies of switching code more synchronized.
2004-04-12 13:17:46 +00:00
kochi 193c08b383 Clean up memory allocated during autoconfiguration 2004-04-11 10:36:35 +00:00
kochi b547a6d28f change acpi_resource_parse API to support _PRS parsing as well as _CRS 2004-04-11 08:36:19 +00:00
kochi e80850866a de __P, ANSIfy PCIBIOS related files. 2004-04-11 06:00:25 +00:00
kochi db7198d645 whitespace nit 2004-04-10 11:48:10 +00:00
augustss 9224fd7b0a Put ichlpcib in alphabetical order. 2004-04-07 13:13:59 +00:00
wiz 8ad72c592f Revert previous: Linux' procfs spells "CPU" "cpu", so mimic it.
Closes PR 25076 by salo.
2004-04-06 20:37:07 +00:00
mrg 1739cf2504 - fix i386_intel_brand[]: it was missing a empty reserved entry at 0xD
causing Mobile Pentium 4 to be shown as a Mobile Celeron.
- fix intel_family6_name() for brand=0xB && signature >= 0xF13
- fix a potential out-of-bounds array reference
2004-04-05 02:09:41 +00:00
kochi ee2683e797 Support for PIRQ[E-H], found in recent intel south bridges
(ICH2 and later), which fixes PR/23700.
The changes are from Hiroyuki Bessho and Masanori Kanaoka in PR/23700
with a little modification of interrupt router lookup from mine.
2004-04-04 16:06:09 +00:00
kochi 41ea3c2a77 add one more PCI ID (ICH4-M). 2004-04-04 15:16:38 +00:00
groo f2d334068a Let's try that again... one comes from .CURDIR, another set of files
comes from .OBJDIR.
2004-04-03 18:18:21 +00:00
groo 291203c667 Don't cd ${.CURDIR}, it's not where the uudecoded objects are. 2004-04-03 17:45:19 +00:00
lukem e7b4b99d58 Convert to using UUDECODE_FILES instead of using -kb in the repository. 2004-04-02 08:54:04 +00:00
jwise bffc53d606 Fix grammar in error message. 2004-03-29 15:57:28 +00:00
drochner c83eb997b8 nothing cares about __HAVE_SIGINFO anymore, so nuke it 2004-03-26 21:39:57 +00:00
drochner ae94c80224 fix references to the syscall formerly known as SYS___sigreturn14 2004-03-26 19:05:33 +00:00
minoura a3a2a1ebcf Print better names for Pentium4-class processors (Xeon, Celeron, etc). 2004-03-26 13:57:44 +00:00
jmc 77e0ba6695 Convert athhal-elf.o to a .uue and add appropriate make hooks to use it 2004-03-25 23:32:10 +00:00
wiz f1b19ce1db Backout previous -- this is not enough, config needs to be taught
how to reach partitions above h. Noted by Simon Burge, related to
PR 24905.
2004-03-25 15:26:35 +00:00
wiz 3afe1a1d87 Define maxpartitions to the same value as MAXPARTITIONS in disklabel.h.
Addresses PR 24905 by Simon Burge.
2004-03-25 12:38:49 +00:00
drochner 566efeb685 remove license clauses 3 and 4 from my cpoyright notices 2004-03-24 16:46:27 +00:00
drochner 091c877e12 remove license clauses 3 and 4 from my cpoyright notices 2004-03-24 16:34:29 +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
kanaoka 5886bca6f0 Make it compile (int -> ACPI_INTEGER) 2004-03-24 11:26:46 +00:00
lukem 455da8e60b Move mbr_bootsel from offset 404 to offset 400 in struct mbr_sector to
leave 4 bytes for the Windows NT Drive Serial Number (DSN) at 440-443
(as mbr_sector.mbr_dsn).

Ensure that all the MBR & PBR code reserves space for mbr_sector.mbr_dsn.

Leave the bootsel magic number at 444-445 as mbr_sector.mbr_bootsel_magic
(instead of mbr_sector.mbr_bootsel.mbrbs_magic), but use 0xb5e1 (MBR_BS_MAGIC)
instead of 0xaa55 (MBR_MAGIC) to indicate that this change has occurred.

Rework MBR_BS_NEWMBR to mean "mbr_bootsel has moved to 400".

Modify fdisk(8) to automatically relocate the mbr_bootsel from 404 to 400
if mbr_bootsel_magic is the old value (0xaa55), and unset MBR_BS_NEWMBR
to flag that new mbr_bootsel code must be used if updating the MBR.


These changes fixes a problem where Windows 2000 or Windows XP would corrupt
the last 3 bytes + NUL of MBR partition 3's bootsel name if the bootsel name
was 5 characters long, replacing bytes 6-9 with the DSN.
Also, by explicitly reserving the space for the DSN we prevent problems in the
future if non bootsel MBR or PBR code had other information at bytes 440-443.
2004-03-22 07:11:00 +00:00
kim 92703eeedb AMD CPUID 0x6a0 is an Athlon XP processor model 10, revision A2.
http://www.amd.com/us-en/assets/content_type/white_papers_and_tech_docs/27532.pdf
2004-03-21 17:59:44 +00:00
junyoung 2ed9c2c7b7 ANSIfy. 2004-03-21 15:37:02 +00:00
simonb 84b7d801ac Only initialise ksi if we use it. 2004-03-21 10:56:24 +00:00
minoura 88f55c570c Fix typo. 2004-03-15 05:31:46 +00:00
minoura 17724e2968 Stop the timer explicitly before initialization.
Apparently certain BIOS requires this.  Noted by yamt.
2004-03-15 01:23:49 +00:00
minoura 10cb1fb645 Add ichlpcib. 2004-03-14 08:09:42 +00:00
minoura b332b550b9 Add Intel ICHn PCI-LPC bridge driver.
It is a pcib, but with sysmon watchdog support.
2004-03-14 08:04:38 +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
dsl ae7b924322 Translate ascii keycode to help those with azerty keyboard type straight. 2004-03-13 22:41:37 +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
yamt aad9f63765 before resuming from failure during return to user mode,
- clear PSL_NT.  it can be set by userland because setting it
  isn't a privileged operation.
  (cf. DSA-336-1, CVE-2002-0429)
- set PSL_I.  otherwise, if SIGSEGV is ignored, we'll
  end up to infinite loop, generating the same traps, with
  interrupts disabled.
2004-03-11 11:42:04 +00:00
yamt b62ef7b657 update trap(), resume_iret and friends to match with
the recent version of INTRFASTEXIT.
might be related to PR/24711.
2004-03-11 11:39:25 +00:00
junyoung 0f89803028 Drop trailing spaces. 2004-03-05 11:30:50 +00:00
dsl 44eaa39982 Report errno value from boot1() - even though the standalone FS code
seems to translate everything into ENOENT.
2004-02-28 23:01:55 +00:00
dsl da7ffa3cbe Look for /boot in the 'a' partition (from the label in the mbr partition)
if it can't be found in a filesystem (or raid set) at the start of the
mbr partition.
2004-02-28 22:32:23 +00:00
dbj 5b782a2183 allow err of IREENT_MAGIC when looking for interrupt frames 2004-02-28 20:30:58 +00:00
dbj 0dcc30f1ff fix bug in tracing current process by explicit pid 2004-02-28 02:58:35 +00:00
dbj ba0f8cbecc fix an uninitialized variable problem that prevented t/u from working.
this also helps some when no symbols are available
2004-02-28 01:00:30 +00:00
dbj d3e00c7d64 fix backtracing through interrupt frames and system call frames 2004-02-27 22:52:03 +00:00
enami ac317107c7 Backout (part of) rev. 1.187, since the control no longer fall through. 2004-02-27 21:37:48 +00:00
jdolecek b1d292e1be add yet another ServerWorks variant
from PR port-i386/24570 by Ray Phillips
2004-02-27 09:01:26 +00:00
perry 39c2ad666c fix another whitespace nit 2004-02-25 18:56:26 +00:00
perry c5e487ca2c juggle tabs and spaces so comments don't nuke line lengths as badly 2004-02-25 18:50:01 +00:00
wiz 516a72484d Spell through with two hs. From Peter Postma. 2004-02-24 15:24:35 +00:00
junyoung 2402a07435 - Locate comment in right place.
- Fix wrt protection against multiple inclusion.
2004-02-21 04:31:40 +00:00
yamt d749a2d0b4 defer pmap switching until it's really needed
to avoid frequent loading of cr3 register, which involves tlb flush.

with some fixes/improvements from Stephan Uphoff and Bang Jun-Young.
2004-02-20 17:35:01 +00:00
drochner 893de0a21e signal SIGSEGV/SEGV_ACCERR if non-executable stack is jumped to 2004-02-19 17:02:44 +00:00
uebayasi 5d41e06074 Update some URLs. 2004-02-19 12:23:47 +00:00
wiz bb3980ab7a Remove last traces of DUMMY_NOPS option that was removed some
time ago.
From Jeff Rizzo in PR 24442.
2004-02-16 17:11:26 +00:00
bjh21 5aca86918f Add a new MI attribute, pckbc_machdep_cnattach, and change pckbc_cnattach()
to only call pckbc_machdep_cnattach() if this is present.  This allows
pckbc_machdep_cnattach() to be omitted entirely on most ports, where it only
returns ENXIO anyway.

The devices with this attribute at the moment are pc(4) on i386 and bebox, and
pckbc on sparc, where pckbc_machdep_cnattach() mysteriously returns 0 rather
than ENXIO.
2004-02-14 14:33:28 +00:00
drochner dc30e923ea plug kernel lock leaks 2004-02-13 18:57:19 +00:00
wiz d20841bb64 Uppercase CPU, plural is CPUs. 2004-02-13 11:36:08 +00:00
yamt 03e3b6a13c pmap_create: initialize pm_cpus. 2004-02-11 12:15:12 +00:00
drochner 5ab60443ab please test-compile before committing 2004-02-06 10:28:03 +00:00
junyoung bf274fed3f ANSIfy & KNF. 2004-02-06 08:18:39 +00:00
jdolecek 5ecaa7ecee add dependency on isadma for atppc attachments
add atppc_isadma.c for atppc@isapnp and atppc@ofisa, too
2004-01-31 13:59:20 +00:00
dbj ce701fa38b fix for backtracing through trap frames from Christian Limpach 2004-01-29 04:58:50 +00:00
yamt 2a93afdfd5 rename i386 mdlwp flags from MDP_ to MDL_
to avoid confusion with mdproc flags which also have MDP_ prefixes.
2004-01-28 10:48:55 +00:00
yamt 20236bf218 gdt_alloc_cpu: use unmanaged mappings as gdt_init and gdt_grow. 2004-01-28 10:43:50 +00:00
jdolecek 41f3d22517 add PNPBIOS attachment foor atppc(4) driver; compiles, otherwise untested 2004-01-28 09:09:14 +00:00
scw 43cdf5ffb6 __splbarrier() is deprecated in favour of the MI __insn_barrier(). 2004-01-26 19:43:25 +00:00
jdolecek e702ddcd47 include SMBFS support 2004-01-23 13:43:46 +00:00
jonathan e83c4e9b7e An i386 config file that includes GENERIC and adds ``options FASSDT_IPSEC''.
Intended as a tinderbox/regression-test aid, to prevent skew or
other bitrot between KAME IPsec and fast-ipsec.
2004-01-23 02:16:38 +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
perry c70305f794 Make the warning on NEW_BUFQ_STRATEGY much milder -- I've upgraded it
to "Likely stable". I'm not going to make it the default unilaterally
but I really think it should be.
2004-01-16 17:02:05 +00:00
dyoung dee4867ed0 Compute tags for `*.[sS]' instead of `*.s', only. 2004-01-16 10:08:42 +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
yamt 6125e101f7 remove a duplicated definition of MDP_USEDFPU. 2004-01-14 11:29:40 +00:00
cube 063960f68a Make it aware of the new ata configuration syntax. 2004-01-11 12:55:19 +00:00
perry 3682e63056 nuke trailing spaces. 2004-01-09 18:31:25 +00:00
chuck e5aceb8c63 the IBM thinkpad T40p's built-in wireless ath0 interface attaches
to pci, so add an entry for it so that the GENERIC_LAPTOP kernel
can use it.
2004-01-06 16:24:14 +00:00
jdolecek c3bb9cd5a4 Process and lwp exit path always executes lwp_exit2() now and cpu_exit()
is empty besides calling switch_exit(). So, rename switch_exit() to
cpu_exit() and modify the routine to call lwp_exit2() direct.
This saves couple cycles on the exit path.
2004-01-04 11:44:52 +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
thorpej a963286f8d More wdc_channel structure member namespace cleanup:
- channel -> ch_channel
- wdc -> ch_wdc
2004-01-03 22:56:52 +00:00
thorpej 5bd80d8373 Rename "struct channel_softc" to "struct wdc_channel". 2004-01-03 01:50:52 +00:00
thorpej 77eb53d196 Update for opencrypto changes. 2004-01-01 18:46:14 +00:00
thorpej 527c829fa0 Rename:
- wdc_xfer to ata_xfer
- channel_queue to ata_queue
and move them to <dev/ata/atavar.h> so they can be used by non-wdc ATA
controllers.  Clean up the member names of these structures while at it.
2004-01-01 17:18:53 +00:00
jonathan 01c51dab61 Split opencrypto configuration into an attribute, usable by inkernel
clients, and a pseudo-device for userspace access.

The attribute is named `opencrypto'. The pseudo-device is renamed to
"crypto", which has a dependency on "opencrypto". The sys/conf/majors
entry and pseudo-device attach entrypoint are updated to match the
new pseudo-device name.

Fast IPsec (sys/netipsec/files.ipsec) now lists a dependency on the
"opencrypto" attribute.  Drivers for crypto accelerators (ubsec,
hifn775x) also pull in opencrypto, as providers of opencrypto transforms.
2003-12-31 16:44:26 +00:00
augustss 044205cf85 Alphabetize IDE controllers 2003-12-30 18:09:50 +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
yamt 8a7df6a14b (MULTIPROCESSOR version of) need_resched:
- nothing needs to be done if ci_want_resched is already set.
- if the cpu isn't running any lwp, send a no-op ipi to it
  so that it can resume immediately from halting in idle loop
  without having to wait until the next clock tick.
some advices from Stephan Uphoff.
2003-12-30 03:57:19 +00:00
yamt 26db734594 fixes and optimizations from Stephan Uphoff.
- pmap_enter: zap PTE and read attributes atomically to
  eliminate a race window which could cause lost of attributes.
- reduce number of TLB shootdown by using some assumptions
  about PTE handling.

for more details, see "SMP improvements for pmap" thread on port-i386@
around May 2003.
2003-12-30 03:55:01 +00:00
yamt 4cd02fe3d9 g/c unused x86_ipisend. 2003-12-30 03:52:01 +00:00
yamt 1d4f93e85b postpone freeing PTPs until TLBs are flushed
to avoid loading invalid TLB entries.  from Stephan Uphoff.

for more details,
see "i386 pmap bug" thread on port-i386@ around Feb, 2003.
2003-12-26 11:50:51 +00:00
jmc 0fe36533f0 Wrap some areas with #ifndef _LOCORE so assembly files can pick up some defs
from here. Needed for bioscall fixes in PR#14946
2003-12-25 21:03:55 +00:00
jmc f84b0cd795 Partial fix for PR#14946. Make sure x86 symlinks exist also 2003-12-25 21:02:58 +00:00
kochi 71ef8c54d3 add ACPICA_PEDANTIC option. 2003-12-23 10:11:42 +00:00
dsl 4bf8ba6f30 Fix problems booting disks with extended partition from grub (and other
non-netbsd mbr code) - thanks to Joe Thiemann for finding this...
2003-12-21 20:56:40 +00:00
thorpej 54da81c66c A kernel configuration file suitable for Connectix Virtual PC 6. 2003-12-18 17:08:35 +00:00
tls c58ee50077 Add "sk" driver for SysKonnect/Marvell GigE cards. 2003-12-17 09:18:45 +00:00
jdolecek e1a0411746 print complete contents of the second feature byte; this also fixes
printing of DMA32 bit
2003-12-15 08:38:01 +00:00
dyoung 10d1fa6e70 Add ath(4) for Atheros 802.11a/b/g cards. 2003-12-14 09:54:01 +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
thorpej 523e3bb618 I haven't had this laptop for a long time now. 2003-12-13 22:48:02 +00:00
nathanw d7a0075027 Trap 0x8 (T_DOUBLEFLT) and 0x11 (T_ALIGNFLT) should be TRAP, not
ZTRAP; while the error code is always 0, the processor indeed pushes
the 0 on the stack, according to table 5-1 in the IA32 SPG.
2003-12-12 20:17:53 +00:00
drochner bfae4c94ef if the code segment is not enlarged, return 0 in pmap_exec_fixup
so that the trap is not retried
(fixes cases where a program traps for good reasons)
2003-12-10 18:13:32 +00:00
drochner e74e4d19cb Just checking a global marker (pm_hiexec) for the highest executable
address currently in effect does not always work: There might be more
instances of the code segment selector in other threads, on other CPUs
and in *jmp_bufs.
So always check whether the CS needs updating, if it is not already
set to the "BIG" value.
This code needs more cleanup, this is considered a stopgap fix only.
2003-12-10 13:59:48 +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
dsl b31c4f649a Fix speling mistake in commennt. 2003-12-07 20:11:11 +00:00
jdolecek cbff3c76c3 fix IPRINTF() code to compile if the printf()s are enabled; also print
lwp pointers rather than proc pointer
2003-12-05 21:24:57 +00:00
christos f7e4c22afc Add a dummy darwin_slock 2003-12-05 20:34:45 +00:00
christos 6b364b0d7f Do the song and dance for the new indirect register mappings.
XXX: This driver's attach routine does not free resources on allocation
failure.
2003-12-05 19:00:07 +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
keihan 8476e6755a NetBSD.ORG -> NetBSD.org
Now all "NetBSD.ORG" are gone from src/sys.
2003-12-04 12:42:54 +00:00
christos f1a738c8b7 add stub file so that the kernel compiles. 2003-12-04 01:17:19 +00:00
christos f85ce17392 add stub function, so that kernel links 2003-12-02 04:53:11 +00:00
jdolecek 2f13a5654b throw in some default switch labels to pnpbios_update_dock_status(), so that
this compiles with PNPBIOSEVENTS option (such as with config DR-EVIL)
fixes kern/23564 by dheeraj reddy
2003-11-25 20:47:27 +00:00
abs 115bd31b73 Sync with GENERIC.MP (in particular add MPBIOS). Noted by Adam C. Migus 2003-11-21 09:29:11 +00:00
dsl 91f5ee90a4 Add .WAIT after first subdirectory to ensure we don't build the libraries
twice.
2003-11-20 16:16:41 +00:00
fvdl 56bf58a34b Add (commented out) and document NO_TSC_TIME. 2003-11-20 13:32:41 +00:00
fvdl a8ea4f26c8 If NO_TSC_TIME is defined, do not use the tsc microtime. This option can
be used to make time pass a little more smoothly when running under
VMware.
2003-11-20 13:30:29 +00:00
junyoung e58c050c81 Use predefined macro rather than hardcoded value. 2003-11-20 12:30:34 +00:00
jonathan 94d42f90db Add opencrypto and drivers for PCI cryptographic accelerators --
hifn (Hifn 7751), ubsec (Broadcom 582x) -- to i386 GENERIC kernel.
2003-11-18 23:07:37 +00:00
jonathan 9845fd1063 Add support for Broadcom and Intel gigabit lan devices on (i386)
laptop motherboards. From GENERIC_LAPTOP revisions 1.81->1.83.
2003-11-18 21:21:58 +00:00
jonathan f95098aec9 Add wm* and igphy*/makphy*, for laptops with Intel Pro/1000-family
gigabit Ethernet on the motherboard.
2003-11-18 21:15:46 +00:00
jonathan 64f5634e18 Add bge* and brgphy*, for laptops with Broadcom gigabit on motherboard. 2003-11-18 20:54:44 +00:00
tls 2a94b617f1 We can't use bf_cbc.S if I386_CPU is defined; the 80386 doesn't have
bswapl, and bf_cbc.S uses it.  Unfortunately, this means that GENERIC
will no longer use the asm code -- though it will still use the asm
for the basic Blowfish transform.  This won't slow down the KAME IPsec
(since it rolls its own CBC) but may slow down fast-ipsec in kernels
that have I386_CPU defined.
2003-11-16 12:02:15 +00:00
christos a0e314dfe4 add noop wrapper functions for i386 2003-11-13 01:44:36 +00:00
drochner 038b8b6573 Uhm - the last change broke everything but very simple setups.
(it only allowed to boot an nfs /netbsd automatically)
To make it work for people who can't tell the DHCP server to pass
the right kernel file to pxeboot, without losing flexibility for
people who can, do the following:
Use the filename given by the DHCP server if it contains a ":". A ":"
was already used to seperate filesystem and filename, so we don't
lose anything. Otoh, a path to pxeboot usually doesn't contain a ":",
so it should still work if we got the old pxeboot filename again.
2003-11-12 18:44:08 +00:00
dsl ec098b8a13 Double space for memory disk to 5MB, this costs (almost) nothing on the
install media and the kernels (and sysinst) will still run on a 16MB system.
(They haven't run on an 8MB system for a while - might affect 12MB though.)
The additional space in the root filesystem lets sysinst core dump properly!
2003-11-12 11:47:34 +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
tsutsui 112c91d583 Use #if defined(_KERNEL_OPT) to protect #include "opt_xxx.h"
from building LKM etc. Suggested by mrg.
2003-11-09 05:29:59 +00:00
dsl fcb78a6640 Remove depencency of vers.c on ${LIBLIST} - it messes up the depends and
I'm not sure why I added it now!
Default NWEVERSWHAT back to "BIOS Boot" - look better on boot banner page.
2003-11-08 00:02:02 +00:00
dsl a7e45c127a stand/lib/crt/rom is no more, no need for it in .PATH 2003-11-07 23:44:56 +00:00
dsl 80e537250b Make 'dependall' generate the dependencies 2003-11-07 23:39:27 +00:00
dsl 6074f35279 Change getextmem2 to return 'configured' values from cx/dx if ax/bx zero,
make absolutely high the top 16bits of returned values are zero.
Ralf's list says that some BIOS need %eax = 0x0000e820 in getmementry.
Add a few comments.
Might fix problems with memory size detection on some systems.
2003-11-07 11:34:28 +00:00
dsl a8af374602 Adjust location of 'extmem2' diagnostic print. 2003-11-07 11:30:39 +00:00
tron 0ad4493632 Update comment for wm(4) attachment because the driver supports more
than the Intel 82543 and 82544.
2003-11-05 07:51:12 +00:00
mycroft 06eb56a853 So, on other platforms we use the BOOTP/DHCP file name for the boot program
and use a default file name of "netbsd" for the kernel.  Do the same thing
here, as it hardly makes sense any other way.
2003-11-05 04:18:26 +00:00
fvdl 60a5dfd880 Add and enable igphy. 2003-11-04 23:38:41 +00:00
mycroft 94d9caaae4 Re-add ServerWorks IDE support, as "rccide". Note: this is untested, as I no
longer have a ServerWorks-based motherboard.
2003-11-04 16:57:57 +00:00
dsl 2ffbd2ab99 Remove p_nras from struct proc - use LIST_EMPTY(&p->p_raslist) instead.
Remove p_raslock and rename p_lwplock p_lock (one lock is enough).
Simplify window test when adding a ras and correct test on VM_MAXUSER_ADDRESS.
Avoid unpredictable branch in i386 locore.S
(pad fields left in struct proc to avoid kernel bump)
2003-11-04 10:33:15 +00:00
mycroft 4ac0e3e5c6 More cleanup:
* Use ACPI_FAILURE() and ACPI_SUCCESS().
* Output exception strings in a few more places.
2003-11-03 18:07:10 +00:00
mycroft b910c03a32 Clean up some messages:
* Use AcpiFormatException() in a bunch of places.
* acpi_resource_parse() already prints an error, so don't do it in the callers.
2003-11-03 17:54:39 +00:00
kochi 84795bd3fd * now the size of ACPI_DEVICE_INFO is variable:
it can now accomodate multiple _CIDs
  sizeof(ACPI_DEVICE_INFO) should not be used
* make ad_devinfo member in acpi_devnode a pointer
* implement acpi_match_hid() to simplify matching devices;
  _CIDs are also taken into account now as well as _HID
2003-11-03 06:03:47 +00:00
yamt c8d12c1c35 retire PG_ZERO zero-fill checks. uvm_pagefree now check it for us. 2003-11-03 04:02:13 +00:00
jdolecek ec23fd5f28 properly initialize local variable in pnp_debugdump() 2003-11-02 11:32:03 +00:00
yamt fe3e5aa0b8 as we know PTPs are zero-filled when being freed,
mark them PG_ZERO so that they'll be used to serve UVM_PGA_ZERO requests.
2003-11-01 15:21:02 +00:00
yamt e36739df67 use explicit "l" suffixes.
(xor -> xorl)
2003-11-01 15:14:27 +00:00
yamt f41e60e6a0 as there shouldn't be any mappings when pmap_destroy() is called,
assert there is no remaining PTPs at that point.
2003-11-01 09:07:11 +00:00
mycroft a4061d6dec Update for structure changes. 2003-10-31 21:49:39 +00:00
cl ef56cc40ab Reduce code duplication by adding mi_userret() in sys/userret.h
containing signal posting, kernel-exit handling and sa_upcall processing.

XXX the pc532, sparc, sparc64 and vax ports should have their
XXX userret() code rearranged to use this.
2003-10-31 16:44:34 +00:00
hannken ef301d7a07 Remove memset prototype. Already present in sys/lib/libsa/stand.h. 2003-10-31 10:49:25 +00:00
nisimura 51cdfee682 Added stpcide(4) driver for STMicroelectronics STPC IDE controllers. 2003-10-31 06:49:58 +00:00
simonb 6d85c5e0d5 Don't pass the (unused) return value args to the
trace_enter()/systrace_enter() functions.
2003-10-31 03:28:12 +00:00
fvdl 7d342b5852 * keep track of PCI buses that aren't known by firmware, but are found
by NetBSD
* use this info in in intr_find_mpmapping
* get rid of the last argument to intr_find_mpmapping, it was redundant
2003-10-30 21:19:54 +00:00
simonb b6abb6ab1d Remove some assigned-to but otherwise unused variables. 2003-10-30 01:58:17 +00:00
mycroft a246f3b7a5 Reorder slightly to eliminate bogus initializers. 2003-10-29 02:02:05 +00:00
mycroft 659649b149 The previous change was wrong. The variables were legitimately uninitialized.
This code was broken on 2002/10/22 by christos.
2003-10-28 23:10:02 +00:00
mycroft 6ad04f2a27 XXX: gcc 2003-10-28 23:04:26 +00:00
mycroft 3aae7144ea Eliminate bogus initializer. 2003-10-28 22:52:53 +00:00
yamt a059d6caf4 appease gcc "uninitialized" warning. 2003-10-28 14:49:53 +00:00
drochner 46e330c669 quell a gcc3 "uninitialized" warning by putting some more dead code
inside "#ifdef PNPBIOSEVENTS"
2003-10-28 11:17:14 +00:00
junyoung 68a06a8528 Fix indent level. 2003-10-28 04:59:18 +00:00
junyoung 2c4f6d0128 Nuke __P(). 2003-10-27 14:11:46 +00:00
junyoung 8f1ba94956 Nuke __P(). 2003-10-27 13:43:48 +00:00
christos 7f7c7b7d99 Back out the libretto related hacks I accidentally committed. They are
in CVS in case one wants them :-)
2003-10-27 04:10:43 +00:00
yamt 8122bbfb62 issue PAUSE during ipi rendezvous even with DIAGNOSTIC. 2003-10-26 11:09:13 +00:00
yamt f16e031e00 don't grab kernel lock for SYCALL_MPSAFE syscalls. 2003-10-26 10:48:08 +00:00
lukem f85d2d1c14 Use ${HOST_SH} instead of `sh'.
If necessary, pull in <bsd.sys.mk> to get the definition of HOST_SH;
Makefiles that pull in one of (most of) <bsd.*.mk> will get this anyway.
2003-10-26 07:25:33 +00:00
dyoung 4b8cd4a6ea Make the tags: target create tags for the ath(4) HAL. 2003-10-26 00:17:46 +00:00
christos b92846c162 Fix uninitialized variable warnings. 2003-10-25 21:34:07 +00:00
mycroft ca57a40612 Remove bogus initializers. 2003-10-25 19:38:18 +00:00
mycroft 8fd2d44a41 Add a missing default. 2003-10-25 19:37:47 +00:00
christos 65235b9eb5 Fix uninitialized variable warnings 2003-10-25 18:40:37 +00:00
mycroft 0965dd2ada Recognize ESS1879. 2003-10-23 14:28:55 +00:00
chs 65d5587ddd rename pv_next to pv_node. use SPLAY_RIGHT() instead of expanding it inline. 2003-10-23 08:30:21 +00:00
provos 6a583bc5cb changed linked list in pmap_remove_pv to a splay tree; approved: fvdl@ 2003-10-23 03:03:20 +00:00
kleink 5d1a2f48d2 Use a common <machine/math.h> for amd64 and i386. 2003-10-22 11:54:23 +00:00
cl ed9c2d7075 don't uvm_swapout LWPs which are LSONPROC on another cpu.
uvm_swapout_threads will swapout LWPs which are running on another CPU:
- uvm_swapout_threads considers LWPs running on another CPU for swapout
  if their l_swtime is high
- uvm_swapout_threads considers LWPs on the runqueue for swapout if their
  l_swtime is high but these LWPs might be running by the time uvm_swapout
  is called

symptoms of failure: panic in setrunqueue

fixes PR kern/23095
2003-10-19 17:45:35 +00:00
lukem 184141db07 Use one 'atabus* at ata?' instead of multiple 'atabus* at FOOide? channel ?' 2003-10-18 08:12:07 +00:00
lukem e1616bdc8a use 'atabus* at ata?'
use 'atapibus* at atapi?' instead of 'atapibus* at atabus?'
2003-10-18 08:11:02 +00:00
fvdl 6a6db3cbd9 Add hooks and structures to allow the MP table intr mapping code a
better shot at finding a mapping. For PCI interrupts, if a bus
has no mappings, try its parent, with the swizzled pin, and the
bridge's device number.
2003-10-16 22:56:29 +00:00
gson d1298fd2a7 If a bootxx program already happened to be a multiple of 512 bytes in
length before padding, the shell command to conditionally pad it to
a multiple of 512 bytes returned a nonzero exit status, causing the
build to fail.
2003-10-15 03:49:57 +00:00
dsl ca9f17c96d Add bsd.obj.mk so these directories get their own obj directory (for the
library objects shared by their subdirectories).
Needed when the obj directory isn't a parent of the subdirectories obj directory
2003-10-13 06:56:47 +00:00
dyoung 18cc6db280 For PCI attachment, ath(4) needs both the HAL binary and the files
listed in dev/pci/files.ath.
2003-10-13 06:40:14 +00:00
lukem e076c47767 Instead of defining TERSE_ERROR by default (due to space constraints),
define NO_LBA_CHECK.  bootxx_msdos still needs TERSE_ERROR because its
BPB is larger than the default.
2003-10-13 06:15:00 +00:00
lukem af93a5c749 The reserved space for the BIOS Parameter Block (BPB) only needs to be for
FAT16 (11+51) except when booting from FAT{12,16,32}, which needs FAT32 (11+79).
We still reserve the BPB for non-bootxx_msdos PBR bootblocks because
they may be installed as a floppy boot record (and those need a BPB).

Remove some redundant wording in an error messsage, saving 6 bytes.
2003-10-13 06:08:28 +00:00
dyoung 8a58dbfd9a Add atw at cardbus (ADMtek ADM8211 802.11). 2003-10-13 05:46:26 +00:00
dyoung f39f5e0652 Add atw (ADMtek ADM8211 802.11). 2003-10-13 05:45:59 +00:00
dyoung 2f8d4622dd Add atw at cardbus (ADMtek ADM8211). 2003-10-13 05:43:14 +00:00
dyoung b491c05ae7 Add the 82801EB LPC, which provides the PCI Interrupt Router on
the Dell PowerEdge 400SC.
2003-10-13 05:19:19 +00:00
jdolecek 0979ebaa1c g/c major for 'netsmb' and mark the slot free - it has never been used 2003-10-11 07:54:26 +00:00
jdolecek ef5bb330f5 reassing majors for crypto and pf to use the newly defined MI major
range
2003-10-10 22:42:39 +00:00
jdolecek 4e915c9ccd update the comment - the space for machine-dependant majors
is reduced to 0-143
follows discussion on tech-kern
2003-10-10 21:21:25 +00:00
thorpej a483d3a893 Delete the vinum major; it conflicts with an existing entry, and should
be added to the MI space anyway.
2003-10-10 17:36:56 +00:00
simonb 84fa2d5a87 Take previous even further - leave only CTL_MACHDEP and related
definitions and structures outside the #ifdef _KERNEL block.
2003-10-10 13:02:34 +00:00
yamt 26efaef9af revert the previous (thanks, lukem)
and wrap curcpu, cpu_info and friends with #ifdef _KERNEL completely.
2003-10-10 11:53:44 +00:00
lukem b313b2641e Userland needs <stddef.h> for offsetof(), not <lib/libkern/libkern.h> ...
(Arguably a chunk more of this file could be protected with _KERNEL.
That's a separate project.)
2003-10-10 06:27:15 +00:00
grog 2ce576d37a Add config info for Vinum 2003-10-10 04:50:07 +00:00
grog c6ed3adf63 Add major number for Vinum. 2003-10-10 03:51:58 +00:00
yamt d9d3c0dd8e avoid a magic number in curcpu(). 2003-10-09 13:46:43 +00:00
dsl ab073a34f8 Move lib/crt/start_rom.S to a more sensible location. 2003-10-09 10:56:13 +00:00
dsl 44ac426707 Use real_to_prot (etc) from stand/lib.
Add a patchable header for boot parameters (eg console type).
2003-10-09 10:36:26 +00:00
dsl 3d4b6a197d Pick up X86_BOOT_MAGIC_* from bootblock.h
Move boot_params.S to lib (seems useful to use it in pxeboot).
2003-10-09 10:29:39 +00:00
dsl 6f9f3c64a7 Move start_pxe.S to a more sensible place 2003-10-09 09:42:25 +00:00
thorpej 901da40cf9 Add some accessor macros for the ucontext:
* _UC_MACHINE_PC() - access the program counter
* _UC_MACHINE_INTRV() - access the integer return value register
* _UC_MACHINE_SET_PC() - set the program counter (this requires
  special handling on some platforms).
2003-10-08 22:43:01 +00:00
thorpej 55452b8f35 Use KSI_INIT_TRAP(). 2003-10-08 19:10:30 +00:00
dsl 977fe7c488 Change the way the shared lib directory is handled.
Should now work if ${.OBJDIR} = ${.CURDIR}/obj.
2003-10-08 18:51:50 +00:00
dsl cabc1ae936 Need to explicitly create directory behing symlink.
Clean share lib directory.
2003-10-08 18:38:43 +00:00
dsl 2ae753f095 Only build the libraries once, 2003-10-08 18:20:15 +00:00
dsl c8b26967a8 These files are not used by the new boot code. 2003-10-08 13:10:20 +00:00
dsl c86f86e53a BSSTART was only used for the (now depracated) old stand/biosboot code. 2003-10-08 13:06:30 +00:00
augustss be81c72bb8 Alphabetize. 2003-10-08 12:08:38 +00:00
bouyer f5a6a0a843 Add new per-chip pciide drivers. 2003-10-08 11:55:43 +00:00
bouyer 8f905677f4 Adapt for wdcattach() prototype change. 2003-10-08 11:10:18 +00:00
bouyer f003412676 Add atabus 2003-10-08 11:10:04 +00:00
lukem 8ff09e8ecf Remove the unused "hardcode the blocks of /boot" versions /boot and
i386-MD installboot.
They haven't been enabled for a while, keeping them here is just
confusing, and they're still going to be in the CVS repo attic...
2003-10-08 04:43:28 +00:00
lukem 1c33b4e6a4 Overhaul MBR handling (part 1):
<sys/bootblock.h>:
    *	Added definitions for the Master Boot Record (MBR) used by
	a variety of systems (primarily i386), including the format
	of the BIOS Parameter Block (BPB).
	This information was cribbed from a variety of sources
	including <sys/disklabel_mbr.h> which this is a superset of.

	As part of this, some data structure elements and #defines
	were renamed to be more "namespace friendly" and consistent
	with other bootblocks and MBR documentation.
	Update all uses of the old names to the new names.

<sys/disklabel_mbr.h>:
    *	Deprecated in favor of <sys/bootblock.h> (the latter is more
	"host tool" friendly).

amd64 & i386:
    *	Renamed /usr/mdec/bootxx_dosfs to /usr/mdec/bootxx_msdos, to
	be consistent with the naming convention of the msdosfs tools.

    *	Removed /usr/mdec/bootxx_ufs, as it's equivalent to bootxx_ffsv1
	and it's confusing to have two functionally equivalent bootblocks,
	especially given that "ufs" has multiple meanings (it could be
	a synonym for "ffs", or the group of ffs/lfs/ext2fs file systems).

    *	Rework pbr.S (the first sector of bootxx_*):
	    +	Ensure that BPB (bytes 11..89) and the partition table
		(bytes 446..509) do not contain code.
	    +	Add support for booting from FAT partitions if BOOT_FROM_FAT
		is defined.  (Only set for bootxx_msdos).
	    +	Remove "dummy" partition 3; if people want to installboot(8)
		these to the start of the disk they can use fdisk(8) to
		create a real MBR partition table...
	    +	Compile with TERSE_ERROR so it fits because of the above.
		Whilst this is less user friendly, I feel it's important
		to have a valid partition table and BPB in the MBR/PBR.

    *	Renamed /usr/mdec/biosboot to /usr/mdec/boot, to be consistent
	with other platforms.

    *	Enable SUPPORT_DOSFS in /usr/mdec/boot (stage2), so that
    	we can boot off FAT partitions.

    *	Crank version of /usr/mdec/boot to 3.1, and fix some of the other
	entries in the version file.

installboot(8) (i386):
    *	Read the existing MBR of the filesystem and retain the BIOS
    	Parameter Block (BPB) in bytes 11..89 and the MBR partition
	table in bytes 446..509.  (Previously installboot(8) would
	trash those two sections of the MBR.)

mbrlabel(8):
    *	Use sys/lib/libkern/xlat_mbr_fstype.c instead of homegrown code
	to map the MBR partition type to the NetBSD disklabel type.


Test built "make release" for i386, and new bootblocks verified to work
(even off FAT!).
2003-10-08 04:25:43 +00:00
thorpej 68723a995b * Shuffle some data structures so, and add a flags word to ksiginfo_t.
Right now the only flag is used to indicate if a ksiginfo_t is a
  result of a trap.  Add a predicate macro to test for this flag.
* Add initialization macros for ksiginfo_t's.
* Add accssor macro for ksi_trap.  Expands to 0 if the ksiginfo_t was
  not the result of a trap.  This matches the sigcontext trapcode semantics.
* In kpsendsig(), use KSI_TRAP_P() to select the lwp that gets the signal.
  Inspired by Matthias Drochner's fix to kpsendsig(), but correctly handles
  the case of non-trap-generated signals that have a > 0 si_code.

This patch fixes a signal delivery problem with threaded programs noted by
Matthias Drochner on tech-kern.

As discussed on tech-kern.  Reviewed and OK's by Christos.
2003-10-08 00:28:40 +00:00
skd 6347eb786e Support for proper siginfo FP codes. Also, set si_trap to fp status word.
Approved by fvdl.
2003-10-07 14:35:37 +00:00
lukem 420f3b76ba Replace BP_* with I386_BP_FLAGS_*, for consistency with other stuff in
<sys/bootblock.h>
(CONSDEV_ should be converted as well, but that's more intrusive...)
2003-10-06 05:24:54 +00:00
tron 0fba6709ad Add entry for bce(4). 2003-10-05 11:42:38 +00:00
jdolecek e6286b949a Add some framework for MI assignment of device majors - add sys/dev/majors
which is automatically included during kernel config, and add comments
to individual machine-dependant majors.* files to assign new MI majors
in MI file.

Range 0-191 is reserved for machine-specific assignments, range
192+ are MI assignments.

Follows recent discussion on tech-kern@
2003-10-05 08:04:24 +00:00
junyoung d1486d51cb Rearrange instructions for better use of pipeline. This shaves off 0.5%
of time on interrupt/trap entry on my Athlon 1800.
2003-10-04 05:57:51 +00:00
mrg 3942bb7a51 enable broadcom BCM4401 (bce) driver (as found on recent dell laptops) 2003-09-27 13:16:16 +00:00
christos 6fc26a7684 add SIGTRAMP_VALID and gc old sigcontext <-> ucontext macros. 2003-09-27 03:14:31 +00:00
nathanw 4d59420344 Move __cpu_simple_lock_t and __SIMPLELOCK_{UN,}LOCKED to machine/types.h
so that they can be used in a namespace-friendly way.
2003-09-26 22:45:41 +00:00
christos cfba45c856 constify sendsig/trapsignal 2003-09-25 22:00:02 +00:00
mycroft eefae40298 Hide the use of config_interrupts() in one place. 2003-09-25 19:29:48 +00:00
mycroft 864b96269c Modify the fdcattach() interface again, splitting it into two parts, so that
DRQ allocation is done earlier.
2003-09-25 19:06:19 +00:00
pooka a41fa163fd iavc@pci 2003-09-25 16:00:24 +00:00
mycroft 3d7395ab71 Update for new attach method. 2003-09-25 01:12:43 +00:00
mycroft d40837608f 1) Use config_interrupts() to attach IDE and ATAPI drives. This eliminates
most polling.
2) Clean up some goofiness in pciide -- get rid of the whole "candisable" path
   (it's gratuitous) and simplify the code by calling pciide_map_compat_intr(),
   *_set_modes() and wdc_print_modes() from central locations.
3) Add a register writability and register ghost test to eliminate phantom
   drives more quickly.
2003-09-19 21:35:56 +00:00
drochner 27c7714f95 syntax error in comment 2003-09-17 11:57:34 +00:00
cl abc609d801 add MD part of SA/pthread pagefault handling on i386 2003-09-16 13:57:47 +00:00
simonb f7e3330a08 Remove a variable that is assigned to but not used. 2003-09-13 11:12:06 +00:00
christos 280bbfe466 Set si_code for T_PROTFLT|T_USER. Pointed out by enamicode. 2003-09-12 23:20:26 +00:00
christos 51d8c27c8d pick up the right sigreturn symbol. we could have #define __HAVE_SIGINFO
instead too.
2003-09-12 16:51:04 +00:00
christos 75c419ccc0 include opt_compat_netbsd.h, sort includes. Thanks yamt. 2003-09-12 12:39:59 +00:00
christos 9889f06536 make sigcontext visible all the time instead of including opt_*.h from a
large number of files.
2003-09-12 01:13:35 +00:00
christos 2bf3634159 fix typo. 2003-09-11 20:48:35 +00:00
christos 7340db7385 Bring back sigcontext to userland by popular demand. 2003-09-11 20:22:30 +00:00
christos 99ee91793f make vm86 use __gregset_t 2003-09-11 19:17:07 +00:00
christos a6540cf740 XXX: vm86 for sigcontext comment is gone. 2003-09-11 19:16:05 +00:00
christos ab63d91442 old vm86 call with COMPAT_16 code. 2003-09-11 19:15:12 +00:00
kleink d440784b30 __{BEGIN,END}_DECLS-wrap prototypes. 2003-09-11 09:40:11 +00:00
christos 2300d30c79 delete debug printf's. 2003-09-10 21:40:02 +00:00