Commit Graph

7073 Commits

Author SHA1 Message Date
Mike Smith
a7d3b81100 Use the same blocks->size-in-MB conversion algorithm as the SCSI code
to avoid overflowing an intermediate value for disks > 2^32 bytes
large.
1997-02-18 23:31:53 +00:00
Garrett Wollman
c20ac0292f Declare the new generic EOPNOTSUPP routines. 1997-02-18 20:47:24 +00:00
Garrett Wollman
117bcae7c4 Convert raw IP from mondo-switch-statement-from-Hell to
pr_usrreqs.  Collapse duplicates with udp_usrreq.c and
tcp_usrreq.c (calling the generic routines in uipc_socket2.c and
in_pcb.c).  Calling sockaddr()_ or peeraddr() on a detached
socket now traps, rather than harmlessly returning an error; this
should never happen.  Allow the raw IP buffer sizes to be
controlled via sysctl.
1997-02-18 20:46:36 +00:00
Garrett Wollman
d8392c6c39 uipc_mbuf.c: do a better job of counting how often we have to wait
for memory, or are denied a cluster.

uipc_socket2.c: define some generic ``operation-not-supported'' entry points
for pr_usrreqs.
1997-02-18 20:43:07 +00:00
Justin T. Gibbs
df98fb1bb2 Kill the initialization of two old scratch ram variables. They were removed
to make space for the larger message buffer.
1997-02-18 20:23:09 +00:00
Justin T. Gibbs
5154778752 Enlarge the message out buffer from 6 to 8 bytes. Now that sync and wide
negotiation messages may be tagged, we were overrunning the old buffer.
The variable that was getting squashed is updated before the message goes
out, causing corrupted SDTR or WDTR messages.  Depending on the phases
traversed before message out, this could cause the wrong offset to be
negotiated allowing data overruns to occur.  The problem is easier to
detect with wide targets on the chain since the allowed offset is smaller.

Also removed the unnecessary  clearing of SPIORDY during the message out
phase.  We don't rely on SPIORDY any more.
1997-02-18 20:22:52 +00:00
Nate Williams
9b4e82f125 Try to make the BROKEN_VLSI chipset detection better, and not break
non-broken chipssets whose ID is 0x84, such as the one found in the NEC
6030H.

> The code relies on the assumption that on a genuine_broken vlsi, you
> don't get 0x84 when probing slot 1 in the normal location.  On the versa I
> do get 0x84 when probing slot 1 in the normal location.  What you get on
> genuine_broken at the normal slot 1 location is unknown to me;

Submitted by:	Chris Timmons <skynyrd@opus.cts.cwu.edu>
1997-02-18 19:20:52 +00:00
Bruce Evans
b0a5b85d06 Fixed biosboot to compile with Lite2. <sys/lock.h> is now a prerequisite
for <ufs/ufs/inode.h>.
1997-02-18 15:09:39 +00:00
Bruce Evans
d314500e7e This now uses queue macros. Include <sys/queue.h> if !KERNEL to preserve
the documented interface.
1997-02-18 15:03:17 +00:00
Bruce Evans
a8687b6dcd Added some ufs #includes so that this compiles with option LOCKF_DEBUG.
Moving this all from ufs wasn't a good move.  At least the debugging
routines depend on the file system.

Cleaned up the LOCKF_DEBUG #includes.
1997-02-18 14:37:26 +00:00
Bruce Evans
697030ed3d Removed vestiges of Mach lock types.
vm_map.h:
Removed #include of <sys/proc.h>.  curproc is only used in some macros
and users of the macros already include <sys/proc.h>.
1997-02-18 14:07:03 +00:00
Bruce Evans
cd9307f60d Changed type of t_line from u_char to int. The Lite2 merge blew away
rev.1.6 which changed it from char to int.
1997-02-18 09:26:15 +00:00
Bruce Evans
78fd7b3d49 Fixed namei caching for LOOKUPs. It was broken for lstat() and olstat().
Successful lstat()s purged an existing entry as well as not caching the
result.

