Commit Graph

331 Commits

Author SHA1 Message Date
ache
7f3ca7c540 Move soundcard.h & ultrasound.h to proper location <machine/...>
to allow application access it.
1993-11-27 22:16:44 +00:00
wollman
13557bc52a Declare cnopen, cnclose, and other console routines. 1993-11-27 19:19:19 +00:00
rich
37c59cbda9 Declared cn{open,close,read,write,ioctl,select} extern. 1993-11-27 06:50:45 +00:00
rich
47ffcbfe51 Fix conflicting prototypes and return values. 1993-11-27 06:32:41 +00:00
wollman
425f3e1671 Fix d_write_t -> d_rdwr_t (typing error). 1993-11-26 22:44:17 +00:00
dg
1d18814c41 Patch from Julian Elischer:
Here is the fix for the 'hanging' bug.

This bug happenned whenever two operations were already underway on the
disk and a third (non-IO) command was requested..
in this case the process submitting the NON-IO command was requested to wait,
and a flag set so that on completion of the IO commands, the Non-io command
was given priority over any pending IO commands. (the queue is not
allowed to drain while there are pending "special" ops).

The flag that indicated this was not being reset, so further IO commands
were prohibited from that moment on.
1993-11-25 06:30:58 +00:00
wollman
8e24073a9b Make the LINT kernel compile with -W -Wreturn-type -Wcomment -Werror, and
add same (sans -Werror) to Makefile for future compilations.
1993-11-25 01:38:01 +00:00
nate
0d2bf2f9ed Subject: Panic - can't mount route (Soren's changes)
From: Geoff Rehmet  <g89r4222@braae.ru.ac.za>

Description:
	On bootup, probe of wd drives fails (CP30104), and kernel panics
	- cannot mount root
	It appears that the device probe just times out.
	Increasing the timeout back to its old value fixes the problem.
Repeat-By:
	SUP FreBSD-current,  Find a CP30104 .....  (ok ok ok)
	Basically - Soren's changes barf my disk.
1993-11-23 21:36:37 +00:00
chmr
5bd9041020 Changed return(-1) in switch_scr to return(EINVAL), because -1 is
ERESTART on return from a system call.
1993-11-23 18:20:52 +00:00
nate
73aab54861 Stop gap measure until we can get Bruce's driver debugged.
---
From: sos@login.dkuug.dk (S|ren Schmidt)
Subject: IDE-disk hangs - solution/patches NetBSD/FreeBSD
Summary: fixes for lost interrupts with IDE disks
Keywords: hanging-disk, IDE-disk, lost-interrupt


Due to "popular" demand I'm posting these patches to NetBSD/FreeBSD
instead of mailing them around the world :-)

