Commit Graph

4893 Commits

Author SHA1 Message Date
leo 84c03e6058 - Remove race condition from DMA interrupt handler
- Add function to get current DMA address for Falcon SCSI.
1995-05-14 15:46:17 +00:00
leo 571c7445e0 Remove double mapping of stack. 1995-05-14 15:44:19 +00:00
leo 1029a77f13 Function proto added. 1995-05-14 15:29:18 +00:00
leo cf6323d778 Fixup comment. 1995-05-14 15:27:51 +00:00
leo e2b044e52f - Remove double mapping of stack
- Change to new coredump format
1995-05-14 15:26:55 +00:00
leo 72472e35b1 Remove double mapping of stack 1995-05-14 15:24:35 +00:00
leo 92d594935c - Remove double mapping of stack
- Change to new coredump format
1995-05-14 15:23:30 +00:00
leo d3e5e6574b Fix double mapping of stack. 1995-05-14 15:20:22 +00:00
chopps d25d16dd79 fix ITEIOC[GS]BELL and ITEIOCGREPT cases in iteioctl() 1995-05-14 14:26:00 +00:00
chopps d2d8deb3bb make recent cpu_fork() changes more similar with hp300. 1995-05-13 05:57:25 +00:00
chopps 51731ce367 fix dumpmem 1995-05-13 05:17:56 +00:00
jonathan 4175c2819f Redo 3MAX+ (5k/240) interrupt enable code.
Instead of being a no-op, kn03_intr_enable() sets the sw copy of the
interrupt-enable mask *and* writes it into the IO asic intr-enable
register.  Boot code sets the sw copy (kn03_tc_imask) to something
sane (KN03_IM0, with tc option slots turned off).  Tested and works.
Interrupt code for other IOASIC machines should be redone so that
interrupts for devices are enabled by drivers, rather than by
cpu-specific boot code.  Functions common to all IOASIC machines
(PSWARN?) should be done by asic_init().

Checked in without the above changes so that 3MAX+, MAXINE and 3MIN
interrupt-(enable,handle) can converge.
1995-05-12 23:27:23 +00:00
cgd fc90442d14 add lots of vnds 1995-05-12 21:08:41 +00:00
mycroft af73578e82 Map the source page of a copy read-only. 1995-05-12 20:57:22 +00:00
mycroft 76860a15b0 Add a child_return() function to clean up the child's state correctly, and
use this in cpu_fork().  Generalize proc_trampoline() so it can also be used in
this case.
1995-05-12 18:24:46 +00:00
chopps 0cb62c1cb4 added flsc and bzsc. 1995-05-12 13:09:17 +00:00
mycroft 94cb5327ca Stylistic change. 1995-05-12 13:04:33 +00:00
mycroft 46426ac542 main() should never return. 1995-05-12 13:03:23 +00:00
chopps 21d667c8ab scsi drivers for fastlane and blizzard controllers that use the
Emulex FAS216 chip.  from Daniel Widenfalk <t94dwi@student.tdb.uu.se>
1995-05-12 12:59:05 +00:00
mycroft 9877d5d787 Eliminate the double mapping of the kernel stack. Enable swapping. 1995-05-12 12:54:44 +00:00
mycroft 7bf54feda1 Add vnd. 1995-05-12 12:49:54 +00:00
mycroft 3d833a1ab1 Conditionalize the code in process_frame() on the existance of
cpu_set_init_frame().
1995-05-12 12:47:45 +00:00
mycroft c52debae3f Redefine the first part of struct frame to be a struct trapframe, and add a
struct switchframe.
1995-05-12 12:45:24 +00:00
cgd eb4cd26383 from the comments at the top of the file:
INSTALL -- somewhat generic kernel with a snowball's chance of
	   fitting on an install floppy.