This bug was introduced in Lite1 by setting the LOCKPARENT flag for
[o]lstat() in order to support the inherit-attributes-from-parent-
directory misfeature for symlinks.  LOCKPARENT was previously only set
for CREATEs and DELETEs.  It is now set for LOOKUPs, but only for
[o]lstat(), so the problem wasn't very noticeable.
1997-02-18 06:46:41 +00:00
Bruce Evans
25ed2ac223 Changed #ifdef COMPAT_PRELITE2' to #ifndef NO_COMPAT_PRELITE2' so that
the old VFS_VFSCONF sysctl is enabled by default.

Initialize the vfc_vfsops field to non-NULL in sysctl_ovfs_conf()
so that the old VFS_VFSCONF sysctl actually works.  The old (still
current) getvfsent.c uses this "kernel-only" field to decide which
vfs's are configured (the old implementation returned null entries
for unconfigured vfs's).
1997-02-18 04:58:11 +00:00
Bruce Evans
bd6d39b941 Changed #ifdef COMPAT_PRELITE2' to #ifndef NO_COMPAT_PRELITE2' so that
old nfs mount calls are supported by default.
1997-02-18 04:40:38 +00:00
Justin T. Gibbs
4e605384b5 Don't rely on AAP(Auto Access Pause) when queueing SCBs to the card. This
will increase the overhead of queueing a command, but some recent bug reports
make me believe that AAP isn't really working and that we are losing some
SCBs from the input queue.  Hopefully this will cure that problem.

Fix some bugs in the error recovery code.  Mainly these could cause us to
inadvertantly forget to untimeout an SCB that was recovered causing later
confusion.
1997-02-18 04:25:31 +00:00
David Greenman
70e534e78f Pass P_SUGID on to the child of a fork(). It was possible to get rlogin
to coredump previously since it (somewhat uniquely) is setuid and forks
without execing, and thus without passing P_SUGID the child could
coredump and possibly divulge sensitive information (such as encrypted
passwords from the passwd database).
1997-02-17 10:58:46 +00:00
Bruce Evans
f79ef55e7a Replaced START_ENTRY by _START_ENTRY. -current hasn't got my cleanup
of DEFS.h which renamed it.
1997-02-17 07:21:28 +00:00
Bruce Evans
dab159e3d6 Select between the generic math functions and the i387-specific ones
at runtime.

etc/make.conf:
Nuked HAVE_FPU option.

lib/msun/Makefile:
Always build the i387 objects.  Copy the i387 source files at build
time so that the i387 objects have different names.  This is simpler
than renaming the files in the cvs repository or repeating half of
bsd.lib.mk to add explicit rules.