As many have found out there is a problem when using IDE disks on
FreeBSD. Following is a patch that fixes the problem with lost intterrupts.
Both fixes is based on a patch posted here some month ago by
Stefan Behrens?? (sorry I've lost the original article). But anyway it
works (for me :-).
Basically it does a timeout on lost interrupts, starting the operation
again and logging and error message on the console.

It additionally makes the allready present while loop timeouts
independent of CPU speed, and adds minor numbers for easy access to
dos partitions.
1993-11-22 23:25:46 +00:00
dg
b19cf9d9a8 * Revision 2.14 1993/11/22 10:55:30 davidg
* change all splnet's to splimp's
 *
 * Revision 2.13  1993/11/22  10:53:52  davidg
 * patch to add support for SMC8216 (Elite-Ultra) boards
 * from Glen H. Lowe
 *
 * Revision 2.12  1993/11/07  18:04:13  davidg
 * fix from Garrett Wollman:
 * add a return(0) at the end of ed_probe so that if the various device
 * specific probes fail that we just don't fall of the end of the function.
1993-11-22 11:08:16 +00:00
dg
ac967db637 patches from Julian Elischer -
Added support for mmapping /dev/mem
1993-11-22 09:46:45 +00:00
dg
94bb597ccc added 5us delay before checking BUSY flag to conform to ATA spec -
as suggested by John Dyson (dyson@implode.rain.com)
1993-11-19 06:30:00 +00:00
rgrimes
73dd2628a2 New version of scsi code from Julian 1993-11-18 05:03:27 +00:00
wollman
6738caeaa0 Fixed comments. 1993-11-18 00:12:13 +00:00
ache
8d34e09677 Fix attach message, make separate line for it
(old version assumed that line is probe line)
1993-11-17 23:38:23 +00:00
wollman
029f1ccc6f Fixed comments that start within a comment, so code compiles cleanly with
-Wcomment.
1993-11-17 23:25:28 +00:00
wollman
1ae9954219 Increased symtab space and added two more options that don't do anything
(yet).
1993-11-17 23:24:12 +00:00
ache
3dd806470c If netmask == 0, new value changed from 0x8000 to 0x10000
(don't mess with IRQ15)
1993-11-17 00:21:03 +00:00
dg
156d1cd94a new process tracing code from Sean Eric Fagen (sef@kithrup.com).
...also, fixed up the syscall args to make GCC happy.
1993-11-16 09:54:57 +00:00
ache
cf434a6bef We don't want shared boot, so -Bstatic added to ld options 1993-11-16 02:02:05 +00:00
paul
53f348b4ef Changed -Z back to -z.
In line with all other ld's -z is now the "standard" ZMAGIC format.
1993-11-16 00:45:04 +00:00
paul
4d25c340ff Changed -z to -Z so we create old-style ZMAGIC kernels. 1993-11-15 21:06:08 +00:00
ache
142d081759 timeout+sleep changed to tsleep 1993-11-15 01:33:11 +00:00
ache
bfbb9f451b if netmask == 0, then the loopback code can do some really
bad things.
workaround for this: if netmask == 0, set it to 0x8000,
which is value used by splsoftclock
1993-11-14 23:53:32 +00:00
ache
3e31049377 New sio driver from Bruce. 1993-11-14 23:29:01 +00:00
rgrimes
3593da9033 Add _bde_exists: label so that the global is really defined. Fix spelling
error (mount -> amount)
1993-11-14 02:27:22 +00:00
rgrimes
93f6cc5abd >From Charles Hannum
Change movl %es: -2(reg) to use a subl $2,reg when fixing up the IDT
entries for bdb.  This seems to be the best way to go.

Some day soon #ifdef BDB all of Bruces debugger code.
1993-11-13 04:43:25 +00:00
dg
aa3ae6ef2a First steps in rewriting locore.s, and making info useful
when the machine panics.

i386/i386/locore.s:
1) got rid of most .set directives that were being used like
	#define's, and replaced them with appropriate #define's in
	the appropriate header files (accessed via genassym).
2) added comments to header inclusions and global definitions,
	and global variables
3) replaced some hardcoded constants with cpp defines (such as
	PDESIZE and others)
4) aligned all comments to the same column to make them easier to
	read
5) moved macro definitions for ENTRY, ALIGN, NOP, etc. to
	/sys/i386/include/asmacros.h
6) added #ifdef BDE_DEBUGGER around all of Bruce's debugger code
7) added new global '_KERNend' to store last location+1 of kernel
8) cleaned up zeroing of bss so that only bss is zeroed
9) fix zeroing of page tables so that it really does zero them all
	- not just if they follow the bss.
10) rewrote page table initialization code so that 1) works correctly
	and 2) write protects the kernel text by default
11) properly initialize the kernel page directory, upages, p0stack PT,
	and page tables. The previous scheme was more than a bit
	screwy.
12) change allocation of virtual area of IO hole so that it is
	fixed at KERNBASE + 0xa0000. The previous scheme put it
	right after the kernel page tables and then later expected
	it to be at KERNBASE +0xa0000
13) change multiple bogus settings of user read/write of various
	areas of kernel VM - including the IO hole; we should never
	be accessing the IO hole in user mode through the kernel
	page tables
14) split kernel support routines such as bcopy, bzero, copyin,
	copyout, etc. into a seperate file 'support.s'
15) split swtch and related routines into a seperate 'swtch.s'
16) split routines related to traps, syscalls, and interrupts
	into a seperate file 'exception.s'
17) remove some unused global variables from locore that got
	inserted by Garrett when he pulled them out of some .h
	files.

i386/isa/icu.s:
1) clean up global variable declarations
2) move in declaration of astpending and netisr

i386/i386/pmap.c:
1) fix calculation of virtual_avail. It previously was calculated
	to be right in the middle of the kernel page tables - not
	a good place to start allocating kernel VM.
2) properly allocate kernel page dir/tables etc out of kernel map
	- previously only took out 2 pages.

i386/i386/machdep.c:
1) modify boot() to print a warning that the system will reboot in
	PANIC_REBOOT_WAIT_TIME amount of seconds, and let the user
	abort with a key on the console. The machine will wait for
	ever if a key is typed before the reboot. The default is
	15 seconds, but can be set to 0 to mean don't wait at all,
	-1 to mean wait forever, or any positive value to wait for
	that many seconds.