This kernel MUST consist (for users' sanity) of a subset of
the GENERIC configuration.  It also should support X reasonably
(though the SysV SHM extensions won't work).

To avoid a maintenance nightmare, this kernel consists of GENERIC
with missing options/devices/etc. REMOVED rather than commented
out.  That makes it easy to diff agains GENERIC, to make sure that
it really is a subset of the functionality.
1995-05-12 03:19:51 +00:00
cgd aeb93da3d7 Split FFS,QUOTA line, comment each individually.
Add 'options INSECURE' so that the GENERIC kernel is happy with
X's linear mapping.
1995-05-12 03:18:05 +00:00
chopps c7b33abd2d enable swapping of process 1995-05-12 00:21:54 +00:00
chopps a15205fdbf use stdframe from m68k/include/frame.h 1995-05-12 00:18:09 +00:00
chopps 4567f74662 add stdframe (4-word frame) 1995-05-12 00:01:05 +00:00
chopps 2526492410 fix typo 1995-05-11 23:49:56 +00:00
chopps 1ba39fdfd1 conditional use of kstack, specifically there is no kstack on the amiga 1995-05-11 23:15:13 +00:00
chopps 35785d310e remove double mapping of kernel stack. created cpu_set_kpc() 1995-05-11 23:04:18 +00:00
chopps b6e35ee17f fix len bug from Jason Thorpe <thorpej@nas.nasa.gov> 1995-05-11 22:55:12 +00:00
jtc 8aa6c376b6 KERNEL -> _KERNEL 1995-05-11 16:52:54 +00:00
christos 078a98c864 Fixed compat hpux files. 1995-05-10 17:02:52 +00:00
pk e01c46144d Minimalist implementation of KIOC[SG]KEY. 1995-05-10 16:04:55 +00:00
leo 7b03e25bf5 Print proper machine type at startup. Use 'vfs_shutdown' to sync the
disks.
1995-05-10 07:07:30 +00:00
leo 9804349e4d Ignore HBL/VBL interrupts instead of reporting them as stray as they
can't be turned off on a Falcon.
1995-05-10 06:33:31 +00:00
leo 18976dc656 Added machine type detection, the presence of the 2nd MFP determines
if the machine is a Falcon or a TT030. The type is added to 'machineid'.
Interrupt  initialisation is now dependend on the machine type.
1995-05-10 05:59:27 +00:00
briggs 725cb78165 Actually probe for 881 vs. 882. Also add a case for 040, although it's
really lip-service at the moment.
1995-05-10 03:19:00 +00:00
phil fae7c89fdd RCS id/header cleanup. 1995-05-08 19:37:45 +00:00
christos 8e536df8d5 Added sunos_machdep.c; from Matthew Green 1995-05-08 19:14:21 +00:00
christos 9d460c41af Added sunos_machdep.c [from Matthew Green] 1995-05-08 19:13:48 +00:00
ragge 7d8ace7679 Typo 1995-05-08 19:10:53 +00:00
pk 530cf06fbb Adapt declaration to stand.h; PR #1036 1995-05-08 18:56:06 +00:00
pk 9ca43d7c14 Remove -I/usr/include from `genassym' line. 1995-05-08 18:02:12 +00:00
mycroft af7265051f The previous optimization only works for edge-triggered interrupts... 1995-05-08 18:00:20 +00:00
pk c9d346c81c Refuse to map addresses in a MMU hole; the process will get a SEGV.
Changed mmu_pagein() interface.
Small nit in mmu_entry.
1995-05-08 17:56:49 +00:00
pk 51082874bf Use VA_INHOLE().
Define arguments to mmu_pagein() in terms of MI VM constants; an idea from Theo.
1995-05-08 17:53:40 +00:00
pk 2a3952abeb implement cpu_swapout() 1995-05-08 17:50:00 +00:00
pk f250262185 #define VA_INHOLE() - to test a VA for being in an MMU hole
(and PG_VSHIFT should 29).
1995-05-08 17:47:26 +00:00
pk 9ef5f62072 Start swapping. 1995-05-08 17:34:20 +00:00
chopps 79d6c6505e fix a few thinkos 1995-05-08 02:52:21 +00:00
chopps 6a9186c322 may now work for asdg boards.. offsets obtained months ago but untestable here 1995-05-08 02:40:51 +00:00
cgd 3ada5aac65 ignore the kernel compile dirs for which we provide config files. 1995-05-07 22:26:16 +00:00
cgd 1c04650195 protect npxproc usage with #if NNPX. From Bob Baron <rvb@cs.cmu.edu>. 1995-05-07 21:07:17 +00:00
chopps e84ef6b4af rm unused local vars 1995-05-07 16:54:51 +00:00
ragge 197ff756b0 Machine dependent core dump struct added. 1995-05-07 16:43:34 +00:00
ragge 9bdf9bed5e Changed core dump style to generic netbsd format. 1995-05-07 16:41:28 +00:00
chopps 2ca98c3cb6 enable pseudo-dma on ivsc, allow no ite/grfcc. 1995-05-07 15:37:02 +00:00
mycroft dbaa7014ef Turn off a debugging printf(). 1995-05-07 03:27:37 +00:00
mycroft 8a50716192 Fix restore of %fs and %gs in linux_sigcode. 1995-05-07 03:16:16 +00:00
mycroft 4e9f66f9ca Improve Linux signal emulation, and emulate the modify_ldt() call. 1995-05-07 02:59:30 +00:00
mycroft 6e02c4b647 Add a copy of the user code and data descriptors in the GDT. 1995-05-06 20:30:14 +00:00
mycroft 5c75c8b7ad Use global definitions of i386_[gs]et_ldt_args. 1995-05-06 19:21:37 +00:00
mycroft 7a69a9c95b Define i386_[gs]et_ldt_args here. 1995-05-06 19:19:57 +00:00
briggs 56b5c26854 Get rid of a printf() that got left behind in the probe. 1995-05-06 18:44:48 +00:00
briggs c4cb3e244c Probe this like the other devices. 1995-05-06 18:33:19 +00:00
mycroft e97a07b5a4 Add stub for linux_modify_ldt(). 1995-05-06 18:17:15 +00:00
ragge 372dd89e62 Kernel message buffer implemented. 1995-05-06 00:08:28 +00:00
mycroft 524c9c7f2a Use nvram.h. 1995-05-05 22:28:17 +00:00
mycroft 8fc6a61adc Add definitions for NVRAM equipment byte. 1995-05-05 22:08:43 +00:00
leo 8b4abb7503 Fix error in handling FPU types. 1995-05-05 16:39:14 +00:00
leo 231b64341e Fix bug on handling HD-floppy's. 1995-05-05 16:38:05 +00:00
leo ec3a1cd9f7 Define dma_drvmode correctly 1995-05-05 16:36:57 +00:00
leo 0d58fa8604 Report "real mem" correctly and make one single module for handling
software interrupts.
1995-05-05 16:35:21 +00:00
leo 0dae8a5da7 Remove some unused defines. 1995-05-05 16:33:11 +00:00
leo 60f4c22869 Shift system clocks from TT-mfp to ST-mfp and remove some dead-code. 1995-05-05 16:31:46 +00:00
leo d64c598f6a Shift system clocks from TT-mfp to ST-mfp for Falcon. 1995-05-05 16:30:33 +00:00
ragge 29a5673f41 BROKEN_SWAP removed, swapping verified OK.
pmap_collect(pmap) added as null define.
1995-05-05 14:13:01 +00:00
ragge bd890814cf Removed cpu_set_init_frame() use.
Increased default limits of memory use, ridiculously small before.
1995-05-05 10:53:53 +00:00
ragge f58eb36f82 Removed kernel stack relocation and double-mapping.
Speeded up fork() significantly.
1995-05-05 10:47:35 +00:00
mellon 214234c937 Fix MAXine interrupt mask routine 1995-05-05 06:48:14 +00:00
briggs 331e2bd82b Add some code/defines to differentiate Asante and Interlan/Gator cards
correctly with the new nubus code.
1995-05-05 05:40:13 +00:00
cgd 8703076975 define BROKEN_SWAP and/or cpu_swapout as appropriate. 1995-05-05 03:41:51 +00:00
mellon 3ff601e7a1 Don't conditionalize utility routines based on DEBUG flag 1995-05-05 02:45:31 +00:00
jonathan 03c9dc7a48 Fix long-standing bug in NetBSD/pmax interrupt initalization on
Turbochannel machines with an IOASIC.

After an interrupt is taken, the IOASIC interrupt enable mask is
and'ed with the kernel's interrupt-mask variable.  This masks
off any interrupts that were enabled after the hardware interrupt-enable
mask was set. Due to this bug all iynterrupts must be enabled before
the first interrupt is taken. (Interrupts enabled later aren't on in the
ioasic intr-mask  register, so they aren't on in (sirm & kernelmask),
which is what used to get written back to the ioasic interrupt-mask
register.  	Fixed, and tested on  on 3MAX+ but not xine/3min.

If this patch perchance breaks on Xines or 3mins, the old code can be
re-enabled by changing the #if 0 in machdep.c to #if 1.
1995-05-04 19:48:41 +00:00
pk 7d244351cf Add `evcnt' field. 1995-05-04 19:43:27 +00:00
pk 089ab8e266 define audio `evcnt' field. 1995-05-04 19:42:36 +00:00
pk 9e61204b61 Tally interrupts. 1995-05-04 19:41:35 +00:00
cgd 2e0e8fc49d use the machine-independent definitions for the mc146818.
wrap the various uses of the chip (including the uses of the NVRAM on it)
around the new defintions, structures, and functions specified in the header.
1995-05-04 19:39:08 +00:00
cgd 7153343684 two cases to quiet the compiler. perhaps should be fixed differently. 1995-05-04 19:35:20 +00:00
mycroft 40b72cc7a2 Wrap NGDT and NLDT in parens. 1995-05-04 05:37:39 +00:00
mycroft 0175317fc3 If we decide to use IRQ 13, explicitly turn off CR0_NE to be sure. 1995-05-04 00:30:56 +00:00
mycroft 94f4346537 Update a comment to match that last change. 1995-05-04 00:20:40 +00:00
mycroft f0a42753e4 npxinit() should not be called during autoconfig now. Watch for this
condition.
1995-05-04 00:16:40 +00:00
mycroft e03a827a0a Move some comments from before npxsave1() to before npxsave(). 1995-05-04 00:00:25 +00:00
mycroft bfef4c14c5 Slight rearrangement, to make the TS handling easier to follow. 1995-05-03 23:09:37 +00:00
mycroft 99224602b4 Only dump the FPU state if the process actually used the FPU. 1995-05-03 23:05:46 +00:00
mycroft d23aebf3bb Fix pccnpollc(). 1995-05-03 20:46:32 +00:00
ragge a412d4803c mtpr support for 11/780 added. DELAY added. mcount() corrected.
trapframe fixed to support all registers.
1995-05-03 19:53:40 +00:00
ragge 35d394d7e4 Changed conf.c to new style. Took away double saving of regs in traps.
Changed boot() to use vfs_shutdown(). Updated setregs.
1995-05-03 19:20:09 +00:00
mycroft 6db4e1b58a By default, don't frob the ICU masks here. The software masking should
be sufficient.
1995-05-03 14:31:35 +00:00
mellon c6a24163a3 Use Alpha cdefs.h 1995-05-03 06:04:54 +00:00
mycroft f57d609a52 Use PCB_USEDFPU, and a small performance tweak. 1995-05-03 00:17:16 +00:00
cgd 66927585fc make an __indr_references macro, that expands to nothing... 1995-05-03 00:13:55 +00:00
mycroft e772f7c5ef Set PCB_USEDFPU. 1995-05-03 00:09:13 +00:00
mycroft 029176e96b Add PCB_USEDFPU. 1995-05-03 00:08:19 +00:00
jonathan 64b99b333d The pmax 3100 interrupt-init code is broken: cpu_startup() enables
interrupts before it calls configure().  On 3100s, this can result in
the ethernet interface interrupting before leprobe() is ever called.
Be a bit more defensive in leintr(), where it was dereferencing a null
pointer.  This reputedly fixes the oft-reported problems of 3100s not
ooting unless they're on an idle net or had a hard reset done before boot.
(Reworking the config code completely would be nice too.)
1995-05-02 20:00:09 +00:00
jonathan be2c7f3d13 If we panic inside trap(), Do a stack traceback before printing the trap log.
Also change the stack-traceback code to avoid having multiple returns
(and thus multiple stack pops) because with gcc -O2 that breaks the
heuristic that a "jr ra" preceding the PC precedes code to push the
current stack frame.  Which breaks stacktrace() before it even
traces past itself :-(.  Use a goto instead.
1995-05-02 19:51:52 +00:00
pk 0c8be3a288 Make sure kbdopen() ships the keyboard reset cmd. 1995-05-02 07:56:42 +00:00
leo 176d4dd6e5 Added -T option. 1995-05-02 05:54:28 +00:00
mycroft 73fead01fc Fix typos. 1995-05-01 19:45:42 +00:00
mellon edab8dc1d9 Oops, took out a bit too much 1995-05-01 17:35:45 +00:00
mellon 7bada980a5 Oops. Undo some console code checkins that didn't belong. 1995-05-01 17:22:20 +00:00
mycroft 88f28c3996 Fix typo. 1995-05-01 14:19:14 +00:00
mycroft 8792c8e284 Save and restore %fs and %gs across signals. 1995-05-01 14:15:07 +00:00
mycroft 4eea138a48 Add sc_gs and sc_fs. Move sc_onstack and sc_mask to end. 1995-05-01 14:14:11 +00:00
pk c78dd5a369 New location & definitions for audio driver. 1995-05-01 14:13:45 +00:00
mycroft bbfcbb8483 Add VM86 segment registers to trapframe. 1995-05-01 14:13:26 +00:00
mycroft cef0c43dee Stylistic changes, and we don't need KERNEL any more. 1995-05-01 13:16:16 +00:00
mycroft c55ef2fd64 Always reload the LDT iff we reallocated its storage. 1995-05-01 13:13:20 +00:00
mycroft 953e339aa0 Stylistic changes tp cpu_exit(). 1995-05-01 13:09:43 +00:00
mycroft f745c10020 Eliminate _gsel_tss and _default_ldt. 1995-05-01 13:02:24 +00:00
mycroft e5d7ebde66 Update to match include files. 1995-05-01 11:07:40 +00:00
mycroft 0ea347bf51 Update for changes in segments.h. 1995-05-01 10:43:01 +00:00
mycroft bce8e94dd2 Correct comments in gdt_segs[] and ldt_segs[] initializers. 1995-05-01 09:08:27 +00:00
mycroft 5d17674312 Remove IdlePTD. 1995-05-01 08:53:13 +00:00
mycroft 87b25c7f5c Update to match include files. Eliminate _ucodesel, _udatasel, and IdlePTD. 1995-05-01 08:25:30 +00:00
mycroft ae11bd216c Remove historical garbage. 1995-05-01 08:14:25 +00:00
mycroft 17dd9534bf Update to match include files. Eliminate _ucodesel, _udatasel, and IdlePTD. 1995-05-01 08:06:22 +00:00
mycroft 5a7e987371 Make md_regs a pointer to a trapframe. 1995-05-01 07:56:20 +00:00
mycroft f32276958e Use segments.h, and some other cleanup. 1995-05-01 07:55:21 +00:00
mycroft 33e0286648 Remove PCB_SAVEFPU. 1995-05-01 07:55:04 +00:00
mycroft 8b51849f9d Make this includable from locore. Remove unused GDT and LDT slots. 1995-05-01 07:37:43 +00:00
mycroft c2e46efab2 Rename ibcs2_sigflags to __spare, but leave the space for now. 1995-05-01 04:53:24 +00:00
mycroft 7688f4456e Remove usages of ibcs_sigflags. 1995-05-01 04:50:28 +00:00
mycroft 92e9818c88 Expose idt[] here. 1995-05-01 04:49:51 +00:00
mycroft b8d3de2758 Add pcb_cr0. 1995-05-01 04:49:28 +00:00
mycroft 17a5f987ba Be more aggressive about lazy saving and initialization. 1995-05-01 04:47:43 +00:00
mycroft f55c4a0a19 Another trivial optimization. 1995-05-01 01:24:04 +00:00
briggs 34e5f975f9 Don't set mrg vectors if we're using the serial console--this allows
machines w/ non-working desktop bus to actually get on with booting.
1995-04-30 17:01:06 +00:00
leo 58cd4c0a1d Get 68040 defines in line with other 68k ports so libkvm/kvm_m68k.c compiles
cleanly.
1995-04-30 14:02:12 +00:00
leo f677a89489 Small changes in dma locking code. 1995-04-30 12:06:01 +00:00
leo 12c60f7bc0 Complete rewrite, made necessary because Falcon SCSI needs to share
NCR5380 and DMA access with floppy.
1995-04-30 12:04:48 +00:00
leo e95337c226 Added lock status bits, update function prototypes. 1995-04-30 12:02:03 +00:00
leo fb4939eddf Moved softint definitions still in cpu.h into mtpr.h and did some minor
cleanups.
1995-04-30 12:00:31 +00:00
leo 8996e3866b - Move softint definitions to mtpr.h
- Add flags for TT/Falcon model for machineid, we definitely need them
1995-04-30 11:56:22 +00:00
cgd 4d059559f7 resurrect, and move files.pmax.newconf to new location. 1995-04-30 10:11:00 +00:00
cgd 9b7c37148b new-config files list. missed this yesterday. 1995-04-30 02:44:44 +00:00
jonathan fb9f07db36 Update MIPS stack backtrace code to trace through locore functions,
traps, and interrupts  The earlier (4.4bsd) code didn't do the first two, and
got the last one wrong.  Also print some functions (e.g., trap handlers)
by name.  Add hook to use something other than printf() as the output
function, e.g,. for kernel debugging.
Tested with the `native' toolset, but not ELF format kernels.
(i.e., unwinding the $GP register is not tested.)

The stack backtrace code that interprets and unwinds stackframes is still
opaque and stylistically awkward.
1995-04-29 21:10:31 +00:00