Commit Graph

13730 Commits

Author SHA1 Message Date
is e10e9e8455 Clean up the attach messages a bit. 1996-10-19 16:54:14 +00:00
jonathan 3bd4c6caee regen from pcidevs 1.20 1996-10-19 13:04:51 +00:00
jonathan 7717235f4c Add productId for RealTek 8029 PCI ethernet board. 1996-10-19 13:01:49 +00:00
jonathan 05c95ca095 Update copyright. 1996-10-19 12:40:31 +00:00
thorpej cf9b36ab1d Set up a kernel_map entry for the text segment with protection of
VM_PROT_READ|VM_PROT_EXECUTE.  The previous default (VM_PROT_ALL)
would cause the following scenario:
	- someone attempts to write kernel text (my test was writing
	  to an offset of /dev/kmem which was known to be in the text
	  segment, while in single-user mode).
	- enter trap() with MMU fault (because of RO pte).
	- trap() calls vm_fault(), which looks up vm_map_entry for
	  fauling address.
	- vm_fault interprets write fault and VM_PROT_WRITE (in VM_PROT_ALL)
	  as COW; new page allocated, data copied to new page, new page
	  mapped in at trunc_page(<faulting va>).
	- wow, look at the fireworks!
Fixes two potential symptoms:
	- kernacc() returns TRUE when checking for permission to write
	  an offset in kernel text, which is bogus, since the text has
	  been mapped RO by pmap_bootstrap().
	- Handling of a stray pointer that attempted to scribble into
	  kernel text would not be executed properly.