2) print "Rebooting..." just before doing it.

kern/subr_prf.c:
1) remove PANICWAIT as it is deprecated by the change to machdep.c

i386/i386/trap.c:
1) add table of trap type strings and use it to print a real trap/
	panic message rather than just a number. Lot's of work to
	be done here, but this is the first step. Symbolic traceback
	is in the TODO.

i386/i386/Makefile.i386:
1) add support in to build support.s, exception.s and swtch.s

...and various changes to various header files to make all of the
	above happen.
1993-11-13 02:25:21 +00:00
ache
76098db5b5 Fixed minor bug in M[LSN] interpretation, added octave-tracking.
Added the slur-mark feature.
Name of ioctl's include sys/spkr.h changed to machine/speaker.h
1993-11-09 02:32:30 +00:00
ache
788ea3fcac Name of ioctl's include sys/spkr.h changed to machine/speaker.h 1993-11-09 02:31:53 +00:00
alm
46df0965e7 Applied David Greenman's hack to disable IRQ conflict checking
when COM_MULTIPORT is defined.
1993-11-09 02:12:36 +00:00
jkh
79a69c41f4 Change from David Greenman to return properly unsigned irq. 1993-11-09 01:20:33 +00:00
ache
5a7a2e36f5 Add missing read flush code to siostop 1993-11-08 19:36:32 +00:00
rgrimes
319a187e56 Increase timeout in sd_start_unit procedure from 2000 to 6000, per Adam David 1993-11-08 12:11:01 +00:00
wollman
4e9765d815 Added the netrmp protocol from the Net/2 tape. While of dubious utility,
it's simple enough that it might actually work and be useful on some systems.
(That's more than you can say for netccitt or netimp!)
1993-11-07 22:54:51 +00:00
wollman
d2ef484c3d Get rid of WFJ's use of sleep() for more user-friendly tsleep(). 1993-11-07 21:47:19 +00:00
wollman
1ee55cfc6a Add options MACHVMCOMPAT and bump symtab space appropriately. 1993-11-07 21:46:25 +00:00
wollman
6701461a9a Made all header files idempotent and moved incorrect common data from
headers into a related source file.
Deleted some very old device-specific headers for devices that we don't
support and likely never will.
1993-11-07 17:52:59 +00:00
wollman
2aba23834f Made all header files idempotent and moved incorrect common data from
headers into a related source file.
1993-11-07 17:51:34 +00:00
wollman
bd2b2815f2 Made all header files idempotent and moved incorrect common data from
headers into a related source file.  Also fixed a bug in ed_probe() where
it was possible to fall off the end of the function
1993-11-07 17:44:34 +00:00
wollman
371ee40cea Made all header files idempotent and moved incorrect common data from
headers into a related source file.  Added cons.h as first step towards
moving i386/i386/cons.h to machine/cons.h where it belongs.
1993-11-07 17:43:17 +00:00
wollman
c1b92d6bad Made all header files idempotent and moved incorrect common data from
headers into a related source file.  (This is the only change to locore.s).
Also fixed pg() to be properly declared and use stdargs.
1993-11-07 17:41:36 +00:00
wollman
facbbe496c Fixed comment. 1993-11-07 17:40:05 +00:00
wollman
f76e5f0160 Make all headers idempotent. All incorrect common data moved out of header
files and into a related source file.
1993-11-07 17:39:25 +00:00
wollman
e31f27fb90 Try to be a little smarter about touching the date on assym.s, so that
if something changes which doesn't affect it, locore doesn't have to get
rebuilt.  This is at the cost of a genassym and a cmp in every compile,
until someone can figure out how to make `make' smarter itself.
1993-11-07 16:46:33 +00:00
wollman
3895123653 Added some more defines that weren't there before. Also bumped up
symtab space again.
1993-11-07 16:44:40 +00:00
wollman
c3e07d8db4 Needed to bump up SYMTAB_SPACE again. (This really should be done by the
boot loader...)
1993-11-07 05:26:17 +00:00
wollman
4b075d2d89 Added CWARNFLAGS and COPTFLAGS defines to Makefile so that we can easily
test various warning and optimization compiler flags without modifying the
Makefile. (From my patch set.)
1993-11-07 04:41:11 +00:00
dg
89898c034b splnone()'s in the trap code can be deadly. Save/restore previous priority
instead.
1993-11-04 15:05:41 +00:00