dillon [Mon, 5 Nov 2001 18:48:54 +0000 (18:48 +0000)]
Implement IO_NOWDRAIN and B_NOWDRAIN - prevents the buffer cache from blocking
in wdrain during a write. This flag needs to be used in devices whos
strategy routines turn-around and issue another high level I/O, such as
when MD turns around and issues a VOP_WRITE to vnode backing store, in order
to avoid deadlocking the dirty buffer draining code.
Remove a vprintf() warning from MD when the backing vnode is found to be
in-use. The syncer of buf_daemon could be flushing the backing vnode at
the time of an MD operation so the warning is not correct.
jhb [Mon, 5 Nov 2001 18:05:56 +0000 (18:05 +0000)]
- There is no such thing as a socket structure. sockets are integers.
I'm assuming that the comment was regarding socket address structures, so
correct the comment about pre-zero'ing socket structures to recommend
pre-zero'ing socket address structures.
- Fix some minor grammar nits.
- This isn't directly submitted by the PR below but is related to it and was
inspired by it.
ume [Mon, 5 Nov 2001 16:46:24 +0000 (16:46 +0000)]
- net.inet.ipsec.esp_auth hasn't been there
- nuke all debug printfs, which are unneeded by now.
- get rid of #ifdef IPSEC_DEBUG in headers
- now that key_debug_level is always defined, there's no need for
#ifdef IPSEC_DEBUG around sysctl MIB code (net.key.debug).
- switch all debug printf() to ipseclog().
marcel [Mon, 5 Nov 2001 05:55:33 +0000 (05:55 +0000)]
Don't pass os_boot_rendez directly to SAL_SET_VECTORS, because it's
actually the address of the function descriptor. The fdesc has both
the address of the function and it's corresponding gp value. Now
that we have a gp value, use it instead of passing 0.
Refer people looking to figure out what major to use for a device to
MAKEDEV and sys/conf/majors, not sys/conf/device.<arch>, which has
never existed in the history of FreeBSD (well, at least it isn't in
the repository).
peter [Sun, 4 Nov 2001 21:30:12 +0000 (21:30 +0000)]
Make strtod.c work on Alpha as well. strtod.c has got locale support,
the netbsd_strtod.c file we have does not. More still should be done
here, but this works happily on my Alpha. I have not (yet?) changed
the Makefile.inc to use this.
dillon [Sun, 4 Nov 2001 18:55:42 +0000 (18:55 +0000)]
Add mnt_reservedvnlist so we can MFC to 4.x, in order to make all mount
structure changes now rather then piecemeal later on. mnt_nvnodelist
currently holds all the vnodes under the mount point. This will eventually
be split into a 'dirty' and 'clean' list. This way we only break kld's once
rather then twice. nvnodelist will eventually turn into the dirty list
and should remain compatible with the klds.
peter [Sun, 4 Nov 2001 18:28:45 +0000 (18:28 +0000)]
Forced commit:
Fix breakage in previous time_t related commit:
quad_t is not a 'long long' - don't use that for casting for printf %lld
(it is plain "long" on our 64 bit platforms).
Also, These timestamps are relative to boot time, not 1970. We dont need
to slow things down here with synthetic types on i386 since we have
other wraparounds that occur *long* before 68 years of uptime.
dillon [Sun, 4 Nov 2001 06:18:55 +0000 (06:18 +0000)]
Fix a bug in CD9660 when vmiodirenable is turned on. CD9660 was assuming
that a buffer's b_blkno would be valid. This is true when vmiodirenable
is turned off because the B_MALLOC'd buffer's data is invalidated when
the buffer is destroyed. But when vmiodirenable is turned on a buffer
can be reconstituted from its VMIO backing store. The reconstituted buffer
will have no knowledge of the physical block translation and the result is
serious directory corruption of the CDROM.
The solution is to fix cd9660_blkatoff() to always BMAP the buffer if
b_lblkno == b_blkno.
jhb [Sun, 4 Nov 2001 03:51:59 +0000 (03:51 +0000)]
Trim all the extra debugging output including hexdumps, debug messages,
etc. The only bit of debugging left is performing dual output to both
the screen and COM1. Also, the twiddle is still disabled since it seems
to do weird things to the serial dump. cdboot now has 880 bytes to spare.
jhb [Sun, 4 Nov 2001 03:24:16 +0000 (03:24 +0000)]
This is a new CD bootstrap utility designed to replace cdldr. According
to the El Torito standard for CD booting, a CD may boot in "No emulation"
mode without using a floppy image. In this mode, the BIOS loads a program
off of the CD into memory and creates a BIOS device using 2048 byte sectors
for the CD. According to the standard, this program can be up to 0xFFFF
virtual (512-byte) sectors long. The old cdldr depended on this by having
the BIOS load the entire loader and the small cdldr stub as one binary
similar to pxeboot so that cdldr didn't have to read the CD to find the
loader. However, the NT no emulation loader just uses 1 disk sector
(4 virtual sectors), so it seems that at least some BIOS writers just did
enough to get NT to boot by only loading 1 sector and ignoring the sector
count. Thus, while cdldr should have worked in theory, it doesn't in
practice. This replacment fits entirely in 1 sector and includes simple
ISO 9660 support. It looks for /boot/loader on the CD and loads it up
using the BIOS. This allows us to not have to depend on the limited size
of floppy images but use a full GENERIC kernel for CD-ROM installs in the
future, among other things.
This version of cdboot is a bit bloated as it includes some useful
debugging routines that people can pull to use in other x86 assembly
modules. Even with all the debugging cruft, we still have 272 bytes to
spare.
jhb [Sun, 4 Nov 2001 02:58:39 +0000 (02:58 +0000)]
Print out 'foo devices:' as the line before displaying a group of
devices in 'lsdev' output rather than printing out a pointer to the
print function since the user really could care less about the pointer
value. Perhaps this was intended to be a debugging printf?
jhb [Sat, 3 Nov 2001 22:09:30 +0000 (22:09 +0000)]
Add support for sending messages to the serial console which is helpful
when debugging boot problems. It is not on by default but is enabled via
the BTX_SERIAL variable. The port and speed can be set via the same
variables used by boot2 and the loader.
jhb [Sat, 3 Nov 2001 21:53:46 +0000 (21:53 +0000)]
Add support for outputting multiple lines when dumping memory during the
register dump. Change the default to bump 2 lines of output (32 bytes)
instead of 1 line (16 byte).
jhb [Sat, 3 Nov 2001 21:42:25 +0000 (21:42 +0000)]
Add support for trace traps by returning from them just as for breakpoint
traps rather than halting. Ideally, we should avoid printing the
'BTX halted' message for debug register dumps.
gallatin [Sat, 3 Nov 2001 17:22:50 +0000 (17:22 +0000)]
Introduce a boot environment variable (clock_compat_osf1) which can
be set to 1 to make FreeBSD and Tru64 coexist peacefully on a dual
boot system and not clobber each other's year in the TOY clock.
(Tru64 uses an offset 52 years higher than one would expect)
peter [Sat, 3 Nov 2001 13:26:15 +0000 (13:26 +0000)]
_SIG_MAXSIG (128) is the highest legal signal. The arrays are offset
by one - see _SIG_IDX(). Revert part of my mis-correction in kern_sig.c
(but signal 0 still has to be allowed) and fix _SIG_VALID() (it was
rejecting ignal 128).
peter [Sat, 3 Nov 2001 12:36:16 +0000 (12:36 +0000)]
Partial reversion of rev 1.138. kill and killpg allow a signal
argument of 0. You cannot return EINVAL for signal 0. This broke
(in 5 minutes of testing) at least ssh-agent and screen.
However, there was a bug in the original code. Signal 128 is not
valid.