1996-10-19 08:51:33 +00:00
cgd a6d9feb7a5 clean up chrtoblktbl, adding comments naming the devices which actually do
have entries in both device switch tables.  Add 'st' entry to chrtoblktbl.
1996-10-18 21:26:57 +00:00
cgd 44365140cf Severely clean up netisr handling. Clean up includes for netisr handlers.
Fix PPP netisr handling, add NATM netisr handling.
1996-10-18 20:35:23 +00:00
chuck 41a87a7ae0 fix: add missing ntohs() for llc mode, as noted by several people including
Dong Lin, Zdenek Salvet, and Matthias Drochner(i think).
1996-10-18 19:26:54 +00:00
explorer efccf77947 Add quirk entries for two more optical drives; closes pr kern/2861 1996-10-18 17:22:17 +00:00
fvdl d1400746a5 Fix some printf formatting strings within DEBUG and DIAGNOSTIC defines.
From Mike Long, PR 2859
1996-10-18 09:03:42 +00:00
thorpej 6126eea479 Tell the `upper half' of the VM system that page 0 isn't mapped. If we
don't do this, kernacc() will bogusly return TRUE for page 0, causing a
NULL pointer dereference in uiomove() when reading /dev/kmem.

Thanks to Scott Reynolds for noticing the problem.
1996-10-18 08:57:14 +00:00
mrg 8fd70c1fe1 in coredump(), check the SUGID bit rather than testing various parts
of the cred structures.  this prevents a previously set[gu]id process
from generating a core file.
1996-10-18 08:39:34 +00:00
thorpej 150c33e60b Use ${INSTALL}. 1996-10-18 05:55:26 +00:00
thorpej c9592404ce Clarify the comment about enabling interrupts above level 11, suggested
by Andrew Gillham.
1996-10-18 01:36:16 +00:00
mark 1f388af5cf Fixed 4 compiler warnings about casts on insw() and outsw() calls. 1996-10-18 00:48:29 +00:00
fvdl 990f0ce9b7 Add RCS Id. 1996-10-17 19:46:39 +00:00
fvdl 6177bfa965 Remove compiler warning when USER_LDT not specified. PR 2852 1996-10-17 19:41:00 +00:00
fvdl 3e338cbad4 Fix compiler warning (PR 2852) 1996-10-17 19:38:45 +00:00
fvdl f9a53c581f Cast ioport_ex_storage to caddr_t, needed becauseit is now long[]
and creates warnings.
1996-10-17 19:31:09 +00:00
cgd 8f799be896 add a WEAK_ALIAS macro if building on an ELF-capable system, which creates
a weak alias for a symbol.
1996-10-17 18:33:53 +00:00
perry 8a0600b163 removed #ifdef tahoe 1996-10-17 16:31:54 +00:00
is 7e1b190155 Change Blizzard IV/1260/2060 to the name used by the driver.
While we're here, clean up a few other entries.
1996-10-17 15:49:39 +00:00
is 8f5996c976 Add driver bznsc (for BliZzard, New version: -IV, -1260, -2060).
Still untested on -1260/-1230, and hangs when enforcing SFAS_NO_DMA on 2060;
but works with DMA on the latter.

Still untested in a NetBSD-12A environment. (Sorry, don't have the hardware
myself.)

Thanks to Laurent Baroukh for being the guinea pig, and to Jerome Lovy
for forwarding the hardware information Phase V gave him, and to Phase
V for providing it.
1996-10-17 15:42:36 +00:00
ws 2c65d27e6b Forgot to "cvs add" this in the last:
Rename recently checked in KGDB to IPKDB to resolve conflicts with older KGDB
1996-10-17 12:09:05 +00:00
thorpej 78bce16293 Couple of changes:
- Rename EX_NOBLOB to EX_NOCOALESCE; it's much more descriptive of
  what's going on.
- Ensure that fixed extent storage is longword aligned.
1996-10-17 08:31:28 +00:00
thorpej 2487643691 Several changes:
- Rename EX_NOBLOB to EX_NOCOALESCE; it's much more descriptive of
  what's going on.
- Use ALIGN(), rather than our homegrown EXTENT_ALIGN(), when dealing
  with map overhead.  Privatize the EXTENT_ALIGN() macro; there's no need
  to export it.
- Implement EX_BOUNDZERO flag.  This changes the boundary line policy in
  extent_alloc() and extent_alloc_subregion(); boundary lines are
  computed relative to 0, rather then the start of the extent.
- Add a new flag to specify that it's ok to wait for space in the
  extent: EX_WAITSPACE.
- Add some whitespace in the function prototypes.
1996-10-17 08:29:05 +00:00
thorpej 52c0d38a1a Several changes:
- Rename EX_NOBLOB to EX_NOCOALESCE; it's much more descriptive of
  what's going on.
- In extent_free_region_descriptor(), if we're a fixed extent,
  freeing a dynamically allocated region descriptor, and someone
  is waiting on the freelist, let the waiter have it, rather than
  free'ing it back to the system.
- Use ALIGN(), rather than our homegrown EXTENT_ALIGN(), when dealing
  with map overhead.  Privatize the EXTENT_ALIGN() macro; there's no need
  to export it.
- Implement EX_BOUNDZERO flag.  This changes the boundary line policy in
  extent_alloc() and extent_alloc_subregion(); boundary lines are
  computed relative to 0, rather then the start of the extent.
- Fix a nasty race between multiple participants doing region and
  descriptor allocation.
- Add a new flag to specify that it's ok to wait for space in the
  extent: EX_WAITSPACE.
- Blow away an unnecessary splhigh()/splx().
- Put a bunch of sanity code inside #ifdef DIAGNOSTIC/#endif.
1996-10-17 08:27:35 +00:00
scottr 6bb6fab4ce Changes from the hp300 trap.c:
- Fix up usage of MBD_ISPID().  (from Jason Thorpe)
- Be careful not to deref bad pointers in the MMU fault handler.  (ditto)
- Ensure trap() never deals with a NULL proc, and if our proc has
  no pcb, punt.  (Suggested by Gordon Ross)
1996-10-17 06:42:44 +00:00
scottr ccaecc2dda Some changes from hp300 (thanks Jason!):
- Initialize proc0.p_addr just after setting up the kernel stack, to avoid
  getting NULL pointers in trap().  Change suggested by Gordon Ross.
- Panic if main() returns.
1996-10-17 06:32:13 +00:00
jonathan 772aec9bf4 Remove #ifdef DEBUG lint:
change "%x" -> "%p" for printfs() with pointer args in i386_{set,get}_ldt()
1996-10-17 05:26:25 +00:00
jonathan 6dab138cc0 Remove lint inside #ifdef DEBUG:
* fix pmap debugging format strings: "%x" -> "%lx" for vm_offset_t
         "%x" -> "%p" for pointers.
  * add prottypes for pmap dumping functions
  * add missing return types on pmap dumping functions
  * move initialization of pamp_enter_pv():pv  before #ifdef DEBUG code
    which uses pv.
1996-10-17 05:11:47 +00:00
thorpej 0211a3232d Appease the compiler: get rid of some unused variables, add some
prototypes, and suppress a bogus "might be used uninitialized" warning.
It's clear from reading the logic of the function that produces the
warning that the variable will not be used uninitialized, but the
compiler just isn't smart enough, I guess.  Marked XXX for future reference.
1996-10-17 04:34:08 +00:00
cgd e6d0f7439f copy down changes from libc 1996-10-17 04:26:20 +00:00
thorpej 35b8c6aa4c Add some prototypes, clean up some unused variables, and misc. other
compiler warning cleanup.
1996-10-17 04:21:55 +00:00
mark ac0fd0fce1 Added a few more patches for SA100 support. This is just several
extra cache clean operations during pte manipulation.
1996-10-17 02:55:29 +00:00
mark 6b1666ce52 Don't generate an error if FFS is not compiled in. 1996-10-17 02:52:26 +00:00
cgd 8cab2f173f update for changes in asm.h 1996-10-17 02:50:38 +00:00
mark c252b86536 Couple of fixes for SA100 support.
Added comments to match up #ifdef / #endif pairs.
1996-10-17 02:50:14 +00:00
cgd 905f7abae1 Add __CONCAT and ___CONCAT to concatenate identifiers. Add LLABEL to
create an assembly label, and SYSCALLNUM to convert a syscall name into
the macro that's defined to be its number.  Add a CALLSYS_NOERROR macro
which invokes the named system call.  (CALLSYS_NOERROR is here since
it's used in locore, for sigcode.)
1996-10-17 02:49:04 +00:00
mark 1dd91a8515 Updated vmemcachectl() to allow control of write buffer and cache enable
bits on the video memory ptes.
1996-10-17 02:48:39 +00:00
mark f5c1850ab4 Tweaked several db_printf() calls. 1996-10-17 02:46:49 +00:00
mark 65b01531b9 Reality check. 1996-10-17 02:44:17 +00:00
mark 36cd31048b Removed references to the debug function checkinodes(). 1996-10-17 02:43:38 +00:00
mark abb703fc1b Add files for cosc SCSI driver
Add file for RC7500 prom code.
1996-10-17 02:41:26 +00:00
mark 6ed8e72d96 Fix the pcb_fpstate field. 1996-10-17 02:37:48 +00:00
mrg d21bcc8564 make the value of NetBSD in 1.2A > in 1.2. they were 199608 and
199609 respectively.  the former is now 199610.
1996-10-17 02:10:49 +00:00
cgd f929fef799 pull down from libc 1996-10-17 01:41:35 +00:00
gwr 377ab56b5e Add definitions for the Z85C30 and Z85230 enhanced serial controllers.
Thanks to Bill Studenmund <wrstuden@loki.stanford.edu>
1996-10-16 22:34:52 +00:00
jtk 37449bd6a8 fix compile warnings with -DDEBUG or -DAPMDEBUG 1996-10-16 22:30:34 +00:00
gwr 5c9746c6d1 Replace the field cs_rr0_new with cs_rr0_delta (keep changes instead). 1996-10-16 20:43:39 +00:00
gwr 3424a892b9 Correct a problem with CRTSCTS flow control where output may fail to
restart if we get multiple status interrupts before the softintr()
routine gets a chance to run.  The fix is to determine and accumulate
status line changes at the H/W interrupt level, and then check and zero
the accumulated changes when the softint() finally runs.  Many thanks
to Bill Studenmund <wrstuden@loki.stanford.edu> for finding and fixing.
1996-10-16 20:42:14 +00:00
gwr 58db3aa496 Replace the field cs_rr0_new with cs_rr0_delta (keep changes instead). 1996-10-16 20:34:54 +00:00
ws 31bdb14ed5 Rename recently checked in KGDB to IPKDB to resolve conflicts with older KGDB 1996-10-16 19:32:08 +00:00
ws cf37e5a69e Indent properly 1996-10-16 17:26:19 +00:00
ws e8b039bf8b Add EXEC_ stuff 1996-10-16 17:13:28 +00:00
leo 86c616102f select -> poll 1996-10-16 12:57:11 +00:00
leo 226d874081 Add '-Wall -Wstrict-prototypes -Wmissing-prototypes' to CFLAGS. 1996-10-16 12:53:46 +00:00
leo 4a6637f783 Add EXEC_SCRIPT and EXEC_AOUT options. 1996-10-16 12:52:47 +00:00
leo b87085e3a0 Update pathnames of included files for new version of config. 1996-10-16 12:50:30 +00:00
leo b0b9a3e82c locore.s now needs FR_SIZE. 1996-10-16 12:42:45 +00:00
leo 1bd559103e Sync trace traps with the hp300. 1996-10-16 12:41:50 +00:00
jtk bfe653fbd7 fix PR 2851: make it compile under -Wformat 1996-10-16 11:32:45 +00:00
christos 5bf4fd3d8b make the fu{s,}word() and fuswintr() prototypes return an int instead
of a short so that we can detect errors.
1996-10-16 11:27:25 +00:00
jonathan 5c6013d588 Clone a 5000/{120,125,133} config file from the 5000/240 config. 1996-10-16 08:35:49 +00:00
jonathan 3280c75a3d Update model-specific pmax kernel config files for post-12 config:
add arch/pmax/conf/ to includes,  options MIPS1,   etc.
1996-10-16 08:29:34 +00:00
scottr fb42630e15 Eliminate fusword() prototype, as it's now in <sys/systm.h> 1996-10-16 06:27:05 +00:00
jonathan 8ffa855e18 Increase MAXDSIZE to 256Mbytes. 1996-10-16 06:10:41 +00:00
jonathan 0d1085302d alpha_mb() -> tc_mb(), for alpha/pmax convergence, even tho the tc_mb()
interface in tc_machdep.h is obsolete.
Change "#if 0" around  pmax rcons mouse-redirection to "#ifdef HAVE_RCONS"
1996-10-16 05:07:57 +00:00
jonathan f5343d2229 Cleanups, and convergence with the Alpha driver:
* kill scc_tty[] and needs-count.
  * Add usable-when-cold version of sccparam().
  * Add pre-autconf() console initialization entrypoint.
  * remove lint for gcc -Wall
  * wbflush() -> tc_mb()
all but the last of which have been fed through cgd and committed to the
Alpha scc driver.
1996-10-16 05:04:51 +00:00
cgd caa0b41652 spaces -> tabs where appropriate, some (minor) KNF (it needs much more),
kill spaces at EOL.
1996-10-16 04:07:16 +00:00
scottr e326c3123f We're paranoid; disable the IIci's cache card. 1996-10-16 04:00:28 +00:00
scottr 3370e6c419 External cache card on the IIci is enabled by default;
use DISABLE_EXT_CACHE to turn it off.
1996-10-16 03:55:21 +00:00
cgd 99ffca7953 more updates from jonathan. kill scc_tty array and needs-count 1996-10-16 03:53:31 +00:00
jonathan 428a2b873f Fix polled I/O getc/putc functions for non-serial consoles when
still cold (e.g., to initialize keyboards and mice).
Why these use polled, rather than interrupt-driven, IO is a mystery.
1996-10-16 02:10:33 +00:00
jtk aa8449a9ef fix compile errors & warnings 1996-10-16 01:12:18 +00:00
mark fdf25ce9ce Added generic ARM7500 support. This mainly effects the kernel bootstrapping
code as video memory must be reserved from main memory for the display.
In addition this adds generic support for using DRAM for video memory
on all machines. All video memory accessing should use the video_memory_t
structure.
Added support for the RC7500 motherboard. The RC7500 support includes a
replacement init_arm() function. This also supports the RC7500 prom debug
monitor for debugging the kernel boot.
dumps now work so call dumpsys() following a panic.
Added support for the SA110. This mainly consists of making sure the data
cache is cleaned when appropriate and that the instruction cache is
kept in sync during the bootstrap and when signal handlers are built on
the stack.
Use a larger UND32 mode stack if we are configured for KGDB.
Remove KERNEL_PT_KSTACK references as these should have died with the
removal of double mapped kstacks eons ago.
Make sure we call doshutdownhooks() if boot is called while we are still
cold.
Cleaned up prototypes declarations.
Sorted out comment indentation.
1996-10-16 00:35:45 +00:00
cgd 862e0d2653 various bits of cleanup, from jonathan stone, to make this and the pmax
driver slowly converge.
1996-10-16 00:03:02 +00:00
cgd f31bd002d2 add a new function, hwrbp_restart_setup(), to be called after
autoconfiguration.  It clears the RPB's per-cpu-slot BIP flag and
sets up the RPB's restore_term and restart vectors, etc.  add a
console_restart() function, which causes a panic and system dump,
that is invoked (indirectly) via those vectors.
1996-10-16 00:00:40 +00:00
cgd 2f7e2d8853 add an XentRestart, pointed to by the retore_term HWRPB vector (and maybe,
eventually, the restart HWRPB vector), which calls console_restart.  This
is invoked when the console halt switch is used and the user enters 'c'
at the console prompt, and eventually causes a system crash dump to be
generated.
1996-10-15 23:56:56 +00:00
mark 1beb8a9aad Added support for the SA110. This primarily consists of extra cache
clean and tlb flush code along with write buffer drains that are
dependant on the definition of  CPU_SA110.
The memory reserved for the L1 pagetables is now wired into the memory map
during the pmap_init rather than at L1 pagetable allocation time.
The L1 pages tables are zeroed during initialisation and when they are
released rather than when they are allocated.
When searching for a free L1 page table start search at the page table
after the last one allocated rather than always starting from the first one.
Added some extra DIAGNOSTIC checks for invalidate page index numbers.
Removed some old debugging code that escaped the last clean up.
Idented comments in line with code.
1996-10-15 23:52:52 +00:00
cgd 9da2b9743a define and call a new function, hwrbp_restart_setup(). It's called after
autoconfiguration to clear the RPB's per-cpu-slot BIP flag and to set up the
RPB's restart function pointers, etc.
1996-10-15 23:52:49 +00:00
christos 7ad3f1a832 regen 1996-10-15 23:42:42 +00:00
christos c354418add Use the official 3com part names; from Curt Sampson 1996-10-15 23:41:56 +00:00
mark daec9c54ff Use atomic_{set,clear}_bit() for manipulating the soft interrupt mask.
splsoftclock() is now a macro so the function is dead.
Cleaned up and debugged dumpsys(), kernel core dumps now work.
1996-10-15 23:39:30 +00:00
cgd e897979b3e don't set dumplo to -1 on error. deal with the case where dumplo is
still 0 after dumpconf().
1996-10-15 23:27:27 +00:00
mark 81f6df323e *Major* rewrite, long overdue.
The irq delivery code has been rewritten. On entry to the irq vector the
processor is switched to SVC32 mode so all interrupt routines now run
in SVC32 mode rather than IRQ32 mode. This fixes lots of irq re-enabling
problems.
Interrupt latency times are now vastly improved for high priority interrupts.
Cleaned up calling ast() before returning to USR32 mode (don't need to
mess about with trapframe copying.
Cleaned up all the comments and sorted out their indentation.
Rewritten the soft interrupt delivery code.
Added generic ARM7500 support rather than just RC7500 support.
1996-10-15 23:20:40 +00:00
cgd c8e4c454f2 curproc was being used directly for ru_{in,ou}block counting. Instead
of using it directly, use a local, and set that local to be curproc
if curproc is not NULL else a pointer to process 0's proc struct.
If syncing disks while handling a panic that occurred while 'curproc'
was NULL, the old code would dereference NULL and die.
1996-10-15 23:06:27 +00:00
cgd 279c087328 reorganize tsleep() so the (cold || panicstr) test is done before the
ktrace context switch checking.  If syncing disks while handling a panic
that occurred while 'curproc' was NULL, the old code would dereference
NULL and die.  The (slight) reorganization was done so that space (one extra
splhigh()), rather than time (one extra comparison), would be wasted.
1996-10-15 23:00:10 +00:00
mark b37e8debe6 Added a generic exit routine. This loops round calling ast() if the
astpending flag is set until it is clear at which point to exits to
user land.
Merged in latest kgdb support from Wolfgang.
1996-10-15 22:56:27 +00:00
mark 32549532dc Major comment and code clean up to suit KNF.
Added support for the SA110. This cpu does not need any register fix-ups
following a data abort.
Return valid signal code values on SEGV's. See machine/signal.h for
decoding SEGV signal codes.
1996-10-15 22:22:22 +00:00
mark f015b1bac6 Added support for the SA110. Additional cache clean operations are
required during pagemove() and vmapbuf() and vunmapbuf().
The kernel and undefined mode stack checks are now guarded with
#ifdef STACKCHECKS.
Tidied up comments.
1996-10-15 22:07:41 +00:00
mark af9c048e19 Added support for the SA110. If CPU_SA110 is defined then the data
cache needs to be cleans and the instruction and data caches need to
be invalidate along with the instruction and data tlbs when
the TTB is reloaded during a context switch.
1996-10-15 22:04:19 +00:00
thorpej 9f1ba5739f Don't need "options GENERIC" anymore. 1996-10-15 22:01:53 +00:00
thorpej 608efe383e Use the hp300 version of db_memrw.c (forgot to commit this change the
other day).
1996-10-15 22:00:31 +00:00
thorpej b12cf5890d RCS id police. 1996-10-15 21:59:03 +00:00
mark 5a79d9e2a1 Add the lmcaudio device and files. 1996-10-15 21:53:21 +00:00
mark e41dd7d935 Provide a completely new set of cache clean and tlb flush functions
if CPU_SA110 is defined. Cache cleaning is different on the SA110 as
the cache is a write back virtual cache and is split for data and instruction.
Also the cache and tlb control instructions use different coprocessor #15
registers.
1996-10-15 21:47:51 +00:00
cgd 709ebdf6ab panic must print a newline 1996-10-15 21:35:56 +00:00
mark c77f36a38a Idented comments correctly.
Fixed bug in microtime() that could result in incorrect microsecond
adjustments.
1996-10-15 21:35:23 +00:00
mark 535518ceed Added support for the A7000 and more generally for ARM7500 based machines
that are not RC7500 boards.
Fixed vidcaudio_sw_encode() and vidcaudio_sw_decode() functions.
1996-10-15 21:33:51 +00:00