lib/msun/src/*.c:
Renamed all functions that have an i387-specific version by adding
`__generic_' to their names.

lib/msun/src/get_hw_float.c:
New file for getting machdep.hw_float from the kernel.

sys/i386/include/asmacros.h:
Abuse the ENTRY() macro to generate jump vectors and associated code.
This works much like PIC PLT dynamic initialization.  The PIC case is
messy.  The old i387 entry points are renamed.  Renaming is easier
here because the names are given by macro expansions.
1997-02-16 18:26:31 +00:00
Andrey A. Chernov
a859cfcea9 Back ut FD_SETSIZE increasing until related kernel issues will be resolved 1997-02-16 06:39:43 +00:00
Andrey A. Chernov
acc2427984 Bump default FD_SETSIZE from 256 to 1024 as many modern
systems do nowdays (like SunOs 5.5.1 f.e.)
256 is too small under real network load
1997-02-15 22:26:29 +00:00
Garrett Wollman
d0390e0570 Fix the mechanism for choosing wehether to save the slow-start threshold
in the route.  This allows us to remove the unconditional setting of the
pipesize in the route, which should mean that SO_SNDBUF and SO_RCVBUF
should actually work again.  While we're at it:

- Convert udp_usrreq from `mondo switch statement from Hell' to new-style.
- Delete old TCP mondo switch statement from Hell, which had previously
  been diked out.
1997-02-14 18:15:53 +00:00
Garrett Wollman
4a26224c8d Send RTM_IFINFO messages whenever promiscuous and all-multicast
modes are enabled or disabled.
1997-02-14 15:30:54 +00:00
David Greenman
0305f20493 Changed timeout for requesting sense from 100ms to 1 second.
Submitted by:	gibbs
1997-02-14 03:13:37 +00:00
Bruce Evans
661e2ccd94 Changed #include order to match better order in 2.2. 1997-02-13 22:48:19 +00:00
Garrett Wollman
39191c8eb8 Provide PRC_IFDOWN and PRC_IFUP support for IP. Now, when an interface
is administratively downed, all routes to that interface (including the
interface route itself) which are not static will be deleted.  When
it comes back up, and addresses remaining will have their interface routes
re-added.  This solves the problem where, for example, an Ethernet interface
is downed by traffic continues to flow by way of ARP entries.
1997-02-13 19:46:45 +00:00
Garrett Wollman
30f700e9c7 Provide an alternative mbuf cluster allocator which permits use of
clusters greater than one page in length by calling contigmalloc1().
This uses a helper process `mclalloc' to do the allocation if
the system runs out at interrupt time to avoid calling contigmalloc
at high spl.  It is not yet clear to me whether this works.
1997-02-13 19:41:40 +00:00
Garrett Wollman
10825343b0 Provide an alternative interface to contigmalloc() which allows a specific
map to be used when allocating the kernel va (e.g., mb_map).  The VM
gurus may want to look this over.
1997-02-13 19:37:40 +00:00
KATO Takenori
def9b7665d Synchronize with sys/i386/isa/syscons.c revision 1.201. 1997-02-13 18:43:50 +00:00
KATO Takenori
8ea8b7549d Synchronize with sys/i386/boot/biosboot/boot.c revision 1.62. 1997-02-13 18:41:03 +00:00
Garrett Wollman
5bee01c83f For large values of sb_max or MCLBYTES, it was possible for the expression
sb_max * MCLBYTES / (MSIZE + MCLBYTES)
used in sbreserve() to overflow, causing all socket creation attempts
to fail.  Force the calculation to use u_quad_t's, which makes overflow
less likely.
1997-02-13 18:05:46 +00:00
Bruce Evans
8363c19687 Get defaults for the boot device (and flags) from the file
"boot.config" (relative to the root directory on the 'a' partition
on the first BSD slice) if it exists.  If it doesn't exist, then
the only visible changes should be that the kernel name isn't reset
to "/kernel" after looking it up fails and that the default name
is now "kernel".

The new function readfile() can be used for other things:
- reading help messages.
- reading splash screens.
- reading userconfig info.
1997-02-13 13:15:47 +00:00
Søren Schmidt
cc5625f0ed Oops, cut/paste could be done on tthe WRONG vty :(
pointed out by Kazu.
1997-02-13 11:58:49 +00:00
Bruce Evans
a7d00b5bf6 Moved definition of FUNCTION_ALIGNMENT to a machine-dependent place.
Changed it from 4 to 16 for i386's.  It can be anything for i386's,
but compiler options limit it to a power of 2, and assembler and
linker deficiencies limit it to a small power of 2 (<= 16).
We use 16 in the kernel to get smaller tables (see Makefile.i386 and
<machine/asmacros.h>).  We still use the default of 4 in user mode.

Use HISTCOUNTER instead of (*kcount) in the definition of KCOUNT()
for consistency with other macros.
1997-02-13 10:47:29 +00:00
Bruce Evans
47cac30b9a Align text to 16-byte boundaries if profiling is enabled. This will
allow a fourfold reduction in the size of the profiling buffers.  This
goes with rev.1.91 of Makefile.i386 which does the same thing for C
functions.
1997-02-13 08:31:53 +00:00
Bruce Evans
eb26546e6f Killed more FIFO ifdefs. All gone now. 1997-02-13 01:13:13 +00:00
Bruce Evans
c626216f51 Removed FIFO ifdef again (see rev.1.5). 1997-02-13 00:42:10 +00:00
Bruce Evans
4f3850c2a8 Removed bogus B_AGE policy again (see rev 1.4).
Removed FIFO ifdef again (see rev.1.8).  This also fixes vfs initialization
since the VNODEOP_SET() was inside the ifdef.
1997-02-13 00:39:06 +00:00
Garrett Wollman
176395b2e8 Implement PRC_IFUP a la PRC_IFDOWN so that protocols know when an interface
has come bacl up (and can referse actions taken as a result of downing).
1997-02-12 18:54:32 +00:00
Mike Pritchard
f3a778f288 Eliminate the last of the compile warnings in this module by
correctly casting the arguments to all of the null_bypass() calls.
1997-02-12 18:06:08 +00:00
Mike Pritchard
fdc0430e50 Restore of #include <sys/kernel.h> so that this compiles without
warnings again.
1997-02-12 17:47:28 +00:00
Mike Pritchard
61f84e5b27 Don't depend on FIFO being defined to enable mkfifo.
It is now always compiled.

Submitted by:	bde
1997-02-12 16:55:32 +00:00
Mike Pritchard
dc14cd9f1b This no longer depends on NFS being defined so that it
can check for an NFS root.  With Lite2, the file system
type can be checked by checking if the rootfs name == "nfs".
1997-02-12 16:46:25 +00:00
Mike Pritchard
670718e23a Remove function prototypes for vfs_mountroot and vgoneall, since
they were removed with the Lite2 merge.

Submitted by:	bde
1997-02-12 16:37:39 +00:00
Mike Pritchard
8092a8e143 Make this compile without warnings after the Lite2 merge:
- *fs_init routines now take a "struct vfsconf * vfsp" pointer
  as an argument.
- Use the correct type for cookies.
- Update function prototypes.

Submitted by:	bde
1997-02-12 16:31:27 +00:00
Mike Pritchard
10546e217e Rstored #include of <sys/kernel.h> so that this compiles
without warnings again.

Submitted by:	bde
1997-02-12 16:26:37 +00:00
Mike Pritchard
fd7a659f2f Make this compile again after the Lite2 merge.
Call vget/VOP_UNLOCK with the correct number of
arguments.  Call vn_lock where appropriate.
vfs_goneall is now replaced by VOP_REVOKE.

Submitted by:	bde
1997-02-12 16:19:11 +00:00
Bruce Evans
5afe6df620 Fixed type mismatches. i_spare[N] in ufs/inode.h changed from long to
int.  Change ext2fs to match.  We probably already assume that ints have
>= 32 bits.
1997-02-12 15:35:18 +00:00
Mike Pritchard
63f50488b0 Make this compile again after the Lite2 merge.
Also add missing function prototypes.
1997-02-12 14:55:01 +00:00
Mike Pritchard
aae8d53e0e Add missing function prototypes. 1997-02-12 14:54:14 +00:00
Bruce Evans
938958b97f Added parameter names to prototypes that were added in the last commit to
match nearby style.
1997-02-12 14:45:23 +00:00
Bruce Evans
9e67ea79f0 Restored #include of <sys/kernel.h> so that this compiles again. 1997-02-12 14:31:11 +00:00
Bruce Evans
86413edd9b Declare function args in order in recently K&Rised function headers. 1997-02-12 14:07:26 +00:00
Bruce Evans
b52748bee5 Restored some lost function return types. 1997-02-12 14:00:00 +00:00
KATO Takenori
2f0fdf5504 Added check routine for memory window configuration. The probe
routine of C-NET(98) returns 0 when isa_dev->id_maddr == 0 or
isa_dev->id_msize == 0.
1997-02-12 13:39:24 +00:00
KATO Takenori
39a0888f8a Added memory addres and size of d8 (C-NET(98) network card). 1997-02-12 13:32:58 +00:00
Bruce Evans
56a956e530 Use a valid value for MSGSSZ
Don't specify PSM_CHECKSYNC twice.

Submitted by:	MSGSSZ by mi@aldan.ziplink.net
1997-02-12 09:47:31 +00:00
Mike Pritchard
72a5ee14de Add function protypes for the new Lite2 unionfs functions. 1997-02-12 07:54:22 +00:00
Steven Wallace
1a46116d9d Bug fix for SNDCTL_DSP_GETOSPACE ioctl. It would report 0 bytes
available in buffer when buffer was completely empty.
It now correctly reports the total buffer space available.

Reviewed by:	jkh, davidg
Obtained from:  Linux 1.3.20's sound driver code
1997-02-12 06:56:57 +00:00
Mike Pritchard
724ab19569 Add function prototypes for most of the new Lite2 functions.
Also made a few of the miscfs routines static to be
consistent.  Some modules simply required some additional
#includes to remove -Wall warnings.
1997-02-12 06:52:51 +00:00
Mike Pritchard
820d8cf44a Comment out a call to the #ifdef DIAGNOSTIC routine
vfs_bufstats().  This routine was not imported in the
Lite2 merge.
1997-02-12 06:46:11 +00:00
Nate Williams
8c1801dce9 In the disable_slot() routine, the variable "i" was
being used without ever being initialized.  From examining
the rest of the routine, it looks like this is a typo,
and it really should have been "1" instead of "i".

Submitted by:	mpp
1997-02-11 17:22:46 +00:00
Justin T. Gibbs
a042d32c0b Fix a bug in the reporting of residuals. The code was relying on the SG_COUNT
filed in the hardware SCB not changing during the course of a transaction.
Since the sequencer now DMAs the hardware SCB back up to the host when it
detects a residual, this is no longer the case.  I added a field to the
"software" scb to mirror this information and it is now used for doing the
residual calculation.
1997-02-11 17:10:37 +00:00
Justin T. Gibbs
499c4ce9f6 Clear the DFCNTRL register after every busfree.
When setting the HCNT registers, do so in ascending order.

When performing tagged queueing in non-paging mode, also check the
disconnected bit in the SCB as extra sanity during a reconection.

Make the labels in the DMA routine more sane.

When doing a DMA, if we see the DMADONE condition come true, we can
simply turn of the DMA enable bits in DFCNTRL without testing the FIFO
state as HDONE is true when DMADONE is true and this emplies the FIFO is
empty.

These changes clear up the data overrun error messages and seem to prevent
the "timed out in data-in phase" problems.
1997-02-11 17:07:54 +00:00
Bruce Evans
596d40b9f4 Restored one line of "High Sierra" changes from rev.1.8.
The Lite2 changes in cd9660 are scarey.  I probably missed some
other lossage in this file.
1997-02-11 16:55:33 +00:00
Bruce Evans
49bb6bceaf Restored one line of "High Sierra" changes from rev.1.6 which was
blown away by the previous commit.

Not restored: trailing whitespace changes from rev.1.7.
Not restored: -Wall cleanup from rev.1.5.
1997-02-11 16:16:02 +00:00
Bruce Evans
a9386c5274 Removed High Sierra task from TODO list. Joerg did it years ago and
other items were removed from the list when they were done in the
Lite2 merge.  The Lite2 merge just broke the High Sierra changes.
1997-02-11 16:15:15 +00:00
Bruce Evans
3d1713a8a5 Restored changes from rev.1.58-1.60 which were blown away by the
previous commit.
1997-02-11 15:03:31 +00:00
KATO Takenori
1c3ae72914 Deleted prototypes. They are in pc98_machdep.h. 1997-02-11 14:59:54 +00:00
KATO Takenori
33a262b0dc Synchronize with sys/i386/isa/if_ed.c revision 1.114. 1997-02-11 13:55:36 +00:00
KATO Takenori
512b30df54 Synchronize with sys/i386/conf/majors.i386 revision 1.12. 1997-02-11 13:54:44 +00:00
Julian Elischer
db03b748e3 really minor cleanup
sc is set to ifp->if_softc so use it..
1997-02-11 09:29:48 +00:00
Garrett Wollman
1e49bd9cd3 Fix spelling of net.inet.ip.forwarding.
Add ARP_PROXYALL to defunct options.
1997-02-10 19:19:16 +00:00
Mike Pritchard
812ac98e83 Correct the new Lite2 #ifdef DIAGNOSTIC ffs_checkblk routine
to not return without setting a return value when it
can't read a block error or detects a bad cylinder group,
since the caller is expecting a return value.
It will now panic at this point, since the thing
to do in this case would be to return a "bad block"
status to the caller, and the caller will panic
anyways when that happens.

Also updated to panic strings in this routine to read
"ffs_checkblk: ..." instead of "checkblk: ...".
1997-02-10 17:05:30 +00:00
Mike Pritchard
b49b12158f Make this compile again after the Lite2 merge.
VOP_UNLOCK was being called with the wrong mumber of arguments.

Also silenced a -Wall warning.
1997-02-10 16:34:16 +00:00
Mike Pritchard
59942ba155 Make this compile again after the Lite2 merge.
VOP_UNLOCK was being called with the wrong mumber of arguments.
1997-02-10 16:32:52 +00:00
Mike Pritchard
04a0d5e517 Make this compile after the Lite2 merge.
A non-existent variable was being used.
1997-02-10 16:29:32 +00:00
Mike Pritchard
d2b52eb257 Make ffs_subr.c compile when DIAGNOSTIC is defined.
It looks like this was broken before the Lite2 merge :-(.
VOP_BMAP was being called with the wrong number of arguments.
1997-02-10 16:27:53 +00:00
Mike Pritchard
06bcc9e510 Make ccd compile again after the Lite2 merge.
VOP_UNLOCK was being called with the wrong number of arguments.
1997-02-10 16:24:33 +00:00
Darren Reed
4b93480b2a IP Filter is now character device #79 1997-02-10 12:17:45 +00:00
KATO Takenori
6ed46f82d8 Synchronize with Lite/2 commit: i386/i386/machdep.c, i386/i386/trap.c,
i386/isa/fd.c and i386/isa/wd.c revisions 1.227, 1.87, 1.96 and 1.123,
respectively.
1997-02-10 11:53:20 +00:00
Darren Reed
55452e7f59 Add IP Filter .c files for "config" & "config.new" use. 1997-02-10 11:52:36 +00:00
Darren Reed
afed1b4988 Add IP Filter hooks (from patches). 1997-02-10 11:45:37 +00:00
David Nugent
184989c210 Fix off by one error in setlogin() syscall.
Don't overwrite session login unless the call is going to succeed.
1997-02-10 06:18:20 +00:00
John Dyson
996c772f58 This is the kernel Lite/2 commit. There are some requisite userland
changes, so don't expect to be able to run the kernel as-is (very well)
without the appropriate Lite/2 userland changes.

The system boots and can mount UFS filesystems.

Untested: ext2fs, msdosfs, NFS
Known problems: Incorrect Berkeley ID strings in some files.
		Mount_std mounts will not work until the getfsent
		library routine is changed.

Reviewed by:	various people
Submitted by:	Jeffery Hsu <hsu@freebsd.org>
1997-02-10 02:22:35 +00:00
Justin T. Gibbs
62e2cfe42e ULTRAENB->FAST20 1997-02-09 03:27:09 +00:00
Justin T. Gibbs
21c89fbab3 ahc_search_qinfo->ahc_search_qinfifo
ULTRAENB->FAST20

Add a missing ahc_run_done_queue if a BRKADDRINT occurs.  This should never
happen (haven't heard of one happening), but it was still a bug.

Brought the ordered tag sending code up into the tag code to be clearer.

If we decide we should send an ordered tag, only do so for the target that
timed out instead of all targets.

Initialize the STAILQ in ahc_serach__qinfifo.  This was causing a panic
during some recovery operations.

Remove the unused varable maxtarget.
1997-02-09 03:26:56 +00:00
Justin T. Gibbs
de1dc306be Clear the channel after (re)selection instead of once we see the bus go
free.

When we clear SCSIRATE, also clear the FAST20 bit in SXFRCTL0.  This also
allowed me to clean up some of the ULTRA code.

ULTRAENB->FAST20 to follow the convention in the Adaptec data books.

Fix the data-overrun code to set both stcnt and hcnt otherwise, the transfer
will just hang until we get a timeout.

Add implicit support for the NOOP message.  I've never heard of the driver
issueing a reject for one, but its silly to reject NOOP and who knows how a
device might react.

In the dma routine, check SDONE before cleaing SDMAEN.  The data books mention
SDONE possibly being cleared when SDMAEN is reset.  Clients of dma now need
to check if SINDEX is cleared to know if a phasemis occured.

Fix some comments to be correct.
1997-02-09 03:23:28 +00:00
Joerg Wunsch
17d9b79a9f Add an entry for the Nakamichi 4-disk changer.
Submitted by:	K.R.Marshall@ukc.ac.uk (K.R.Marshall)
1997-02-08 13:26:31 +00:00
KATO Takenori
77720af4dd Replaced hardcoded unit number with ftu. 1997-02-08 09:59:27 +00:00
KATO Takenori
5007dce7da Synchronize with sys/i386/conf/majors.i386 revision 1.11. 1997-02-08 07:39:07 +00:00
Bill Paul
9baa6352dc Make some small tweaks to the messages to clean up some stuff
from last time. Some people have pointed out that there were some odd
side-effects in the changes I made. Two things are different:

- sc_print_addr() will print 'foodev0:' (i.e. sd0:, st0:, cd0:, etc...)
  if the device name is known. If it's not known, it'll use a longer
  notation. This shortens error messages back to a sane length.

- Added a small function called sc_print_init() to set the sc_printing
  flag so that sc_print_addr() will know that we want it to print a
  linefeed. Used this in scsi_device_attach() to restore proper carriage
  return printing behavior which I broke.

Remaining bogons: the NCR SCSI driver prints out information while the
device-specific attach routine is running with its own linefeeds. This
breaks up the individual messages emitted by the subdriver modules and
causes at least one message to appear on a line by itself without a
device spec prefix. I'm not sure of the correct way to fix this, and
I don't have any NCR SCSI hardware to test with anyway.

There's probably more, but I gather that a rewrite of the SCSI subsystem
is pending anyway, so I'll leave the rest to Those Who Know More About
This Than I (tm).
1997-02-08 03:42:22 +00:00
Poul-Henning Kamp
b7a652ab84 I have no idea what this is all about, but it works and Bruce hasn't
complained so it cannot be entirely bad :-)

I include the email that probably explains it for people who already know:

> >Compiling with -O3 inlines functions.  However the function that is being
> >inlined in makeinfo.c (add_word_args()) is a vararg function and must not be
> >inlined.
> >
> >The code in question is K&R style, and AFIK, there is no way for the compiler
> >to determine that the function uses vararg.  Either change the code to use
> >prototypes, or use stdarg, or add a directive to prevent inlining.
>
> Not declaring a varargs function as varargs before it is used gives
> undefined behaviour.
>
> However, in practice the bug is probably in FreeBSD's <varargs.h>, which
> doesn't use gcc's __builtin_next_arg().  gcc should notice that it is
> used and not inline functions that have it.  <stdarg.h.> uses it, but I
> think there's another gcc builtin that it should be using.

Patch attached.  The ellipsis causes gcc to flag this as a varargs function,
and the name "__builtin_va_alist" is special cased in gcc to hide the last
argument in the arglist.

Reviewed by:	bde & phk
Submitted by:	jlemon@americantv.com (Jonathan Lemon)
1997-02-07 20:22:15 +00:00
KATO Takenori
15466e1892 Moved macros which are related to BIOS work area from pc98.h
(corresponds to isa.h) to pc98_machdep.h.
1997-02-07 19:07:43 +00:00
KATO Takenori
f97a606a78 Enabled pccard code which was disabled by mistake.
Reminded by:	Masahiro Sekiguchi <seki@sysrap.cs.fujitsu.co.jp>
1997-02-07 19:02:41 +00:00
Kazutaka YOKOTA
445605a6e0 Fix for the Compaq Armada laptop.
The PS/2 mouse device responds to a reset command with a sequence of
ACK(fa), RESULT(aa) and ID(00).  Most PS/2 mice immediately returns
ACK, but spend sometime before sending RESULT. The Armada takes time
before ACK; extra delay is necessary before the call to read ACK.

The problem was reported in comp.unix.bsd.freebsd.misc and the patch
was tested by the reporter. No PR was filed, by the way.
1997-02-07 11:41:45 +00:00
David Nugent
db2c31168e Correct comments relating to MAXLOGNAME.
MAXLOGNAME includes NUL terminator.
1997-02-07 10:41:41 +00:00
Joerg Wunsch
a2f36095e2 The worm(4) driver needs a bdev major # now, too. 1997-02-06 22:20:33 +00:00
Joerg Wunsch
ab865e3435 After so many people have been bugging me :), finally implement
read-mode access to CD-ROM media in the worm(4) driver.  No whistles
and bells yet, like all the CDIO* commands, but at least a start.

In order to do this, i had to slightly rearrange the semantics of an
open(2) on the worm driver: now, opening it with O_NONBLOCK set means
no actual IO operations will be intended but only ioctls are to be
processed.  This mode is used by wormcontrol(8) to prepare a track
and/or session.

I have only been able to test this on a 2.2-GAMMA system by now, and
only the !DEVFS part is tested yet.  Also, i have only done a dummy
burn so far, but wouldn't expect many surprises else.  Report bugs to
me ASAP, if there's reasonable demand and i hear no objections, i
might consider merging it into the 2.2 branch as well.
1997-02-06 22:19:44 +00:00
KATO Takenori
8716a6359b Deleted ioskip member of the structure pc98_edregister. The member
port is always used for accessing PAR and MAR instead of constant
interval of I/O address.
1997-02-06 14:16:52 +00:00