1) tty.c: gather all the info about the processes before calling ttyprintf
(which may block).
2) syscons.c: handle asynchronous output properly (data structures may
be corrupted otherwise).
Example:
Application use port cua01
Getty open ttyd1 (allocates rawq,outq,etc) and waits while application
done
Application quits, sioclose issued, ttyfree issued (getty calls revoke)
Getty awakes and goes to panic into initrb (NULL rawq)
a zero cylinder and/or head count, set them and the sector count
to some fictious values. The same already happens if the request
sense is unsuccessfull.
1) A new mechanism has been added to prevent pages from being paged
out called "vm_page_hold". Similar to vm_page_wire, but
much lower overhead.
2) Scheduling algorithm has been changed to improve interactive
performance.
3) Paging algorithm improved.
4) Some vnode and swap pager bugs fixed.
now HUPCL set only in bidir case for callin lines
(this prevents set HUPCL on mouse)
comhardclose:
in addition to HUPCL case now DTR dropped for bidir case
if line was active in and no carrier present now.
(this prevents DTR sleep on mouse)
Subject: Re: Bugs with floppy drives
Date: Tue, 8 Mar 94 9:11:54 CST
The transfer speed was only set in the retry after error, not when
switching drives.
Eliminates vm_fault overhead on process startup and
mmap referenced data for in-memory pages.
(process startup time using in-memory segments *much* faster)
2) Even more efficient pmap code. Code partially cleaned up.
More comments yet to follow.
(generally more efficient pte management)
3) Pageout clustering ( in addition to the FreeBSD V1.1 pagein
clustering.)
(much faster paging performance on non-write behind disk
subsystems, slightly faster performance on other systems.)
4) Slightly changed vm_pageout code for more efficiency and
better statistics. Also, resist swapout a little more.
(less likely to pageout a recently used page)
5) Slight improvement to the page table page trap efficiency.
(generally faster system VM fault performance)
6) Defer creation of unnamed anonymous regions pager until needed.
(speeds up shared memory bss creation)
7) Remove possible deadlock from swap_pager initialization.
8) Enhanced procfs to provide "vminfo" about vm objects and user
pmaps.
9) Increased MCLSHIFT/MCLBYTES from 2K to 4K to improve net &
socket performance and to prepare for things to come.
John Dyson
dyson@implode.root.com
David Greenman
davidg@root.com
it still looks a little suspicious that so many of the status codes are missing
so I'm not going to adopt all of the existing ones yet. Try to be more
descriptive in the use of hex constants.
Changes _only_ take effect if `options LAPTOP' is set.
Note: This one is distinctly dodgy. When my IDE drive spins back up from sleep
mode, it generates this `extra interrupt' condition by spinning back up and
generating an intr, though without any particular action required. This
message coming out every time is rather annoying, and thus disabled.
However, what I'm not at all sure of is whether or not all IDE drives will
behave in the same way, or if perhaps it needs to be done in a more complicated
fashion by detecting this more involved "I've spun up and am just saying hi"
condition. This is a simple change and easy to back out/ammend if anybody has
any better ideas.
hack in the moment for testing purposes and to get the drive going
again.
0x20 means empty drive.
0x30 means closed drive with CDROM inserted.
0x80 means drive pulled out, but door closed.
0xa0 means drive pulled out and door open.
Luckily none of these values are the same as that reported for Ethernet
cards ( 0 for WD8003E, 0x40 for WD8013EPC, 0x60 for NE2000).
The bad part is, the probe code gets the WD8003E so hosed, that it is
no longer usable after it. No problem with the WD8013EPC.
my previous fix too (using wdp_heads controller value) and check
0 heads case too.
Other fixes from Bruce:
2) Fix dk_timeout from 2 to about 4 seconds.
3) wdcontrol not retried on internal error.
4) wdwait return check changed ( "!=0" to "<0" into wdsetctlr,
"<0" to "!=0" into wdgetctlr).
This inetrface should be used from now on.
pseudo device pty xx still keeps its meaning: a maximum of
xx ptys is allowed.
A ringbuffer is now 2040 bytes long, per Garrett Wollman's request.
The changes are inspired by the way NetBSD did it (thanks for that!),
though I made it slihghtly different, including the interface so
at least 75% of the allocated space is deallocated when the tty is
closed.
Note further that it is easy to modify the ringbuffer length runtime.
This will have to wait untill some later date...
-Guido
This inetrface should be used from now on.
pseudo device pty xx still keeps its meaning: a maximum of
xx ptys is allowed.
A ringbuffer is now 2040 bytes long, per Garrett Wollman's request.
The changes are inspired by the way NetBSD did it (thanks for that!),
though I made it slihghtly different, including the interface so
at least 75% of the allocated space is deallocated when the tty is
closed.
Note further that it is easy to modify the ringbuffer length runtime.
This will have to wait untill some later date...
-Guido
>From: bde@kralizec.zeta.org.au (Bruce Evans)
Subject: cache botch in bootstrap
Date: Sun, 20 Feb 94 18:14:35 +1100
The cache in the bootstrap loader didn't allow for the device changing.
This caused surprisingly little trouble - the cache is only for a single
track (or part of a track), and the first access to a new device is
always for an early sector, so there is no problem unless the last access
to the old device was for an early sector. I saw the problem on a system
with BSD on wd1 and no label on wd0. Everything worked if the the device
name wd(1,a) was specified before the default of wd(0,a) was tried, but
when the default was tried, it failed on the first sector because there
was no label, and then the first sector on wd0 was always used instead
of the first sector on wd1, so there was apparently no label on wd1
either.
Bruce
Subject: Bugfix for SB16 with DSP version 4 and above
No description sent, but it appears to fix a major number problem
with certain models of the SB16.
Small hack, if heads > 16, output a warning and then set the head
count to 16. This stops the infinite loop on this error and allows
people to later fix the DOS parameter table later with fdisk.
run Exabyte 8505 on 1742's. This may not be the final solution, but it
makes it work. It may be better to change the DELAY(10) to DELAY(30)
inside the loop instead of increasing the loop count from 100 to 300.
Subject: Bug Fix for ft.c - please commit
Date: Mon, 14 Feb 94 10:22:54 CST
This fixes a bug where the system can crash if the tape is used
after the floppy has been used.
idea considering the old version (but I haven't time for attic surgery - this
is just a caution). This is part of (and the major reason for) the new ld
changes.
a pv chain was being traversed while interrupts were
fully enabled in pmap_remove_all ... this is bogus, and
has been fixed in pmap.c. (sorry for adding the splimp)
Description:
The integer overflow instruction (into) and the interrupt instruction with
value 4 (int #4) both give rise to SIGBUS signals rather than SIGFPE. The
problem is that overflow is a trap not a fault (unlike the BOUND instruction).
>From: Adam David <adam@veda.is>
Subject: SCSI timeout in sdopen()
Date: Sun, 6 Feb 1994 21:40:48 GMT
Index: sys FreeBSD-current
Reference: FreeBSD-current/sys/9
Description:
sdopen() times out on slow SCSI devices. This code was moved into
a different file, which might explain why it got missed again.
Repeat-By:
using slow SCSI disks
When the keyboard is probed, the LED's blink quickly and
"Keyboard reset failed" is printed on the console. The
init routine keeps trying endlessly with the same behavior
as above.
I got the latest -current sup sources (06-Feb-94 12:00 GMT) to work using the
old syscons.c. The following patch makes the new syscons work:
2) Make SNAKE_SAVER like default, if no saver specified in "options"
3) Remove #ifdef STAR_SAVER before line /* make screensaver happy */
this code needed in any case.
Subject: syscons-1.3
Date: Sat, 29 Jan 94 23:33:50 MET
But here is the (hopefully) final syscons-1.3....
....
I've changed sgetc so it works as the pccons parallel
(it now uses a scgetc internally).
[
There were a couple changes that Bruce Evans sent me that were applied
to this version along with some changes that S'ren didn't incorporate
into the final version. There will be only minor changes if anything
from this version to his final release.
]
o merged and fixed timeout code from sos.
o merged DOS partition support from sos.
o fixed "extra" interrupts.
o check if malloc retuns NULL :-(.
o print drive size as in NetBSD
o after an error, return the residual count, not 0.
o give up early for > 16 heads.
o cleaned up the old-drive detection in wdgetctlr().
o rewrote wddump(). I'd been putting this off because
I'd had the dump disabled since 0.0 and had no idea
if even the standard version worked. It didn't:
(0) syscons' sgetc() interface broke some keyboard
stuff.
(1) CADDR1 is mapped using pmap() and pmap got a NULL
pointer trap (at least when I got to wddump() using
call diediedie from ddb) because the pte for CADDR1
is only supposed to be hacked on directly (e.g. in
physcopyseg()).
(2) bad144 handling was not done.
(3) it was slooow (3600 sectors/minute) because my
controller doesn't cache writes.
o miscellaneous other cleanups, e.g., removed scattered
patchkit/terry dates.
o lots of reformatting.
To be done:
o Merge/fix TIH/NetBSD bad144 code (doesn't belong in any
particular driver. Why aren't we using i386/dkbad.c?).
o Merge/fix Dyson/NetBSD clustering code (large parts
should be shared).
o Fix/extend the partition in use bits. Support extended
partitions. This should be shared by all disk drivers. Swap
to a DOS partition so that the swap space can be shared with
linux.
o Don't use polling except for initialization. Need to
reorganise the state machine. Then "extra" interrupts
shouldn't happen (except maybe one for initialization).
o Fix disklabel, boot and driver inconsistencies with
bad144 in standard versions.
o Look at latest linux clustering methods. Our disksort()
gets in the way of clustering.
o cleaned up the ATA changes (needs more work. I think
the ATA specs say that the only thing really wrong with
the original version of wx is that there was no test
for drive-ready before some commands. 400 nsec delay
suffices for almost everything and 400 nsec delay is
usually "free").
netmask or impmask.
2) Fixes from Bruce:
o Changed name of schedsoftcom() to setsofttty() to match
setsoftclock()
o Bool_t isn't used.
o tx_fifo_size is 1 for chips without fifos, 16 for 16550's, to
help to output more efficiently for 16550's (LSR_TXRDY means
that the fifo is empty, not that it has space for one char).
o Changed name of softsio1() to siopoll() and merged compoll()
into siopoll().
o The probe forgot to clear com_mcr after it failed. This is
harmful for 4 single serial ports on 2 interrupts. It makes
partial misconfigurations worse.
o Don't bother initializing static variables that are 0 (bidir
stuff).
o Only initialize t_oflag to TTYDEF_OFLAG if unit == COMCONSOLE,
not if COMCONSOLE is defined.
o Don't call siointr() from comparam() if there is no output in
progress. For the call from sioopen(), there's no output in
progress, and siointr() often saw silo overflows for stale
input because it was called before sioopen() discarded the
input.
o Let ttselect() do the work for select(), so that the fixes for
ttselect() don't have to be duplicated in zillions of drivers.
Yes, I know that IFADDR ioctl is supposed to be deprecated... Note
that the patch was modified by me to fit better into the driver. -DG
...
While porting CAP to 386bsd/pk0.2.4 and now to FreeBSD Release 1.0
I found a couple of bugs associated with the packet filter. Here
are the fixes. I'm posting them here because they apply to
FreeBSD and 386bsd/pk0.2.4 and possibly to other *BSD.
The first occurs when using the packet filter to write raw
ethernet packets. The header consisting of the sender and
destination addresses and the protocol is removed and later
added back on, but with the byte order of the protocol reversed.
The fix ensures that the byte order in the protocol field is
swapped when it is removed.
The second fix ensures that SIOCGIFADDR works for BPF as claimed
in the man pages, by adding it to the ed driver. Similar fixes
will be needed for other ethernet drivers.
Dave Matthews.
file override to disable fifo on 16550s:
I bought a board with two 16550's, but one of those ports has a mouse
on it. The sio driver always enables the fifo, which is a bad thing
for mice and X. The mouse is jerky and hard to use. The simple thing
is be to treat one of the ports as a non-fifo'ed UART, and I use the
flags option in my config file.
So, my config file has:
device sio0 at isa? port "IO_COM1" tty irq 4 flags 0x2 vector siointr
device sio1 at isa? port "IO_COM2" tty irq 3 vector siointr
(patch deleted)
following is a summary:
1) increased object cache back up to a more reasonable value.
2) removed old & bogus cruft from machdep.c (clearseg, copyseg,
physcopyseg, etc).
3) inlined many functions in pmap.c
4) changed "load_cr3(rcr3())" into tlbflush() and made tlbflush inline
assembly.
5) changed the way that modified pages are tracked - now vm_page struct
is kept updated directly - no more scanning page tables.
6) removed lots of unnecessary spl's
7) removed old unused functions from pmap.c
8) removed all use of page_size, page_shift, page_mask variables - replaced
with PAGE_ constants.
9) moved trunc/round_page, atop, ptoa, out of vm_param.h and into i386/
include/param.h, and optimized them.
10) numerous changes to sys/vm/ swap_pager, vnode_pager, pageout, fault
code to improve performance. LRU algorithm modified to be more
effective, read ahead/behind values tuned for better performance,
etc, etc...
cd.c:
Initialize channel info in CDIOCSETVOL ioctl.
Correct CDIOCSTOP and CDIOCEJCET ioctls to use scsi_stop_unit
instead of scsi_start_unit.
Add CDIOCALLOW and CDIOCPREVENT ioctls.
ch.h:
Return EBUSY instead of ENXIO if the device is already in use.
scsi_base.c:
Add scsi_stop_unit routine.
sd.c:
Add mising indirection through sc_link to sd_get_parms routine
when checking for media loaded.
st.c:
Return EBUSY instead of ENXIO if the device is already in use.
Clear the SDEV_WAITING flag in ststart if we do the wakeup call.
Cuddle { braces up where possible on if statements
Add missing splx(s) calls before some returns.
Remove extra semicolon that was keeping uha_init from returning
before the timeout occured. This should speed probing up quite
a bit!
0) FreeBSD additional include files additions
1) Rod's arpacom changes
2) Function type and return code cleanup, and all functions have correct
casting to the correct data types
3) Bugfix where driver would not function due to missing structure not
given a value.
4) General cleanup. (Theo did a lot already, I just did some more)
Removed com port comments, since we are about to depricate the driver.
Fix several plaes in LINT where people have been cutting and pasting using
xterms :-(
the device close routine. This works because the device close calls
the line discipline close (which only flushes the output buffers) and
the ttyclose() routine, which does little of nothing except screw with
the session and process group fields (which is what was causing all
the problems).
Date: Mon, 17 Jan 94 20:52:14 PST
As reported on the -bugs list by some one, and confirmed by Julian:
> I increased AHA_RESET_TIMEOUT in aha1542.c from 1000 to 10000
> and now my 1542C is found everytime.
problem with some chipsets (UMC) remapping the 'hole' memory even when
you've got 16MB. People were led to believe that since there was only
16MB of memory in the machine, that they were okay wrt the ISA DMA
limit. This hack simply causes the extra memory to be ignored if it
appears around the 16MB limit.
* Removed pmap_is_wired
* added extra cli/sti protection in idle (swtch.s)
* slight code improvement in trap.c
* added lots of comments
* improved paging and other algorithms in VM system
Changed the output of the isa probe routine, that only devices, that
have an IO address and are smaller than 0x100 to be on the motherboard.
The seagate SCSI adapter is an example of a card, that doesn't have
an IO address and works only memory mapped.
Choose older MULTIPORT version, because lastest bde version
not worked.
Don't force HUPCL for bidirectional case.
From bde:
Use bit (1 << (16 + 4)) in schedsoftcom() to avoid clash with
non-serial h/w on IRQ4.
Allow FIFO_TRIGGER in config.
Clear com->mcr_image when clearing mcr for init of 4port. The
usual value MCR_IENABLE should have broken 4ports unless
something happened to clear it later.
Turn off interrupts as well as DTR after an error waiting for
carrier (bidir dialin case).
Drain fifo more carefully.
Don't hang up if debugging.
Rearrange siointr() -> siointr1() for multiport case for speed,
lower latency and clarity.
Use suser() to check perms.
Provide missing splx() after failed perms checks.
c_ispeed == 0 means c_ispeed = c_ospeed (POSIX).
Set parameters (except speed) for c_ospeed == 0 as well as
hanging up.
Better initialization for console (fifo stuff...).
Misc. cleanups.
Fix dead hang if modem power is off.
problems in the moment are stray intr's in the ifconfig up/down.
No way to select all three interfaces on a combo card with
AUI/BNC/UTP interfaces and the performance doesn't look good.
Only tested with a ISA AUI/BNC card yet.
Added it to the list of known boards and put it into the the list for
the mailbox unlock. Maybe all board-ids over 0x42 should be in the
mailbox unlock part ?
enough tests to be considered more stable than current driver.
Lots of work by Bruce, David G., and Guido have gone into this version, and
more is to come in the future.
Support for multiple controllers is in, but doesn't work correctly with
different controllers (IDE AND MFM), but multiple alike controllers appears
to work.
Most of the stray interrupts problems should be fixed, although you will
get a couple 'extra interrupts' when disklabeling and on startup.
set improves performance and fixes the following problems (description
from John Dyson):
1. Growing swap space problem in both static usage and
in situations with lots of fork/execs in heavy paging
situations.
2. Sparse swap space allocation (internal fragmentation.)
3. General swap_pager slowness.
Additionally, the new swap_pager also provides hooks for multi-page
I/O that is currently being developed (in early testing phases.)
Problem #1 is a result of a problem where objects cannot be collapsed
once a pager has been allocated for them. This problem has been solved
by relaxing the restriction by allowing the pages contained in a shadow
object's pager be copied to the parent object's pager. The copy is
afforded by manipulating pointers to the disk blocks on the swap space.
Since an improved swap_pager has already been developed with the data
structures to support the copy operation, this new swap_pager has been
introduced. Also, shadow object bypass in the collapse code has been
enhanced to support checking for pages on disk. The vm_pageout daemon
has also been modified to defer creation of an object's pager when the
object's shadow is paging. This allows efficient immediate collapsing
of a shadow into a parent object under many circumstances without the
creation of an intermediate pager.
Problem #2 is solved by the allocation data structures and algorithms
in the new swap_pager. Additionally, a newer version of this new swap_pager
is being tested that permits multiple page I/O and mitigation of the
fragmentation problems associated with allocation of large contiguous blocks
of swap space.
Problem #3 is addressed by better algorithms and a fix of a couple of bugs
in the swap_pager. Additionally, this new pager has a growth path allowing
multi-page inputs from disk. Approximately 50% performance improvement can
be expected under certain circumstances when using this pager in the standard
single page mode.
(Actually, I've seen more like twice the speed in my tests. -DLG)
can actually write a sane netif device to support one of these. Note that it
was necessary to steal a netisr bit from another protocol; I took the one for
PF_DATAKIT (no great loss).
a binary link-kit. Make all non-optional options (pagers, procfs) standard,
and update LINT to reflect new symtab requirements.
NB: -Wtraditional will henceforth be forgotten. This editing pass was
primarily intended to detect any constructions where the old code might
have been relying on traditional C semantics or syntax. These were all
fixed, and the result of fixing some of them means that -Wall is now a
realistic possibility within a few weeks.
Entries for 800 and 820 fixed.
From vak@kiae.su:
incorporate Joerg Wunsch formatting code
correct handle timeouted operations
fixed entry for 720 media
GAP values changed suitable for possible format code addition.
Read/write GAP always 2 now.
Interleave parameter added for possible format code addition.
Many logical formats added.
720K physical drive added.
Problems: still can't read 720..820 media in 1.44 drive.
800K in HD 5.25in (maximum for DD diskettes)
1.44M in HD 5.25in (for easy distributions)
1.46M in HD 5.25in (maximum for 5.25)
Some cosmetique changes.
Now minor looks like UU DDDDDD, UU - unit, DDDDDD - density.
If density == 0, CMOS-detect format assumed.
Fix attach code for correct work with unknown CMOS
floppy types.
Trick diskerr to handle new minor.
1.722M floppy in 1.44M drive popular format added.
from:
Sergey Ryzhkov, Serge Vakulenko
E-mail: <sir@kiae.su>, <vak@zebub.msk.su>
This is the streamer tape driver for 386bsd and FreeBSD, which
supports Wangtek and Archive compatible QIC-02/QIC-36 controllers.
It was developed as a replacement of the old Wangtek tape driver from CMU.
In comparison with the CMU driver, this version has the following enhancements:
1) Support for Archive SC402 and SC499 tape controllers added.
2) Support for up to three tape controllers on the same machine.
3) Support for BSD-style ioctls MTIOCGET, MTIOCTOP.
Mt command now works adequately with this driver.
2) Asynchronous REWIND and FSF operations, close() will not wait
until they finish. The next open() will wait for it instead.
4) Use of WTQICMD ioctl is limited to ERASE and RETENS operations.
This prevents the user from locking the tape driver by strange
tape operations.
5) Tape density switching added.
6) The status of the process, blocked on the tape operation,
is displayed at the WCHAN column of the `ps' command as:
wtread reading data from the tape
wtwrite writing data to the tape
wtrfm reading the tape marker
wtwfm writing the tape marker
wtrew rewinding the tape
wterase doing WTQICMD ERASE operation
wtretens doing WTQICMD RETENS operation
wtorew doing MTIOCTOP REW/OFFL operation
wtorfm doing MTIOCTOP FSF operation
wtowfm doing MTIOCTOP WEOF operation
7) It's possible to use the tape with "default density",
useful for devices which don't support density switching
or do automatic format determination.
8) Some controllers support only 1024 block length.
Setting WT_BSIZE bit in device minor number turns on this mode.
Minor number structure:
0bfffuuu
Fields:
uuu - Unit number. It's possible to install
up to three tape controllers on the same machine,
using DRQs 1..3. Hence, unit number can lie
in range 0..2.
fff - Tape format number:
0 - /dev/rwt0 - default density (auto select)
1 - /dev/rwt0a - QIC 11 (obsolete)
2 - /dev/rwt0b - QIC 24 (60 megabytes)
3 - /dev/rwt0c - QIC 120 (120 megabytes)
4 - /dev/rwt0d - QIC 150 (150 megabytes)
5 - /dev/rwt0e - QIC 300 (300 megabytes?)
6 - /dev/rwt0f - QIC 600 (600 megabytes?)
b - Long block size flag. With this bit set,
the driver will perform all i/o operations
with the controller using 1024-byte
blocks, instead of 512 ones.
Some controllers need it (CMS for example).
If you Wangtek controller does not stream well,
you can try to use /dev/rWt0 device instead
of /dev/rwt0 (uncomment needed lines in /dev/MAKEDEV
to create it).
Block interface (writing blocks less than 2048 bytes) is not functioning
pwoperly. Use raw interface instead.
Thanks to all who helped to test it on the following hardware:
Controller Drive Volume Interface Thanks to
---------------------------------------------------------------------------
Archive SC-499 Archive 2150L 150 Meg QIC-02 KIAE
CMS? ? 150 Meg QIC-02 KIAE
Everex EV 831/833 ? ? QIC-36 Joergen Haegg
Wangtek ASSY Wangtek 60 Meg QIC-02 Ken Whedbee
Tecmar QT150i? Wangtek 5150EQ ? QIC-02? Marko Teiste
? Wangtek 5099EK 60 Meg QIC-36 Robert Shien
Archive SC400S ? 60 Meg ? Warren Toomey
possible end-user errors.
Now:
1) on physical 1.2 can open logical 1.2, 720, 360H
2) on physical 1.44 can open logical 1.44, 720
3) on physical 360 can open logical 360
All other variants refused.
C-style improved in this check, multiply if's changed to switch.
More work to add 720K floppy support.
Restore good old dependance of device and floppy type.
Now:
fd?a == 1.44
fd?b == 1.2
fd?c == 720
fd?d == 360 in HD
fd?e == 360
Add more strict size check in Fdopen, not it refuse:
1) Attempt to open any type expect fd?e, if you have only 360K drive.
2) Attempt to open fd?a if you have only 1.2 drive.
John Dyson to make it reliably work under FreeBSD.
2) Added and enabled PROCFS in the GENERICxx and LINT kernels.
3) New execve() from me. Still work to be done here, but this version
works well and is needed before other changes can be made. For
a description of the design behind this, see freebsd-arch or
ask me.
4) Rewrote stack fault code; made user stack VM grow as needed rather
than all up front; improves performance a little and reduces
process memory requirements.
5) Incorporated fix from Gene Stark to fault/wire a user page table
page to fix a problem in copyout. This is a temporary fix and
is not appropriate for pageable page tables. For a description
of the problem, see Gene's post to the freebsd-hackers mailing
list.
6) Tighten up vm_page struct to reduce memory requirements for it. ifdef
pager page lock code as it's not being used currently.
7) Introduced new element to vmspace struct - vm_minsaddr; initial
(minimum) stack address. Compliment to vm_maxsaddr.
8) Added a panic if the allocation for process u-pages fails.
9) Improve performance and accuracy of kernel profiling by putting in
a little inline assembly instead of spl().
10) Made serial console with sio driver work. Still has problems with
serial input, but is almost useable.
11) Added -Bstatic to SYSTEM_LD in Makefile.i386 so that kernels will
build properly with the new ld.
John Dyson to make it reliably work under FreeBSD.
2) Added and enabled PROCFS in the GENERICxx and LINT kernels.
3) New execve() from me. Still work to be done here, but this version
works well and is needed before other changes can be made. For
a description of the design behind this, see freebsd-arch or
ask me.
4) Rewrote stack fault code; made user stack VM grow as needed rather
than all up front; improves performance a little and reduces
process memory requirements.
5) Incorporated fix from Gene Stark to fault/wire a user page table
page to fix a problem in copyout. This is a temporary fix and
is not appropriate for pageable page tables. For a description
of the problem, see Gene's post to the freebsd-hackers mailing
list.
6) Tighten up vm_page struct to reduce memory requirements for it. ifdef
pager page lock code as it's not being used currently.
7) Introduced new element to vmspace struct - vm_minsaddr; initial
(minimum) stack address. Compliment to vm_maxsaddr.
8) Added a panic if the allocation for process u-pages fails.
9) Improve performance and accuracy of kernel profiling by putting in
a little inline assembly instead of spl().
10) Made serial console with sio driver work. Still has problems with
serial input, but is almost useable.
11) Added -Bstatic to SYSTEM_LD in Makefile.i386 so that kernels will
build properly with the new ld.
added to probe.
2) Force CLOCAL=on for outgoing ports and CLOCAL=off for
incoming ports into open in bidirectional case.
3) Add DELAY after writing to com_ier for fifo drain into probe.
The following patch adds the addr argument to signal handlers.
The kernel with the patch is no more and no less in compliance or in
violation of POSIX and ANSI C than the kernel before the patch.
The added functionality this addr argument provides is quite useful. It
enables an entire class of algorithms which use mprotect to trace memory
references. Beside garbage collectors, I have heard of this technique being
applied to debuggers and profilers. The only benchmarking I've performed is
using akcl to compile maxima: without the kernel patch, it takes 7 hours to
compile maxima, while with stratified garbage collection, it only takes 50
minutes.
Basically, I can't think of a reason not to add the addr argument and there
is a compelling need for it.
If you find the patch acceptable, please let me know so I can send my
FreeBSD akcl config files to wfs for inclusion in the core akcl release.
The old 386BSD config files there won't work on either NetBSD or FreeBSD.
From: <dec@lazarus.nrtc.northrop.com>
Changes between EPSILON and RELEASE of FreeBSD have again caused
the kernel to not see my floppy disk drives. I don't know what happened,
'cause I don't see any changes to fd.c, but here is an old fix that
I have applied to the probe routine which will solve the problem (at
least for me). Since this is a rather brute-force solution - I understand
if you want to ignore it...
[Upgrading to pre-Beta FreeBSD caused this on my system. -AM]
* merged in Garrett Wollman's strict prototype changes
*
* Revision 2.15 1993/11/29 16:32:58 davidg
* From Thomas Sandford <t.d.g.sandford@comp.brad.ac.uk>
* Add support for the 8013W board type
Subject: Page fault in PTE area fails in copyout
Index: sys/i386/i386/trap.c FreeBSD-1.0.2
Description:
Reading files of several megabytes into Emacs, or many small
files all at once, would fail with "IO error - bad address".
Repeat-By:
The bug can be exercised by a test program that malloc()'s
a 5MB chunk of memory, and then, without accessing the memory
first, filling it with data from a file using read().
(I read 64k chunks from /dev/wd0d into successive 64k regions
of the 5MB chunk.) The read() will fail with EFAULT at the first
virtual address boundary that is a multiple of 0x400000.
Fix:
The problem was code in sys/i386/i386/trap.c that tries to
figure out what kind of trap occurred and to handle it appropriately.
It was interpreting any page fault with virtual address
>= vm->vm_maxsaddr as being a user stack segment fault.
In fact, addresses >= USRSTACK are in the user structure/PTE area,
and if they are handled as stack faults, the proper PTE will
not be paged in when it is supposed to be. This situation comes
up in copyout() and copyoutstr(), if PTE's are accessed for the
first time ever. The page fault on accessing the nonexistent PTE
is mishandled as a stack fault, and then the fault that occurs on
the subsequent access to the page itself causes copyout to fail
with EFAULT.
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.
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.
---
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.
* 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.
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.
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.
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.
pccons or syscons usage. Modified comment in LINT for FAT_CURSOR.
Now the FAT_CURSOR can be controlled over the option, instead of hacking
syscons.c and pccons.c.
the stack area and not memory above VM_MAXUSER_ADDRESS.
That way, copyout and friends now work for pages whose page table entries
have not yet been allocated/been paged out.
machines (now 20% of all memory after the first 3MB). This is necessary
in order for 4MB machine to be able to rebuild the entire source tree
and not run out of physical memory because of fixed memory requirements
of processes and kernel VM.
set when extended translation is turned on, thus we need to do the mailbox
unlock command no matter what value is in the extended bios flag byte as
the other extensions (ie, > 2 drive support) cause the same problems.
The code has been changed to ALWAYS unlock the mailbox interface on ALL
1542C class boards.
called once when card is attached. Solved problem with driver
getting hosed when a reset takes place.
Removed init_block array -- now part of malloced memory. No more
static declarations left.
Added code so that debug ioctl actually does something.
ifconfig is0 debug will now switch on debugging code.
Other general cleanups.
since make depend wasn't picking up any new dependencies. However, due
to a bug in the old code, the original dependencies weren't being used, so
this version is better than the original and the lastest version.
(And is more readable as well)
* Novell probe changed to be invasive because of too many complaints
* about some clone boards not being reset properly and thus not
* found on a warmboot. Yuck.
*
* Revision 2.10 1993/10/23 04:07:12 davidg
* increment output errors if the device times out (done via watchdog)
*
* Revision 2.9 1993/10/23 04:01:45 davidg
* increment input error counter if a packet with a bad length is
* detected.
Date: Wed, 20 Oct 1993 18:28:44 +0300
Editors Note:
Line ended with comma (``,'') instead of semicolon (``;''),
this should not have effected the code.
Submitter made no comments other than it was ``simple''.
(rick@snowhite.cis.uoguelph.ca). I am currently using it with a Microsoft
InPort busmouse, under FreeBSD Epsilon. I hadn't planned on supporting it,
but I have patched it a few times, and I guess this is now the de facto
reference version, so send me any problems or improvements.
- Gene Stark
stark@cs.sunysb.edu
October 9, 1993
Date: Tue, 19 Oct 1993 02:22:41 -40962758 (WST)
As the subject line says:
I can;t believe this typo is still here.
Has NOBODY used the isa_dmastart() routine for 16bit DMA?
I know I just hit the dma regs directly for the AHA1542,
and it appears that either everybody else does as well, or
they only use 8bit DMA (e.g. floppy)
Editors Note:
The definition of DMA2_CHN was incorrectly using IO_DMA1!
* increase maximum time to wait for transmit DMA to complete to 120us.
* call ed_reset() if the time limit is reached instead of trying
* to abort the remote DMA.
*
* Revision 2.7 1993/10/15 10:49:10 davidg
* minor change to way the mbuf pointer temp variable is assigned in
* ed_start (slightly improves code readability)
*
* Revision 2.6 93/10/02 01:12:20 davidg
* use ETHER_ADDR_LEN in NE probe rather than '6'.
Remove NKMEMCLUSTERS, it is no longer define or used.
locores.s:
Fix comment on PTDpde and APTDpde to be pde instead of pte
Add new equation for calculating location of Sysmap
Remove Bill's old #ifdef garbage for counting up memory,
that stuff will never be made to work and was just cluttering
up the file.
Add code that places the PTD, page table pages, and kernel
stack below the 640k ISA hole if there is room for it, otherwise
put this stuff all at 1MB. This fixes the 28K bogusity in
the boot blocks, that can now go away!
Fix the caclulation of where first is to be dependent on
NKPDE so that we can skip over the above mentioned areas.
The 28K thing is now 44K in size due to the increase in
kernel virtual memory space, but since we no longer have
to worry about that this is no big deal.
Use if NNPX > 0 instead of ifdef NPX for floating point code.
machdep.c
Change the calculation of for the buffer cache to be
20% of all memory above 2MB and add back the upper limit
of 2/5's of the VM_KMEM_SIZE so that we do not eat ALL
of the kernel memory space on large memory machines, note
that this will not even come into effect unless you have
more than 32MB. The current buffer cache limit is 6.7MB
due to this caclulation.
It seems that we where erroniously allocating bufpages pages
for buffer_map. buffer_map is UNUSED in this implementation
of the buffer cache, but since the map is referenced in
several if statements a quick fix was to simply allocate
1 vm page (but no real memory) to it.
pmap.h
Remove rcsid, don't want them in the kernel files!
Removed some cruft inside an #ifdef DEBUGx that caused
compiler errors if you where compiling this for debug.
Use the #defines for PD_SHIFT and PG_SHIFT in place of
constants.
trap.c:
Remove patch kit header and rcsid, fix $Id$.
Now include "npx.h" and use NNPX for controlling the
floating point code.
Remove a now completly invalid check for a maximum virtual
address, the virtual address now ends at 0xFFFFFFFF so
there is no more MAX!! (Thanks David, I completly missed
that one!)
vm_machdep.c
Remove patch kit header and rcsid, fix $Id$.
Now include "npx.h" and use NNPX for controlling the
floating point code.
Replace several 0xFE00000 constants with KERNBASE
Mark the fact that PGSHIFT and PDRSHIFT are really the same as
PG_SHIFT and PD_SHIFT, these should be collapsed some day soon.
Document that KERNBASE should really be KPTDPTDI << PDRSHIFT, for
now leave it as the constant 0xFE000000 until I make a seperate
common header file for this stuff (vmaddresses.h?)
Remove NKMEMCLUSTERS define, it was only being used to define
VM_KMEM_SIZE, so why have all the indirection. Besides who wants
to work in CLBYTE sizes chuncks.
pmap.h:
Fix $Id$ and some other minor format clean ups.
Remove the XXX comment about NKPDE, since it now has the correct value
of 7.
Remove unused LASTPTDI and move the APTD into the very end of memory to
free up 4MB of kernel virtual address space.
Remove unused RSVDPTDI and free up 12MB of kernel virtual address space.
vmparam.h
Fix $Id$.
Increase SHMMAXPGS to 512 (2MB) now that there is room for it to be
bigger. The XXX comment stays until the kernel moves down in memory
to free up enough space to use the proper default of 4MB.
VM_KMEM_SIZE is now a direct constant stating the size of the kernel
malloc region. Increased the value from 3MB to 16MB.
then use that information to fix the enhancemode features of the
1542C/CF boards by turning them off.
When doing this I found that the Buslogic 545S does NOT properly
mimic the 1542 families AHA_INQUIRE command. It only returns 1
byte of information, when the adaptec manual clearly states that 4
bytes are to be returned. I added a printf that explains the error
when we see a 545S for now, I tried to come up with a better solution,
but it involved to much work for now.
Bruce Evans had limited the kernel virtual address space to not include the
last 4MB since it was not being used. Other changes are being made that will
reloate the Alternate Page Directory Table (APDT) into this area so the limit
is being fixed to be the last virtual address. (Infact with this patch you
can now do that relocation)
line of Makefile.i386. Fixes the extra rule that gmake complains about
for machdep.o. This fix is from Joans 0lsson.
Rework the depends and rules for assym.s and genassym so that we now use
the .depend rule for genassym.o such that if you change any header files
that are included by genassym.c the right things happen. This is probably
what has caused more bad kernel builds than any other thing in the
Makefile.i386!
other bio type devices.
Add mcd0 (mitsumi cd rom driver), to bad that GENERICBT is to large,
otherwise I could add this driver to it too.
--- 72,77 ----
Removed patch kit headers and rcsid strings, add $Id$.
isa.c:
Removed old #ifdef notyet isa_configure code, since it will never be
used, and I have done 90% of what it attempted to.
Add conflict checking code that searchs back through the devtab's looking
for any device that has already been found that may conflict with what
we are about to probe. Checks are mode for I/O address, memory address,
IRQ, and DRQ. This should stop the screwing up of any device that has
alread been found by other device probes.
Print out messages when we are not going to probe a device due to
a conflict so the user knows WHY something was not found. For example:
aha0 not probed due to irq conflict with ahb0 at 11
Now print out a message when a device is not found so the user knows
that it was probed for, but could not be found. For example:
ed1 not found at 0x320
For devices that have I/O address < 0x100 say that they are on the
motherboard, not on isa! The 0x100 magic number is per ISA spec. It
may seem funny that pc0 and sc0 report as being on the motherboard, but
this is due to the fact that the I/O address used is that of the keyboard
controller which IS on the motherboard. We really need to split the
keyboard probe from the display probe. It is completly legal to build
a pc with out one or the other, or even with out both!
npx.c:
Return -1 from the probe routine if we are using the Emulator so
that the i/o addresses are not printed, this is the same trick used
for 486's.
Do not print the ``Errors reported via Exception 16'', and
``Errors reported via IRQ 13'' messages any more, since these just lead
to more user confusion that anything. It still prints the message
``Error reporting broken, using 387 emulator'' so that the person is
aware that there mother board is ill.
to do this as I have changed to using PDTI's as the bases for the vm
system layout.
Eliminate constants SYSPDROFF and SYSPDREND, now use NKPTE to control the size
of the kernel virtual space.
Eliminate constant PDRPDROFF, now use PDTDTPI to control location of PTD,
PTDmap and PTDpde
Eliminate constant APDRPDROFF, now use APTDPTDI to control location of APTD,
APTDmap and APTDpde.
Still need to fix Sysmap location (it is still a constant).
.globl statements are now consistent with respect to <comma><space>, the
<space> being removed from all .globl statements.
Document the fillkpt macro as to what registers control what.
Fix some comments that went past column 80, and clean/line some others up.
Remove constand for _Crtat, now use KERNBASE+constant, this still needs work.
Replace constants for offsets of sigcode parameters with symbolic names
from assym.s
Mark the sigreturn() call with XXX since we use the hardcoded constant
for the system call number, this is bogus and should be a #define or
something some place!
The kernel before and after this change was verified with cmp, not one
byte changed. These are all cosmetic clean up changes that makes the
code more correct and easier to move the kernels virtual address space
and size.
Cleaned up tabs vs spaces after #define to make file consistent.
Removed now unused definitions of I386_PAGE_SIZE and I386_PDR_SIZE
Note That these two where unused and had the wrong values anyway!
Changed I386_KPDES to NKPDE
Changed I386_UPDES to NUPDE
Redid constant assignments of *PTDI's to be sizeable and relative.
> code. As this memcpy generation is done by the compiler it doesn't
> work to have memcpy a macro. Instead I made it a static function that
> calls bcopy.
Okay, I tracked down the d*mn thing that is causing the memcpy to be
emmitted by gcc2. In the following patch is a fix to eliminate the
one place that was causing gcc to do the memcpy in function ie_readframe
for the ie_recv_frame_desc rfd = *(ie->rframes[num]) structure copy.
I also fixed the code so that the NS (XNS) support would compile with
out error and removed the cruft #define ns_* stuff from the softc
structures (I did this a while back for all the other either drivers)
Removed the $Log$ and all of the old log stuff, that is all kept in
the cvs tree, no need to duplicate it in the file... I'll copy it
into my commit message so that it is all retained, except the
revision numbers are going to get screwed up.
It now compiles cleanly under my LINT kernel...
> I have not yet tested this on the AT&T fiver cards yet. But, Wollman
> has used it on various other AT&T cards. I'm pretty sure Terry also
> uses this driver.
$Log$ stuff from Garretts original file
* $Log$
* Revision 1.32 1993/06/20 15:56:15 wollman
* Fixed warning message.
*
* Revision 1.31 93/06/20 15:52:28 wollman
* More compilation lint.
*
* Revision 1.30 93/06/20 15:48:16 wollman
* Commented all the rest of the cast-qual warnings. Might be
* fixed someday by changing the prototypes of bcopy(), bzero(), etc.
*
* Revision 1.29 93/06/20 15:40:13 wollman
* Started fixing some of the cast-qual warnings (most just commented).
*
* Revision 1.28 93/06/12 20:39:14 wollman
* Changed definition of MK_24 to silence -Wcast-qual.
*
* Revision 1.27 93/06/08 17:05:57 wollman
* Attach routine now returns void.
*
* Revision 1.26 93/06/08 16:31:21 wollman
* Deleted attempt to set watchdog timer, since we don't use it.
*
* Revision 1.25 93/04/16 22:15:31 wollman
* Fixed infinite loop in iestart() which would cause the transmitter
* to constantly step on the Ethernet, sending the same two packets over
* and over again. This crashes the router (really!) and makes other
* network users very angry.
*
* Revision 1.24 93/04/14 23:57:47 wollman
* Increased transmit buffer size from 1504 to 1512, just in case I don't
* understand how the MTU is used.
*
* Revision 1.23 93/04/14 23:16:19 wollman
* Fix iestart() so that it only tries to execute a command if one was
* queued up (oops...).
*
* Revision 1.22 93/04/14 23:02:16 wollman
* Unknown changes.
*
* Revision 1.21 93/04/12 18:29:33 wollman
* Added multiple transmit commands. Note that they are always queued in
* pairs (there are only two to begin with), and the I flag is only set
* on the second one. This should decrease interrupt activity somewhat.
*
* Revision 1.20 93/04/12 15:36:05 wollman
* Changed setup of config block to take into account difference between
* StarLAN (10BASE-T) and Ethernet: StarLAN is Manchester, Ethernet is NRZ.
*
* Revision 1.19 93/03/23 18:58:44 wollman
* Raised count of receive buffers from 32 to 48 and included analysis of
* memory usage in a comment near that definition.
*
* Revision 1.18 93/03/18 03:59:53 wollman
* Last try to get large TCP windows to work...
*
* Revision 1.17 93/03/18 03:54:10 wollman
* Added RNR processing as a part of receive interrupts. Hopefully this
* will make everything Just Work now.
*
* Revision 1.16 93/03/18 03:23:24 wollman
* Still having problems with RNR conditions. Basic problem: say we
* set TCP window to 16k, which is a semsible value. Then smart
* partners will blast 16k to us, of which we can fit 8k minus a bit
* into our buffers. (Need to look at that memory map..) So, we get
* an RNR interrupt. The problem is, what do we need to do in this case?
* The original code doesn't work, but it doesn't hang the system either.
*
* Revision 1.15 93/03/18 02:37:00 wollman
* Disabled watchdog timer. This gets called from a timeout somewhere,
* which is running up at softclock. This is at a higher priority than
* we are, so we can get interrupted in the process of receiving something
* by the timer expiration, which is not a nice thing to have happen.
* Question: how can we keep this functionality, but do it in sync with
* our interrupts? (Ugh!)
*
* Revision 1.14 93/03/18 02:35:46 wollman
* Fixed some more problems with receive code---it works!
*
* Revision 1.13 93/03/17 20:15:59 wollman
* Think we fixed the serious (showstopper) bugs in 1.12.
*
* Revision 1.12 93/03/15 17:45:39 wollman
* Changed filtering logic dramatically to avoid the unnecessary copyin
* for BPF or multicast routing when the packet is not for us. (We
* have to run in promiscuous mode in this case.) We still need to
* deal with the problem of allocating one mbuf per receive buffer;
* we should be able to get away with a single mbuf for all reasonable
* incoming packets, and using an mbuf cluster will help avoid unnecessary
* copying of data.
*
* Revision 1.11 93/01/30 20:23:15 wollman
* Fiddled with reset code to hopefully make it work better when the
* watchdog timer expires. Question: why does it make a difference that
* we do the same thing through ieioctl() as we were doing before. The
* old code, when iereset() was called, the receive unit would completely
* die. But, a cycle of ifconfig ie0 down ; ifconfig ie0 up' would bring
* things back to normal. So, we try to mimic that now. Grrr...
*
* Revision 1.10 93/01/29 17:26:50 wollman
* Finally fixed multicast routing/BPF mb_map full problem!!!!
* It turned out that, when we received a packet not for us, we
* would just return from ie_readframe(), *WITHOUT* freeing the
* mbuf that the packet was in. So, when running in promiscuous
* mode (i.e., multicast routing or BPF without -p), we would have
* (on our extremely busy subnet 4) a memory leak of epic proportions.
*
* We now hold on to a single mbuf chain allocated in this way,
* and the next time a packet is read, we free it. Also, the
* next time a packet is transmitted, we free it. This way,
* we never lose more than 6 mbufs total (and on average more like
* 3).
*
* Revision 1.9 93/01/23 14:22:21 wollman
* Added some StarLAN Fiber modifications from L. Jonas Olsson.
*
* Revision 1.8 93/01/23 14:02:34 wollman
* Added support for IP multicasting.
*
* Revision 1.7 92/11/21 17:51:59 wollman
* Added StarLAN Fiber version point to my driver.
*
* Revision 1.6 92/11/20 18:21:45 wollman
* Fixed documentation, made out-of-mbuf condition an error.
*
* Revision 1.5 92/11/20 18:14:02 wollman
* Move change of ethertype to host byte order so that it's after
* bpf_mtap. Hopefully, this will allow us to listen to incoming
* IP packets.
*
* Revision 1.4 92/11/20 18:11:00 wollman
* Added code to drop packets when we run out of mbufs rather than
* panicking. This should alleviate the problems observed when using tcpdump.
*
* Revision 1.3 92/11/14 14:12:40 wollman
* Added BPF support code.
*
* Revision 1.2 92/11/14 13:30:26 wollman
* Added RCS keywords
*
Subject: Re: Error reading from DAT (fwd)
Date: Mon, 11 Oct 1993 03:02:39 -40962758 (WST)
Some tapes won't do anything until you tell them to load.
Other tapes think that being asked to load is a great excuse to
make the next command return a "unit attention" (media changed) error.
Since we need to do the load, throw in a dummy instruction to cop the
error.
specifically for DEC DAT drives.
now reads:
printf("use hd(1,a)/386bsd to boot sd0 when wd0 is also installed\n");
I know the person wanted more explination, but there is little room in
the boot blocks for verbose text!
PDRSHIFT.
The SYSTEM constant that was defined in this file has been replaced
with KERNBASE from param.h.
Changed almost all # style comments to /* */ C style comments. Several
comments cleaned up so that they make a little more since.
In the comments that describe C calling conventions to assembler routines
used a comma space sequence to seperate arguments and removed the space
between the function name and the argument list.
Removed useless comments like /* clr eax */.
Changed all comma space sequences on assemble instructions to just be comma.
Removed spaces after $ operators to make the file consistent, this may need
to change again (ie: $KERNBASE should probably be $(KERNBASE), but for now
it all seems to work just fine.) This may become a problem with the C
pre-processor.
Changed several double blank lines to single blank lines that where used
to seperate the I/O routines, these routines are blocked enough that we
don't need double blank lines between them.
Changed sequence of I/O routines to be all input functions, all output
functions instead of just the opposite.
Moved the SHOW_A_LOT debug stuff to near the end of the file.
Changed two occurances of the constant 0xfff to NBPG-1.
the proper I_X86CPU in the config file the following error will occur
while building the kernel: (had to line wrap the error for this message)
../../i386/i386/machdep.c:343: #error This kernel is not configured for one \
of the supported CPUs