Commit graph

7519 commits

Author SHA1 Message Date
Peter Wemm a08f4bf601 Fully implement the clause in Appendix B.4.2.2 from Posix 1003.1
that allows traditional BSD setuid/setgid behavior.

The only visible difference should be that a non-root setuid program
(eg: inn's "rnews" program) that is setuid to news, can completely
"become" uid news. (ie: setuid(geteuid())  This was allowed in
traditional 4.2/4.3BSD and is now "blessed" by Posix as a special
case of "appropriate privilige".

Also, be much more careful with the P_SUGID flag so that we can use it
for issetugid() - only set it if something changed.

Reviewed by: ache
1997-03-31 13:36:46 +00:00
Peter Wemm 8a5d815aa0 Make setgroups(0, xxx) behave as it does on SYSV, namely clear the groups
vector except for the egid in groups[0].  There is a risk that programs
that come from SYSV/Linux that expect this to work and don't check for
error returns may accidently pass root's groups on to child processes.

We now do what is least suprising (to non BSD programs/programmers) in
this scenario, and nothing is changed for programs written with BSD groups
rules in mind.

Reviewed by: ache
1997-03-31 13:21:37 +00:00
David Greenman a91b87211d In accept1(), falloc() is called after the process has awoken, but prior
to removing the connection from the queue. The problem here is that
falloc() may block and this would allow another process to accept the
connection instead. If this happens to leave the queue empty, then the
system will panic with an "accept: nothing queued".

Also changed a wakeup() to a wakeup_one() to avoid the "thundering herd"
problem on new connections in Apache (or any other application that has
multiple processes blocked in accept() for the same socket).
1997-03-31 12:30:01 +00:00
Peter Wemm 57862eed22 Code to do lchown(2), copied from chown(2) except it's NOFOLLOW in ND_INIT
instead of FOLLOW.
1997-03-31 12:21:37 +00:00
Peter Wemm f77da2867a Regenerate 1997-03-31 12:17:45 +00:00
Peter Wemm 4eb542c64b Reserve 252 (poll, first in OpenBSD)
Reserve 253 (issetugid, as in OpenBSD)
Allocate 254 for lchown(2)
1997-03-31 12:14:48 +00:00
Peter Wemm 6c14d95d0d Treat symlinks as first class citizens with their own uid/gid rather than
as shadows of their containing directory.  This should solve the problem
of users not being able to delete their symlinks from /tmp once and for
all.

Symlinks do not have modes though, they are accessable to everything that
can read the directory (as before).  They are made to show this fact at
lstat time (they appear as mode 0777 always, since that's how the the
lookup routines in the kernel treat them).

More commits will follow, eg: add a real lchown() syscall and man pages.
1997-03-31 12:02:53 +00:00
David Greenman 9caaadb63a Changed the way that the exec image header is read to be filesystem-
centric rather than VM-centric to fix a problem with errors not being
detectable when the header is read.
Killed exech_map as a result of these changes.
There appears to be no performance difference with this change.
1997-03-31 11:11:26 +00:00
KATO Takenori 529016f9e7 Synchronize with sys/i386/conf/GENERIC revision 1.89. 1997-03-31 08:27:05 +00:00
Joerg Wunsch 514e9fd6b8 Implement the `detach' command for remote GDB. It gets you back at DDB. 1997-03-30 16:03:00 +00:00
Poul-Henning Kamp 015056ae61 Fix embarrasing typo that survived because I applied the wrong patch-
file.
Noticed by:	Eric Jones <ejon@psa.pencom.com>
1997-03-30 09:08:00 +00:00
Peter Wemm bf6c0d31b7 Regenerate (include file changes, stray blank lines (cosmetic),
and a syscall vector was out of sync with it's .master file)
1997-03-29 13:15:23 +00:00
Peter Wemm bf07edd9e3 Renerate (some include files were changed) 1997-03-29 13:12:46 +00:00
Bruce Evans b445591810 Removed #include of <ufs/ufs/dir.h>. Nfs no longer depends on any ufs
features, and the one thing that it depended on (DIRBLKSIZ) now has
conflicting spelling.
1997-03-29 12:40:20 +00:00
Bruce Evans 00780cef44 Define our own version of DIRBLKSIZ instead of (ab)using ufs's value.
Use the same value of 512 (ufs actually uses DEV_BSIZE).  There are
too many versions of DIRBLKSIZ, one for ufs, one for ext2fs, one for
nfs, one for ibcs2, one for linux, one for applications, ... I think
nfs's DIRBLKSIZ needs to be a divisor of the directory blocks sizes
of all supported file systems.  There is also NFS_DIRBLKSIZ, which is
different from nfs's DIRBLKSIZ but is sometimes confused with it in
comments.

Removed a bogus #ifdef KERNEL that hid the tunable constants for nfs.
This came in undocumented with the Lite2 merge although it isn't in
Lite2.  It required more-bogus #define KERNEL's in fstat and pstat
to make the constants visible.

Restored a spelling fix from rev.1.17.

Removed duplicate #defines of all the the NFS mount option flags.
1997-03-29 12:34:33 +00:00
Peter Wemm e58a2e4c46 Be consistant with the other syscall makefile's handling of the default
target (ie: don't do anything accidently)
1997-03-29 11:17:26 +00:00
Peter Wemm 4a37393e95 Add a Makefile to build all three syscall tables 1997-03-29 11:15:09 +00:00
Peter Wemm 55a278acdd Make sure we touch all the temporary files at startup, because we assume
they were created later on.  This is not the case when processing
syscalls.isc in the ibcs2 area.  (It generates no declarations, it's
all either hidden (already prototyped elsewhere) or unimplemented).
1997-03-29 11:11:18 +00:00
Poul-Henning Kamp 3d4d8fe94d Sanitize APM a bit. Convert various #ifdef to id_flags instead.
You may want to add "flags 0x31" to apm0 if you have a lousy
implementation.  Read LINT.
1997-03-29 11:07:12 +00:00
Peter Wemm d30ea4f53b Fix the warning when compiling the SYSINIT hook due to function types. 1997-03-29 10:50:27 +00:00
Peter Wemm 2b81b1431e Forgot $Id$, break a long line 1997-03-29 10:48:49 +00:00
Peter Wemm 64f873e1f3 Add a Makefile for regenerating the syscall tables 1997-03-29 10:45:39 +00:00
Bruce Evans 83eab616cf Don't keep cpu interrupts enabled during the lookup in vm_page_zero_idle().
Lookup isn't done every time the system goes idle now, but it can still
take > 1800 instructions in the worst case, so if cpu interrupts are kept
disabled then it might lose 20 characters of sio input at 115200 bps.

Fixed style in vm_page_zero_idle().
1997-03-29 04:35:26 +00:00
KATO Takenori f37dd3ba03 Synchronize with sys/i386/i386/machdep.c revision 1.233. 1997-03-29 02:48:49 +00:00
KATO Takenori 66b1f423ac Synchronize with sys/i386/isa/syscons.c revision 1.207. 1997-03-29 02:46:28 +00:00
KATO Takenori a07ac8e453 Synchronize with sys/i386/isa/isa.c revision 1.80. 1997-03-29 02:43:49 +00:00
Poul-Henning Kamp 5482a9c5ca Don't break the nice symmetry of these messages with undue '>' chars. 1997-03-28 18:40:24 +00:00
Poul-Henning Kamp 0a07eccfdd Try to talk to the APM BIOS with version 1.2 if possible. 1997-03-28 18:38:19 +00:00
Bruce Evans b8fa61d129 Added a setjmp() and a longjmp() so that an unexpected trap inside
ddb isn't necessarily fatal.  You can now do silly things like
`call vprint' and `show map' without losing control.
1997-03-28 12:56:07 +00:00
Bruce Evans b825df51c6 Backed out rev.1.5. if %cs is bad, %eip may be bad, but this is no longer
fatal.
1997-03-28 12:46:52 +00:00
Bruce Evans 4b4aeb2591 Added a setjmp() so that an initial pc that points to unmapped memory
isn't fatal.  Backed out rev.1.6, which handled special cases of this.
1997-03-28 12:39:43 +00:00
Joerg Wunsch 403d7829ac Something long overdue: compile inb() and outb() into the kernel as
functions if DDB is available.  The remaining occurences are usually
only inlined and thus not available in DDB.

I'm sure Bruce will have 23 additions to these 30 lines of code, but
at least it's a starting point. ;-)
1997-03-28 12:37:44 +00:00
Kazutaka YOKOTA 31774f6d83 Interim patch/kludge for keyboard lock-up when `kbdcontrol' tries to
change typematic rate, or the X server (XFree86 or Accelerated X)
starts up.

So far, there have been two independent reports from Dell Latitude XPi
notebook/laptop owners. The Latitude seems to be the only system which
suffers from this problem.  (I don't know the problem is with the
entire Latitude line or with only some Latitude models) No problem
report has been heard about other systems (I certainly cannot
reproduce the problem in my -current and 2.2 systems).

In 3.0-CURRENT, 2.2-RELEASE and 2.2-GAMMA-970310, when programming the
keyboard LED/repeat-rate, `set_keyboard()' in `syscons' tells the
keyboard controller not to generate keyboard interrupt (IRQ1) and then
enable tty interrupts, expecting the keyboard interrupt doesn't occur.

It appears that somehow Latitude's keyboard controller still generates
the keyboard interrupt thereafter, and `set_keyboard()' doesn't see
the return code from the keyboard because it is consumed by the
keyboard interrupt handler.

The patch entirely disables tty interrupts while setting LED and
typematic rate in `set_keyboard()', making the routine behave more
like the previous versions of `syscons' (versions in 2.1.X and
2.2-ALPHA, -BETA, and some -GAMMAs). The reporter said this patch
eliminated the problem.

(I also found another typo/bug, but the reporter and I found that it
wasn't the cause of the problem...)

This should go into RELENG_2_2.
1997-03-28 10:11:24 +00:00
Andrey A. Chernov e5df661c83 Remove recently commited support for iobase == -2 ("port none")
is is really probe routine task (return -1 for no ports)
1997-03-28 01:02:17 +00:00
Guido van Rooij 394da4c167 Add code that will reject nfs requests in teh kernel from nonprivileged
ports. This option will be automatically set/cleraed when mount is run
without/with the -n option.
Reviewed by:	Doug Rabson
1997-03-27 20:01:07 +00:00
Andrey A. Chernov 5fba67d120 Add "conflicts" to sbmidi0 since configured irq passed back to isa
and conflict with sb0 irq.

NOTE: existen configurations require "conflicts" adding to sbmidi0 now
1997-03-26 17:46:03 +00:00
Andrey A. Chernov 5c0c82997e Check sb0 configured in probe routine first
Pass configured irq back to isa
1997-03-26 17:41:16 +00:00
Andrey A. Chernov 348a8a6aab Add "conflicts" to sbxvi0 since all information now passed to isa
and conflict with sb0 happens.

NOTE: it affects existen configurations, add "conflicts" to sbxvi0 line
if you see probe error
1997-03-26 17:20:24 +00:00
Andrey A. Chernov cc13c79696 Pass configured irq and ports number back to isa 1997-03-26 17:14:21 +00:00
Andrey A. Chernov 7ee2669b4c Allow low level probe routine pass configured information back to isa 1997-03-26 17:12:31 +00:00
Joerg Wunsch 5be8af9286 Bring the dev/pdq entries into alphabetical order.
Forgotten by:	joerg :)
1997-03-26 17:00:36 +00:00
Andrey A. Chernov add8f4123b Don't trick with opl0 address since we have conflicts keyword 1997-03-26 16:10:43 +00:00
Andrey A. Chernov 88bbadf749 Return ports number in probe now 1997-03-26 16:07:20 +00:00
Andrey A. Chernov 2a64e5d6b8 Return ports number in probe now 1997-03-26 15:57:08 +00:00
Andrey A. Chernov fb04706fc7 Fix probe wrapper to pass ports number from low level probe 1997-03-26 15:56:21 +00:00
KATO Takenori e0762592a1 Synchronize with sys/i386/i386/machdep.c revision 1.232. 1997-03-26 07:03:30 +00:00
Mike Pritchard 89b37cfe4b Change sigreturn() to return EFAULT if it is passed an
address outside of the process's address space.
Now it matches its man page :-).  Closes PR# 2682.

Discussed with: bde
Submitted by:	Jonathan Lemon <jlemon@americantv.com>
1997-03-25 23:43:01 +00:00
Stefan Eßer 6072387d65 Fix printing of map sizes: large numbers got a negative sign before. 1997-03-25 19:12:08 +00:00
Stefan Eßer af78f012fd Improve probe message for generic PCI->xxx bridge chips.
Submitted by:	phk
1997-03-25 19:03:04 +00:00
Stefan Eßer ee88645781 Add a few vendor IDs and class and sub-class encodings.
Submitted by:	phk
1997-03-25 19:01:46 +00:00
Peter Wemm 17a8bb9de0 Add missing $Id$
Note; the RCS file has also been reconstructed to have a CSRG vendor branch.
1997-03-25 17:11:30 +00:00
Peter Wemm 3af1495424 Add missing $Id$
Please note, I have reconstructed the RCS file for this file so that it
has a CSRG vendor branch again.
1997-03-25 17:09:18 +00:00
Peter Wemm 356b94e0d3 Replace original rev 1.3; Author: bde; Date: 1997/02/25 17:24:43;
Fix counting of simplelocks in SIMPLELOCK_DEBUG
Fix style regression
1997-03-25 16:38:01 +00:00
Peter Wemm 4bdb9b1168 Replace original rev 1.2; Author: mpp; Date: 1997/02/12 06:52:30
Add missing #include <sys/systm.h>
1997-03-25 16:36:35 +00:00
Peter Wemm 01687822f0 Replace original rev 1.2; Author: mpp; Date: 1997/02/12 06:52:47
- add missing prototype for lockmgr_printinfo()
1997-03-25 16:35:07 +00:00
Peter Wemm a1ce9d5c33 Replace original revision 1.1; Author dyson; Date: 1997/02/10 02:28:15
Changes from Lite2:
- DEBUG -> SIMPLELOCK_DEBUG
- cosmetic fixes
- bzero of lock at init time -> explicit init of members.
1997-03-25 16:32:46 +00:00
Peter Wemm 6f3ca62e56 This commit was generated by cvs2svn to compensate for changes in r24269,
which included commits to RCS files with non-trunk default branches.
1997-03-25 16:27:20 +00:00
Peter Wemm a88eddbd2e Import 4.4BSD-Lite2 onto CSRG branch 1997-03-25 16:27:20 +00:00
Peter Wemm 53bf4bb2cf Import 4.4BSD-Lite2 onto CSRG branch 1997-03-25 16:27:20 +00:00
David Greenman 6318197e68 Made a couple of minor optimizations that improve performance of the
common case of the interrupt routine by about 20%.
1997-03-25 14:54:38 +00:00
KATO Takenori a8032951a0 Fixed reset port address for PC-9801-108 card. 1997-03-25 10:06:41 +00:00
KATO Takenori e41d6d04fc Synchronize with sys/i386/isa/isa.c revision 1.79. 1997-03-25 10:04:50 +00:00
Peter Wemm 476b25e22e Use the correct (relative to the implementation) ordering of args in
the VOP_LINK() calls, Closes PR#3064

Submitted by: bde
1997-03-25 05:13:40 +00:00
Peter Wemm 289c56e81e The local fs interface does not allow link()/unlink() of directories,
do not allow a remote nfs client to cause local fs corruption either.
1997-03-25 05:08:28 +00:00
Steve Passe 2fab5f6edd "Louis A. Mamakos" <louie@TransSys.COM> new bt848 struct
Randall Hopper <rhh@ct.picker.com> GHUE/GBRIGHT bug
Louis Mamakos made a new bt848 struct, including massive changes to the entire
body of code, substituting array offsets with struct members.

Randall Hopper aadded fixes of BT848_GHUE & BT848_GBRIG.

I (fsmp):
  added polled hardware i2c routines,
  removed all existing software i2c routines.
  added  eeprom support.
1997-03-25 04:18:24 +00:00
Andrey A. Chernov 588a8fcc98 Use FreeBSD-style attach message 1997-03-25 04:16:25 +00:00
Steve Passe 0e23e1a104 added support for EEProms writing/reading. 1997-03-25 04:11:13 +00:00
Andrey A. Chernov 0baa5ad9b2 Use port? for sbxvi0 since it is autoconfigured from sb0
Change sb0 irq from 7 to 5 since 5 is Creative default now.
1997-03-25 03:38:33 +00:00
Andrey A. Chernov 8c41947662 Copy io_base configuration address from sb config.
This change is cosmetique.
1997-03-25 03:32:31 +00:00
Andrey A. Chernov e4960ae4f5 Replace more verbose "at <not configured>" with less verbose "at ?",
we don't need much attention here, because this diagnostic printed first
and then card will be configured.
1997-03-25 03:29:40 +00:00
Andrey A. Chernov 70b57d05df Follow config intention for iobase:
print "at <not configured>" for iobase == -1 (autodetect not happens)
and not print anything for iobase == -2 (none)
Old code treat this two special config numbers as big port numbers.
1997-03-25 03:13:05 +00:00
David Nugent 117ffcde76 Remove unneeded prototype (and warning) for stlintr(). 1997-03-24 21:38:51 +00:00
Justin T. Gibbs c2df2e4bc2 Fix a fencepost error in ahc_find_scb that could cause us to wrongfully
find an SCB still down on the card that was paged out.  This only affects
error recovery.

Submitted by: Daniel M. Eischen <deischen@iworks.InterWorks.org>
1997-03-24 17:42:25 +00:00
Bruce Evans e4602ad9e5 Don't include <sys/ioctl.h> in the kernel. Stage 10 (final). Warn if
<sys/ioctl.h> is included in the kernel.  It still compiles.

This set of changes reduces the number of dependencies in LINT/.depend
from about 31000 to about 30000.  This should make LINT kernels
compile a whole 1% faster.  Further reductions to less than 20000
dependencies can easily be made.  E.g., 20 headers of nested spam
from <sys/param.h> for 500 object files gives 10000 dependencies;
less than half of these are real.
1997-03-24 12:48:46 +00:00
Bruce Evans 3a32c6706b Don't include <sys/ioctl.h> in the kernel. Stage 9: same changes
in pc98 as in isa.
1997-03-24 12:29:48 +00:00
Bruce Evans 528f627f00 Don't include <sys/ioctl.h> in the kernel. Stage 6: include
<sys/filio.h>, <sys/sockio.h> and <sys/ttycom.h> instead of
<sys/ioctl.h> in a couple of files.  This is still only 1/3
as spammish as <sys/ioctl.h> - 5 or 6 old tty ioctl headers
aren't needed.
1997-03-24 12:12:36 +00:00
Bruce Evans afd2f6c218 Don't include <sys/ioctl.h> in the kernel. Stage 5: include
<sys/ioctl_compat.h> and sometimes <sys/filio.h> instead of
<sys/ioctl.h> in tty-related files.  <sys/ttycom.h> is still
usually imported bogusly via <sys/termios.h>.
1997-03-24 12:03:06 +00:00
Bruce Evans 2098241054 Don't include <sys/ioctl.h> in the kernel. Stage 4: include
<sys/ttycom.h> and sometimes <sys/filio.h> instead of <sys/ioctl.h>
in miscellaneous files.  Most of these files have nothing to do
with ttys but need to include <sys/ttycom.h> to get the definitions
of TIOC[SG]PGRP which are (ab)used to convert F[SG]ETOWN fcntls into
ioctls.
1997-03-24 11:52:29 +00:00
Bruce Evans 71455815cc Don't include <sys/ioctl.h> in the kernel. Stage 3: include
<sys/filio.h> instead of <sys/ioctl.h> in non-network non-tty files.
1997-03-24 11:37:53 +00:00
Bruce Evans 51a534883a Don't include <sys/ioctl.h> in the kernel. Stage 2: include
<sys/sockio.h> instead of <sys/ioctl.h> in network files.
1997-03-24 11:33:46 +00:00
Bruce Evans fce002fdef Don't include <sys/ioctl.h> in the kernel. Stage 1: don't include
it when it is not used.  In most cases, the reasons for including it
went away when the special ioctl headers became self-sufficient.
1997-03-24 11:25:10 +00:00
Bruce Evans cb07fc9803 Don't default to (wrong) SCO definitions for _IOR() etc. if <sys/ioctl.h>
doesn't happen to be included before this header.

This header was missed in previous cleanups because it didn't include
<sys/ioctl.h> or <sys/ioccom.h>.  Clean it now:
- #include <sys/types.h> since it is necessary to make the header self-
  sufficient (there are a couple of u_char's).
- uniformized idempotency ifdef.  Copied the style in the 4.4Lite
  ioctl headers.
1997-03-24 11:07:52 +00:00
David Nugent e825ea20dd Make stlintr() public to allow correct linkage. 1997-03-24 07:25:31 +00:00
KATO Takenori 5fa4a05818 Fix typo.
Submitted by:	Bruce Evans <bde@zeta.org.au>
1997-03-24 07:23:05 +00:00
KATO Takenori 507cf9c96e Merge PC-98 code int i386/isa/ft.c. 1997-03-24 07:20:35 +00:00
Justin T. Gibbs 7d951713e8 Fix a nasty bug that meant a QUEUE_FULL status would result in a lost
SCB.  This is probably a main reason for the recent reports of timeouts.
1997-03-24 05:05:18 +00:00
Justin T. Gibbs 23e11becca Re-arrange the code to upload an SCB to ensure that there is at least
on instruction between the last load into the DFIFO and enabling the DMA.
During back to back SCB DMA, it was possible to hang the card.
1997-03-24 05:02:55 +00:00
Bruce Evans a02b0b9694 Removed nested #includes of <scsi/scsi_debug.h> and <scsi/scsi_driver.h>
from <scsi/scsiconf.h> and fixed everything that depended on them.
(Missed this one.)
1997-03-24 04:26:46 +00:00
Bruce Evans 90b42d7e40 Fixed corrupted newline and corrupted tab in previous commit. 1997-03-24 03:19:37 +00:00
KATO Takenori d1dd81c99f Fixed corrupted CFLAGS definition. (Deleted harmful backslash.)
Submitted by:	H. Nokubi <h-nokubi@nmit.mt.nec.co.jp>
1997-03-24 02:38:48 +00:00
Justin T. Gibbs 65e5a3a9df free_xs must be called at splbio(). This is usually the case since the main
caller is scsi_done which the controller interrupt handlers call.  In the
case of a non-buffer based transaction, the xs structure is freed by the
process that initiated the transfer in scsi_scsi_cmd.  In this case, an
explicit splbio/splx pair around the call to free_xs is required.  Without
the splbio protection, the xs free list could be corrupted, and the type
driver's start routine might run without spl protection.

Submitted by:	Tor Egge <Tor.Egge@idt.ntnu.no>
Obtained from: PR kern/2891
1997-03-24 01:46:15 +00:00
Guido van Rooij 8f89943eda Add generation number randomization. Newly created filesystems wil now
automatically have random generation numbers. The kenel way of handling those
also changed. Further it is advised to run fsirand on all your nfs exported
filesystems. the code is mostly copied from OpenBSD, with the randomization
chanegd to use /dev/urandom
Reviewed by:	Garrett
Obtained from: OpenBSD
1997-03-23 20:08:22 +00:00
KATO Takenori 56be183376 Created new section `CPU OPTIONS'. CPU classes and math emulator are
moved to there.  Options for CPU feature is also described there.
1997-03-23 11:08:28 +00:00
Bruce Evans 6617929964 Removed nested #includes of <scsi/scsi_debug.h> and <scsi/scsi_driver.h>
from <scsi/scsiconf.h> and fixed everything that depended on them.
1997-03-23 06:33:55 +00:00
Bruce Evans db0ac821f2 Removed nested #includes of <scsi/scsi_debug.h> and <scsi/scsi_driver.h>
from <scsi/scsiconf.h> and fixed everything that depended on them.
1997-03-23 06:26:47 +00:00
KATO Takenori 14667a26c6 Added Accton EN1207-TX support. 1997-03-23 05:10:14 +00:00
Bruce Evans 08febfa741 Removed nested #include of <sys/conf.h> from <scsi/scsi_driver.h>
and fixed everything that depended on getting it from the wrong
place.  Most of the broken things actually only depended on getting
the declaration of their interrupt handler from "ioconf.h".
1997-03-23 04:40:00 +00:00
Bruce Evans fe10481de8 Don't #include <sys/fcntl.h> in <sys/file.h> if KERNEL is defined.
Fixed everything that depended on getting fcntl.h stuff from the wrong
place.  Most things don't depend on file.h stuff at all.
1997-03-23 03:49:00 +00:00
Bruce Evans 3ac4d1ef0c Don't #include <sys/fcntl.h> in <sys/file.h> if KERNEL is defined.
Fixed everything that depended on getting fcntl.h stuff from the wrong
place.  Most things don't depend on file.h stuff at all.
1997-03-23 03:37:54 +00:00
John Dyson c5d593ae63 Fix a significant error in the accounting for pre-zeroed pages. This
is a candidate for RELENG_2_2...
1997-03-23 02:44:54 +00:00
Bruce Evans 84232bd337 Merged the rest of lfs from Lite2. It compiles (uncleanly) but is as
unlikely to work as before.
1997-03-23 00:45:27 +00:00
Mike Pritchard 9a8f4a4c93 Restore Bruce's original comment. It seems that "iff" = if and only if,
and is not a typo.  It is used other places in the kernel, too.
1997-03-22 20:34:21 +00:00
KATO Takenori a8e282d6c3 Oops, I forgot to `cvs add'. This file is a part of new CPU
identification and initialization routines.
1997-03-22 19:00:36 +00:00
KATO Takenori 4c024bbdf8 Improved CPU identification and initialization routines. This
supports All Cyrix CPUs, IBM Blue Lightning CPU and NexGen (now AMD)
Nx586 CPU, and initialize special registers of Cyrix CPU and msr of
IBM Blue Lightning CPU.

If revision of Cyrix 6x86 CPU < 2.7, CPU cache is enabled in
write-through mode.  This can be disabled by kernel configuration
options.

Reviewed by:	Bruce Evans <bde@freebsd.org> and
            	Jordan K. Hubbard <jkh@freebsd.org>
1997-03-22 18:54:54 +00:00
Mike Pritchard 269ebc8621 Fix a typo in a comment of a recent commit. 1997-03-22 16:52:19 +00:00
Bruce Evans 20cb3c714b Merged enough of lfs from Lite2 for mkdep of LINT to work again. 1997-03-22 09:33:55 +00:00
Bruce Evans 774fce94c0 Removed volatile' from declaration of time', and removed the resulting
null casts.  `time' is nonvolatile for accesses within a region locked
by splclock()/splx().  Accesses outside such a region are invalid, and
splx() must have the side effect of potentially changing all global
variables (since there are hundreds of sort of volatile variables like
`time'), so declaring `time' as volatile didn't have any real benefits.
1997-03-22 08:03:51 +00:00
Bruce Evans 3c81694426 Fixed some invalid (non-atomic) accesses to `time', mostly ones of the
form `tv = time'.  Use a new function gettime().  The current version
just forces atomicicity without fixing precision or efficiency bugs.
Simplified some related valid accesses by using the central function.
1997-03-22 06:53:45 +00:00
John Dyson 8e56e56134 Decrease the latency/overhead in the prezero code when there is
an adequate number of prezeroed pages.
1997-03-22 04:28:16 +00:00
Bruce Evans c16cb2c78b Backed out rev.1.27, which broke unmounting of mfs and caused panics
on shutdown.

Should not have been in 2.2 (the buggy last minute change, that is).
1997-03-22 03:59:46 +00:00
Steve Passe e75839864d Submitted by: Michael Petry <petry@netwolf.NetMasters.com>
Michael submitted code to activate the audio muxes.

fsmp:
 extended those changes for different boards.
 auto-detection of board types.
 auto-detection of tuner types.
 auto-detection of stereo option.
1997-03-21 17:33:03 +00:00
Steve Passe d830eb7d9f Submitted by: Michael Petry <petry@netwolf.NetMasters.com>
Michael submitted code to activate the audio muxes.

fsmp:
 extended those changes for different boards.
 auto-detection of board types.
 auto-detection of tuner types.
 auto-detection of stereo option
1997-03-21 17:29:54 +00:00
Bill Paul 0b788fa1da Add support to sendmsg()/recvmsg() for passing credentials between
processes using AF_LOCAL sockets. This hack is going to be used with
Secure RPC to duplicate a feature of STREAMS which has no real counterpart
in sockets (with STREAMS/TLI, you can apparently use t_getinfo() to learn
UID of a local process on the other side of a transport endpoint).

What happens is this: the client sets up a sendmsg() call with ancillary
data using the SCM_CREDS socket-level control message type. It does not
need to fill in the structure. When the kernel notices the data,
unp_internalize() fills in the cmesgcred structure with the sending
process' credentials (UID, EUID, GID, and ancillary groups). This data
is later delivered to the receiving process. The receiver can then
perform the follwing tests:

- Did the client send ancillary data?
	o Yes, proceed.
	o No, refuse to authenticate the client.

- The the client send data of type SCM_CREDS?
	o Yes, proceed.
	o No, refuse to authenticate the client.

- Is the cmsgcred structure the right size?
	o Yes, proceed.
	o No, signal a possible error.

The receiver can now inspect the credential information and use it to
authenticate the client.
1997-03-21 16:12:32 +00:00
David Greenman 6ebc315326 Added support for newer cards that have the DP83840A PHY chip.
Fixed a bug in fxp_mdi_write - a hex number was missing a preceding 0x
and this was causing the routine to not wait for a PHY write to complete.
Added support for link0, link1, and link2 flags to toggle auto-
negotiation, 10/100, and half/full duplex:

link0	disable auto-negotiation

	When set, these flags then have meaning:

	-link1	10Mbps
	link1	100Mbps
	-link2	half duplex
	link2	full duplex

...needs a manual page.
1997-03-21 08:00:13 +00:00
Mike Pritchard 35846a8163 Typo police. 1997-03-20 16:33:15 +00:00
John Polstra cf49f43912 Add backward compatibility so that static executables built on
modern FreeBSD systems will syslog properly on older systems that
still name the logging socket "/dev/log".  This includes pre-2.2
versions of FreeBSD as well as BSD/OS systems.  If the connect to
"/var/run/log" fails, the function now tries to connect to
"/dev/log" as a fallback.
1997-03-20 16:28:27 +00:00
KATO Takenori 0908b6ff4a Added Allied Telesis CenterCOM LA100-PCI support. Currently, full
duplex mode doesn't work.
1997-03-20 07:25:22 +00:00
Steve Passe 0f4a397771 additions for table-driven frequency calculation.
addition of colorbar ioctl.
removed unneeded disable_intr()/enable_intr() wrappers in i2c code.
minor cleanup.
1997-03-19 19:10:45 +00:00
Steve Passe 535341aacb additions for table-driven frequency calculation.
addition of colorbar ioctl.
1997-03-19 19:08:31 +00:00
KATO Takenori 2f284f07f8 Synchronize with sys/i386/conf/files.i386 revision 1.156. 1997-03-19 16:14:25 +00:00
Bruce Evans 3628c5b631 Only export ioctl-related stuff to applications. Include prerequisite
headers (like most other ioctl-related headers).

Didn't fix spelling errors and other warts.
1997-03-19 04:37:26 +00:00
David E. O'Brien c85cfdb229 typo (nthe --> the) 1997-03-19 02:59:02 +00:00
Peter Wemm c5d5416c2d MAXDIRSIZE is (or would be) used in fsck. It's a sanity check. 1997-03-18 19:52:17 +00:00
Peter Wemm cc9d89901f Restore the lost MNT_LOCAL flag twiddle. Lite2 has a different mechanism
of setting it (compiled into vfs_conf.c), but we have a dynamic system
in place.  This could probably be better done via a runtime configure
flag in the VFS_SET() VFS declaration, perhaps VFCF_LOCAL, and have the
VFS code propagate this down into MNT_LOCAL at mount time.  The other FS's
would need to be updated, havinf UFS and MSDOSFS filesystems without
MNT_LOCAL breaks a few things..  the man page rebuild scans for local
filesystems and currently fails, I suspect that other tools like find
and tar with their "local filesystem only" modes might be affected.
1997-03-18 19:50:12 +00:00
Justin T. Gibbs 1c147cc352 aic7xxx.seq:
Stick 4 more, twin channel only, instructions behind
	.if ( TWIN_CHANNEL)

aic7xxx_asm.c:
	Add the -O options which allows the specification of which options
	to include in a program listing.  This makes it possible to easily
	determine the address of any instruction in the program across
	different hardware/option configurations.  Updated usage() as well.
1997-03-18 19:18:39 +00:00
Steve Passe ba2c23286f Submitted by: Doug White <dwhite@gdi.uoregon.edu>
I broke the cable tuning with my 'TEST_A' code.  Remove TEST_A define
till I finish this change for both tuning modes.  Note that this
will effectively break the new TVTUNER_SETFREQ/TVTUNER_GETFREQ ioctl()s.
These aren't used by anyone but me yet (attempt to provide full resolution
fine tuning for "fringe" stations) so it should be no problem
1997-03-17 17:41:24 +00:00
David Greenman dccee1a193 Fixed two deficiencies in the driver that have existed since it was
written:

1) Full duplex mode is now supported (and works!)
2) The 10Mbps-only PCI Pro/10 should now work (untested, however)

Thanks to Justin Gibbs for providing a PCI bus analyzer trace while the
Intel Windows driver was configuring the board...this made it possible
to figure out the mystery bit that I wasn't setting in the PHY for full
duplex to work.
1997-03-17 11:08:16 +00:00
Nate Williams 55e1a05578 Don't try to lint the gcc extension byte-swapping macros.
Submitted by:	Eivind Eklund <eivind@dimaga.com>
1997-03-17 00:51:51 +00:00
Bruce Evans 444f003cca Fixed null pointer panic in devtotty(). Fixed bounds checking in
devtotty().  devtotty() must check its arg carefully since the arg is
supplied as ioctl data.  This should fix PR3004.

Renamed devtotty() to snpdevtotty().
1997-03-16 19:11:40 +00:00
Justin T. Gibbs 34564ce31e Make this whitespace compatible with the change that I correctly committed
to the 2.2 branch for the new aic7xxx assembler.
1997-03-16 19:06:45 +00:00
Bruce Evans 60b161a92a Don't depend on <sys/types.h> being (bogusly) included by <stdio.h>. 1997-03-16 17:31:59 +00:00
Bruce Evans 54c4d30615 Fixed broken line continuation in the previous revision. Config apparently
has buggy backslash-newline handling.  Avoid it by using whitespace before
backslash-newline.
1997-03-16 17:25:53 +00:00
Bruce Evans 0617e8fdf6 Fixed missing line-continuation backslash in the previous revision. 1997-03-16 17:14:04 +00:00
KATO Takenori 3abc0e5cd9 Synchronize with sys/i386/boot/biosboot/sys.c revision 1.19. 1997-03-16 10:57:54 +00:00
Steve Passe d380dd6d8e patches for bt848 specific hue/bright/contrast/satu/satv. 1997-03-16 07:40:01 +00:00
Steve Passe 55566fdc2f Submitted by: Amancio Hasty <hasty@rah.star-gate.com>
addition of bt848 specific ioctl()s for hue/bright/contrast/satu/satv.

patches by Amancio Hasty to fix "screen freeze" problem.
1997-03-16 07:37:23 +00:00
Justin T. Gibbs 65c303b1b1 Missed one. 1997-03-16 07:28:30 +00:00
Justin T. Gibbs 4a2a38f682 The register definitions are now in the compile directory. 1997-03-16 07:12:36 +00:00
Justin T. Gibbs f9380a619e Adapt to some changes in the register definitions. Clear the selection
enable in SCSISEQ during error recovery to deal with the way the
sequencer leaves selections enabled now.  Add code to perform "patching"
during sequencer program download.

Spelling fixes obtained from NetBSD.
1997-03-16 07:12:07 +00:00
Justin T. Gibbs 25f864c494 The register definition file is now in the compile directory. 1997-03-16 07:09:32 +00:00
Justin T. Gibbs 8733b9a7ca Adapt build rules to new aic7xxx seqeuncer assembler. 1997-03-16 07:09:01 +00:00
Justin T. Gibbs c5cb388883 Makefile gram.y scan.l sequencer.h symbol.c symbol.h aic7xxx_asm.c:
New sequencer assembler for the aic7xxx adapters.  This assembler
	performs some amount of register type checking, allows bit
	manipulation of symbolic constants, and generates "patch tables"
	for conditionalized downloading of portions of the program.
	This makes it easier to take full advantage of the different
	features of the aic7xxx cards without imposing run time penalies
	or being bound to the small memory footprints of the low end
	cards for features like target mode.

aic7xxx.reg:
	New, assembler parsed, register definitions fo the aic7xxx cards.
	This was done primarily in anticipation of 7810 support which
	will have a different register layout, but should be able to use
	the same assembler.  The kernel aic7xxx driver consumes a generated
	file in the compile directory to get the definitions of the register
	locations.

aic7xxx.seq:
	Convert to the slighly different syntax of the new assembler.

	Conditionalize SCB_PAGING, ultra, and twin features which shaves
	quite a bit of space once the program is downloaded.

	Add code to leave the selection hardware enabled during reconnects
	that win bus arbitration.  This ensures that we will rearbitrate
	as soon as the bus goes free instead of delaying for a bit.

	When we expect the bus to go free, perform all of the cleanup
	associated with that event "up front" and enter a loop awaiting
	bus free.  If we see a REQ first, complain, but attempt to
	continue.  This will hopefully address, or at least help diagnose,
	the "target didn't send identify" messages that have been reported.

Spelling corrections obtained from NetBSD.
1997-03-16 07:08:19 +00:00
Justin T. Gibbs 2edd1d6696 Add depend rule for the now compile time generated aic7xxx register file. 1997-03-16 06:52:27 +00:00
Joerg Wunsch 1355add51f Fix from Matt for the problem described in PR # kern/2990: ``DEC FDDI
is a little *too* promiscuous''

Also a 2.2 candidate, again, after testing.

Submitted by:	Matt Thomas <matt@lkg.dec.com>
1997-03-15 19:58:43 +00:00
Søren Schmidt 6ae8358759 Fix support for != 512 byte sector devices.
Restores the use of SBLOCK instead of the BSOFF/sectorsize calculation.
Using SBLOCK is bogus however in that it uses DEV_BSIZE instead of
the actual sector size, but that is taken care of in other places.
Changing the SBLOCK would be better, but it affects the system
in other places, and doing it this way makes it possible to
use filesystems that was made before the lite2 merge.
1997-03-15 18:58:10 +00:00
Bruce Evans c24b67b188 Don't attempt to read past EOF.
Saved enough bytes to make room for this bloat (testing poff < inode.i_size
takes 56 bytes!) by copying fs to a local variable.
1997-03-15 16:49:51 +00:00
KATO Takenori dfbc54730c Synchronize with sys/i386/conf/GNERIC revision up to 1.88. 1997-03-15 15:58:43 +00:00
KATO Takenori 38f8e5fbc7 Synchronize with sys/i386/i386/userconfig.c revision 1.85. 1997-03-15 15:44:05 +00:00
Garrett Wollman 7b187005d1 Add protoswitch entries for shortcut send/receive. Correct
a few misleading comments, and move allthe struct tag
forward declarations to be in one place.
1997-03-14 16:51:28 +00:00
Bruce Evans 25292acb24 Updated comment about npx0.
Added obsolete option GATEWAY so that kern_opt.c gets tested.

Added undocumented options LOCKF_DEBUG and SIMPLELOCK_DEBUG so
that these options get tested.  The addition of LOCKF_DEBUG shows
that all of kern/kern_lockf.c shouldn't have been moved from ufs.
The debugging parts are very fs-dependent.
1997-03-13 19:23:27 +00:00
Bruce Evans a92a5c234e Quoted CMD640. It's still missing from options.i386.
Removed stale comment saying that npx0 is mandatory.
1997-03-13 19:03:58 +00:00
Joerg Wunsch 5cf816c239 Various stylistic improvements regarding num_eisa_slots & co.:
. properly declare the variable in in a .h file, as opposed to
  using a private extern declaration in userconfig.c;
. move the definition of EISA_SLOTS and therefore the inclusion of
  opt_eisa.h into eisaconf.c.
1997-03-13 18:04:05 +00:00
KATO Takenori 904385e65b Synchornize with sys/i386/conf/options.i386 revision 1.37. 1997-03-13 17:04:23 +00:00
KATO Takenori b5ff11dbb6 Synchronize with sys/i386/isa/wd.c revision 1.126. 1997-03-13 17:00:27 +00:00
KATO Takenori 77fd6eeaf8 Synchronize with sys/i386/boot/biosboot/boot.c revision 1.64. 1997-03-13 16:58:15 +00:00
David Nugent 4511a3a921 Submitted by: Greg Ungerer <gerg@stallion.oz.au>
Update to version 1.0.0 of stallion.c from author.
1997-03-13 04:13:45 +00:00
David Nugent 1f77b941e5 Submitted by: Greg Ungerer <gerg@stallion.oz.au>
Update istallion driver to version 1.0.0 from author.
1997-03-13 03:51:25 +00:00
KATO Takenori 242b8c5441 Change #ifdef FreeBSD' to #ifdef __FreeBSD__'.
Submitted by:	H. Nokubi <h-nokubi@nmit.mt.nec.co.jp>
1997-03-13 02:10:21 +00:00
KATO Takenori c4d420eee3 Added `\' (backslash) at the end of line in the CFLAGS definition.
Submitted by:	H. Nokubi <h-nokubi@nmit.mt.nec.co.jp>
1997-03-13 02:04:47 +00:00
Stefan Eßer 09d5def9ce Activate CMD640 workaround 1997-03-12 19:59:58 +00:00
Stefan Eßer 2928e6b5fd Add option CMD640 which is required to use both channels of that
EIDE chip
1997-03-12 19:11:59 +00:00
Stefan Eßer f5cd278ca4 Add wdc_p.c for support of the CMD640 PCI EIDE chip. 1997-03-12 19:10:27 +00:00
Bruce Evans 051fc6fab1 Fixed setting of default kernel name when there is no boot.config file.
Didn't fix a more serious problem when boot.config is empty - read()
can't handle empty files.

Reported by:	Chris Timmons <skynyrd@opus.cts.cwu.edu>
1997-03-12 18:48:31 +00:00
Joerg Wunsch 1b0d314332 Since i don't see that anybody is implementing a more correct EISA
probing anytime soon, make EISA_SLOTS a fully supported option.  It's
required for the HP NetServer LC series machines.

Next stop: make dset(8) aware of it as well.
1997-03-12 17:41:35 +00:00
Stefan Eßer e93e9e7392 Add support for the buggy CMD640B PCI EIDE controller chip, which
can't perform overlapping commands on both of its channels.

To enable the CMD640B work-around, the kernel must be compiled with
"options CMD640". Without that option there should be no difference
in the code produced compared to the previous revision of wd.c.

Submitted by:	Wolfgang Helbig <helbig@ba-stuttgart.de>
1997-03-11 23:17:28 +00:00
Bruce Evans ed637f8f5f Fixed clist limits. I got them wrong several years ago in rev.1.9
(1994/11/26).  Packets with more than approximately 128 0xc0's or
0xdb's in them were untransmittable.
1997-03-11 19:39:21 +00:00
Joerg Wunsch ad27a972d0 Retrofit Bruce's changes from rev 1.7. 1997-03-11 19:38:02 +00:00
KATO Takenori 078e650eb4 Synchronize with sys/i386/i386/userconfig.c revision 1.84. 1997-03-11 16:19:55 +00:00
KATO Takenori ef5c2a7815 Synchronize with sys/i386/conf/majors.i386 revision 1.14. 1997-03-11 16:18:08 +00:00
Mike Smith 169b2e51e3 Avoid double-s when #conflicts drops from 10 to 9. 1997-03-11 07:11:46 +00:00
Joerg Wunsch 930bb1a4da Add a quirk entry for the HP6020i, after John has just confirmed that
it works now.

Submitted by:	jhay@zibbi.mikom.csir.co.za (John Hay)
1997-03-10 20:51:17 +00:00
Poul-Henning Kamp fdc58e30da Add char#80 xdcp, assigned to Chris Ficklin <chris@serengeti.com> 1997-03-10 20:25:45 +00:00
Mark Murray a30c77e886 Move this files* entry for the Brooktree TV driver toi the right 'files*'. 1997-03-10 17:55:49 +00:00
Mark Murray 51e053d6cc Initial import of the Brooktree PCI-TV drivers. I have not tested
these, they may not even compile. I am importing them on behalf
of the submitters.
Submitted by:	amancio, smp
1997-03-10 06:38:26 +00:00
KATO Takenori d025bca112 Makefile generates boths IBM-PC and PC-98 version of object code in
apm_init.inc.  The PC-98 version of object is included in `#ifdef
PC98'.

Pointed-out by:	URATA Shuichiro <s-urata@nmit.tmg.nec.co.jp>
1997-03-09 16:46:05 +00:00
KATO Takenori c8ac925d54 Added PC-98 specific function to get battery status.
Submitted by:	URATA Shuichiro <s-urata@nmit.tmg.nec.co.jp>
1997-03-09 16:40:13 +00:00
Bruce Evans 13a44161a2 Moved userland assembler macros from <machine/asmacros.h> to
<machine/asm.h>.
1997-03-09 13:57:33 +00:00
Bruce Evans 644ba7e84e Cloned src/lib/libc/i386/DEFS.h to create <machine/asm.h> for the i386.
The former file was too hard to get at from other parts of the src tree
and will go away.
1997-03-09 10:39:15 +00:00
Bruce Evans 7eff94279a YAMInTheWrongDirectionF22 (part of rev.1.28.2.3: set B_CLUSTEROK for
commits).
1997-03-09 10:21:26 +00:00
Mike Pritchard d0ad3d988a Update a number of routines to reflect the actual name
of the routine that caused the panic.
1997-03-09 06:10:36 +00:00
Mike Pritchard 5ace3b260a Update a number of panic messages to reflect the actual name
of the routine that caused the panic.
1997-03-09 06:00:44 +00:00
Bruce Evans 2a31d924ab Use the common nchstats struct instead of a private one for ncs_2passes
and ncs_pass2.  The public one is already used for other cd9660 statistics
and the private one was effectively invisible.
1997-03-08 16:09:38 +00:00
Bruce Evans 90106ad38b Fixed missing initialisation of vp->v_type for types Pfile and Pmem
in procfs_allocvp().  This fixes at least stat() of /proc/*/mem.

stat() of /proc/*/file already worked.  I think procfs_allocvp() isn't
actually called for type Pfile.
1997-03-08 16:06:34 +00:00
KATO Takenori 593b35ace1 Synchronize with sys/i386/boot/biosboot/Makefile revision 1.55. 1997-03-08 15:46:59 +00:00
Bruce Evans d8d6519c63 Fixed the hash formula. Lite2 doesn't have phashinit(), so Lite2's hash
formula uses `& nchash'.  This is very broken when nchash is a prime
number instead of 1 less than a power of 2, but the Lite2 formula was
merged in.

Merged some cosmetic changes from Lite2, rev.1.21 and Lite1.  The merge
was difficult because the Lite2 code is essentially ours (phk's) except
where Lite2 improved or broke it.

Summary of the Lite2 changes:
- in the copyright, phk's rights have been transferred to the Regents.
  This change should be reviewed.
- nchENOENT went away; the "no" vnode is now simply 0.
- comments were improved.
- style was "improved".
- goto instead of Fanatism (sic) was considered bad :-).
- there are some small changes to support whiteouts.
- new cache entries are added in more cases.  More work is required
  near here to change the hash table size if kern.desiredvnodes is
  changed using sysctl.
- rescanning of the hash bucket in cache_purgevfs() was removed.  This
  change should be reviewed.
1997-03-08 15:22:14 +00:00
Guido van Rooij dfd0621acc Fix style bugs and other bugs in the NFS fix. 1997-03-08 15:14:30 +00:00
John Dyson eb2c768ebb When removing IN_RECURSE support during the Lite/2 merge, read/write
to/from mmaped regions was broken.  This commit fixes the breakage, and
uses the new Lite/2 locking mechanisms.
1997-03-08 04:33:47 +00:00
John Dyson d6faa36b42 Remove unnecessary check for vp->v_mount being null. Pointed
out by BDE.
1997-03-07 14:40:54 +00:00
Kazutaka YOKOTA d36dc5e36b Made set_controller_command_byte() less verbose. It used to print a
debug message whenever one of lock keys were pressed, if the system
was started with the `-v' option.

Removed a couple of lines of dead code too.
1997-03-07 10:22:55 +00:00
Joerg Wunsch e843ad34c1 Fix a bogon in pcvt that caused a characterset designation to not take
effect immediately, but required a following (normally redundant) G0
into GL mapping.  This adds one layer of indirection (thus might make it
slower), but fixes the broken box character drawing in pcvt.

Hellmuth and Bruce are unfortunately too busy too review this right now,
but i wanna have it in 2.2 since it has often been asked in the past.
1997-03-07 08:56:00 +00:00
Joerg Wunsch f9ba24beed Fix the new (kbdio) keyboard layer to correctly work if PCVT_SCANSET == 2
even early in the boot process (boot -c or -d).

Submitted by:	yokota@zodiac.mech.utsunomiya-u.ac.jp (Kazutaka YOKOTA)
1997-03-07 08:53:16 +00:00
Gary Palmer 324d42ad57 Fix (I hope) the NFS hole. This is only compile tested.
Submitted by:	(partly) davids@SECNET.COM via BUGTRAQ
1997-03-07 07:42:41 +00:00
Joerg Wunsch 8a973ca81c Move pcvt towards using kbdio (finally!).
Warning: this won't work yet with PCVT_SCANSET=2 along in early
console mode (boot -c, or boot -d).

A big thanks to Kazutaka, and a word of apologies for delaying the
review for that long time...

Submitted by:	yokota@zodiac.mech.utsunomiya-u.ac.jp (Kazutaka YOKOTA)
1997-03-06 22:34:24 +00:00
Joerg Wunsch f357773315 Merge Jason Thorpe's updated changer stuff into the actual system.
Many things have been changing in the kernel since mid-1996, so there's
quite some amount of diffs here already.  It compiles, but i cannot
test it anywhere here.

2.2 candidate?

Closes PR # 1201.
1997-03-06 15:36:45 +00:00
KATO Takenori b95c15c20f Added missing i8251 code.
Submitted by:	H. Nokubi <h-nokubi@nmit.mt.nec.co.jp>
1997-03-06 15:07:04 +00:00
Stefan Eßer 81cf5d7aae improve pcibus_check: Only assume PCI if at least one PCI to anything bridge
on bus 0.
This fixes problems with EISA-only systems mistakenly being assumed to support PCI.
1997-03-05 20:52:00 +00:00
Bruce Evans c68fa33937 Try a no-wait malloc first in clist_alloc_cblocks(). If this fails, then
complain and blunder on.

Should be in 2.2, preferably with a better fix.
1997-03-05 16:45:01 +00:00
Bruce Evans a5c1768dd5 Made FPU stuff conditional on npx as well as I586_CPU. 1997-03-05 16:30:55 +00:00
KATO Takenori 85c57124b2 Synchronize with sys/i386/isa/clock.c revision 1.79. 1997-03-05 16:19:48 +00:00
Bruce Evans bdca44f670 Added -mno-486 to CFLAGS to force smaller code in case someone compiles
with CC="cc -m486".  This doesn't fix PR2381, since PR2381 is for 2.1.x.
1997-03-05 15:43:03 +00:00
Julian Elischer e990261c58 make the netatalk output routine matcy the prtotype used in the
protocol structure. Silences a warning from Gcc.
1997-03-05 09:17:38 +00:00
Bruce Evans 65ff42dd17 Only print clock calibration messages if the system was booted with -v.
Submitted by:	partly by gpalmer
1997-03-05 08:08:48 +00:00
Julian Elischer 499676df4d add a bunch of comments to describe what's going on.
This is some of the worst code I've had to wade through in
ages and I don't want to have to start from scratch again next time.

(I have a 2.2 version of these comments, can I commit them?)
1997-03-05 08:01:28 +00:00
David Greenman 2f2160da3b Fixed splbio problems in vinvalbuf. Closes PR#2875, although fixed
differently by me.
1997-03-05 04:54:54 +00:00
Mike Smith 789962659e Supply the mount point given to mfs_mount when getting a vnode for the
mount.  This may have been a contributor to the 'null v_mount in
fsync()' problem

This is another, perhaps slightly less urgent, 2.2 last-minute candidate.

Reviewed by:	sef
1997-03-05 01:57:54 +00:00
Mike Smith 3a558f83dd Check that vp->v_mount is non-null in fsync() before dereferencing it to
obtain the mountpoint's MNT_ASYNC flag.

This is a Very Definite Last-Minute 2.2 Bugfix Candidate.

Reviewed by:	sef
1997-03-05 01:42:14 +00:00
Gary Palmer 0b146b65d2 Back out the patch to break up the clock probe lines. Instead, follow
Bruce's suggestion of deleting "relative to mc146818A clock ",
thus shortening the line ...
1997-03-05 00:54:00 +00:00
Bruce Evans e4c4150e70 Fixed connection of vfs.ffs node to the sysctl tree. 1997-03-04 18:35:15 +00:00
Bruce Evans 4a8b966013 Attach vfs_sysctl() one level lower so that only the levels below
VFS_GENERIC aren't done in the FreeBSD way.  The previous commit
broke the nfs sysctls.
1997-03-04 18:31:56 +00:00
Gary Palmer 5c5e8d766c Split the rather long and line-wrapping clock probe messages on boot.
(2.2?)

Submitted by:	Mathew Dood <winter@jurai.net>
1997-03-04 09:24:01 +00:00
KATO Takenori 5db523b1d5 Fixed devfs code. Old code remained in pc98 tree.
Submitted by:	URATA Shuichiro <s-urata@nmit.tmg.nec.co.jp>
1997-03-04 06:39:02 +00:00
KATO Takenori 541de8d9a5 Synchronize with sys/i386/isa/syscons.c revision 1.205. 1997-03-04 06:25:54 +00:00
Andrey A. Chernov 53490b7634 Oops, fix typo. 1997-03-03 23:02:43 +00:00
Andrey A. Chernov 30cf3ac460 Don't copy more than MAXLOGNAME bytes in getlogin() syscall,
it is stricter than padded s_login size check was there.
1997-03-03 22:46:16 +00:00
Bruce Evans 60e0f7e23d Don't export kernel interfaces to applications. msdosfs_mount probably
didn't compile before this change.

Added idempotency ifdef.
1997-03-03 17:36:11 +00:00
Bruce Evans e4d202a8ae Fixed struct access bug and style bugs in previous revision. The same
fix as for syscons did not work because pcvt uses a struct where syscons
uses a struct pointer.
1997-03-03 16:33:41 +00:00
Bruce Evans 9bdc993298 Removed unused flag IN_RECURSE and unused struct member i_lockcount. 1997-03-03 16:25:46 +00:00
Bruce Evans 0d4c2cc0c7 Removed useless setting of IN_RECURSE. The (anti) locking for this needs
to be done in a different way, if at all.
1997-03-03 16:23:15 +00:00
Bruce Evans 3a76a5949b Merged Lite2's vfs_sysctl(). It doesn't fit very well into FreeBSD's
(phk's) sysctl framework, and I needed special code to disambiguate
the VFS_GENERIC node from the VFS_VFSCONF leaf, so I only converted
the leaves to the FreeBSD framework.  The error handling isn't quite
right.  CSRGS's sysctls seem to return ENOTDIR too much and FreeBSD's
sysctls don't agree with the man page.
1997-03-03 12:58:20 +00:00
Bruce Evans 379184c88d Fixed the getvfsbyname macro hack. 1997-03-03 11:55:47 +00:00
Andrey A. Chernov 964ca0caee Use MAXLOGNAME for stricter size check in setlogin() syscall instead of
sizeof of padded s_login array
1997-03-03 10:15:48 +00:00
Andrey A. Chernov e91f3cb0c3 Use roundup(MAXLOGNAME, sizeof(long)) as e_login/s_login arrays size
instead of all hardcoded assumptions historically used
(i.e. sizeof(long) == 4)

Use MAXLOGNAME == 17 for stricter setlogin() size checking. Since
it rounds up to 20, all sizes remains the same
1997-03-03 09:51:15 +00:00
David Greenman ddd79a9790 Improved performance of hash algorithm while (hopefully) not reducing
the quality of the hash distribution. This does not fix a problem dealing
with poor distribution when using lots of IP aliases and listening
on the same port on every one of them...some other day perhaps; fixing
that requires significant code changes.
The use of xor was inspired by David S. Miller <davem@jenolan.rutgers.edu>
1997-03-03 09:23:37 +00:00
Andrey A. Chernov 1366201aec Bump MAXLOGNAME to 20 to really hold 16-bytes user names + NUL
and decrease spare array by one to keep the same size of eproc
1997-03-03 08:34:08 +00:00
Andrey A. Chernov 3bf4871a36 Restore MAXLOGNAME comment, but in slightly different form 1997-03-03 08:05:03 +00:00
Andrey A. Chernov 3005821598 Back out 1.21 change because MAXLOGNAME _not_ includes NUL character in BSD 1997-03-02 21:21:08 +00:00
Bruce Evans dc91a89e83 Restored some pre-Lite2-merge source-level compatibility to the mount()
and getvfsbyname() interfaces.  The new interfaces are now hidden from
applications unless _NEW_VFSCONF is defined.  The new vfsconf interfaces
don't work yet.
1997-03-02 17:53:37 +00:00
Peter Wemm 413e00145c Import ipfilter 3.1.8 kernel components 1997-03-02 15:50:35 +00:00
Peter Wemm 2236e17352 This commit was generated by cvs2svn to compensate for changes in r23285,
which included commits to RCS files with non-trunk default branches.
1997-03-02 15:50:35 +00:00
Peter Wemm 3589f3628a Replacement import of ipfilter 3.1.7 components used in kernel.
(This is to repair the vendor branching)
1997-03-02 15:49:41 +00:00
Peter Wemm 5c45aebbdc This commit was generated by cvs2svn to compensate for changes in r23282,
which included commits to RCS files with non-trunk default branches.
1997-03-02 15:49:41 +00:00
John-Mark Gurney 4eaede87b0 add the same fix to pcvt that I did to syscons. Make sure that the signals
provided by the user are valid else return EINVAL.

Reviewed-by: joerg
1997-03-02 14:03:33 +00:00
Bruce Evans a896f0256c Moved vfs sysctls to where Lite2 put them. No code changes yet. 1997-03-02 11:06:22 +00:00
Joerg Wunsch 8830f80880 Remove an extraneous shift operation. The facility macros do already
shift the value.

Submitted by:	Andre.Albsmeier@mchp.siemens.de (Andre Albsmeier)
1997-03-02 09:19:15 +00:00
John-Mark Gurney 5ec8909366 make sure that the user supplied signals in struct vt_mode are actually
valid signals, else return EINVAL for ioctl VT_SETMODE.

this fixes a problem that anybody with vty access can panic the system.

2.2-Candidate (and 2.1.0 I believe)

Reviewed-by: sos
1997-03-01 23:53:46 +00:00
Bruce Evans e9ca7be82f Added some nfs #includes so that netboot compiles again. Lite2 made the
nfs includes even more order-dependent and less documented than before.
1997-03-01 17:59:04 +00:00
Wolfram Schneider 6faaa756b5 Include copyright message from <sys/copyright.h> 1997-03-01 17:49:09 +00:00
KATO Takenori 7f247c74a9 Synchronize with sys/i386/conf/options.i386 revision 1.36. 1997-03-01 11:06:41 +00:00
KATO Takenori 070c946661 Synchronize with sys/i386/isa/syscons.c up to revision 1.204. 1997-03-01 10:53:07 +00:00
Justin T. Gibbs 8a709f7876 When we perform an "automatic request sense", we issue an untagged command.
The sequencer expects untagged transactions to have the SCBID of the
transaction in the "busy target" array.  So, ensure that the busy entry
is up to date for the target in this case.  The new identify code in the
sequencer that performs additional sanity checking got caught up when a
tagged transaction created an untagged request sense.

In ahc_handle_seqint, ensure that the target ID is taken from the right
place.  In the case of a selection, the ID is in SCSIID.  In the case of
a reconnection it is found in SELID.
1997-03-01 06:50:41 +00:00
Andrey A. Chernov 50ac8e2f59 Add missing #include <machine/segments.h> for ISPL and SEL_UPL macros 1997-03-01 05:44:09 +00:00
Wolfram Schneider 44f2eddeef Copyright macros and FreeBSD copyright definition. 1997-02-28 23:32:02 +00:00
Bill Fenner e1596dff1e Fix a comment and some commented-out code in ip_mloopback to
reflect how multicast loopback really works.
1997-02-28 19:40:48 +00:00
Bruce Evans 2ca8d13195 Fixed a panic in nfs_writevp(). Lite2 provided a fix for a silly
missing-parentheses bug, but this exposed a misplaced vfs_busy_pages().
This bug cost a factor of 2.5-3 in nfsv3 write performance!  It should
be fixed in 2.2.

Removed some debugging code that gets triggered often in normal
operation.  There are still many backwards diagnostics (#define
DIAGNOSTIC gives no diagnostics).

Submitted by:	vfs_busy_pages() fix by dfr
1997-02-28 17:56:27 +00:00
Bruce Evans 98d0a0b543 Removed nonexistent option PSM_NO_RESET. 1997-02-28 16:56:06 +00:00
Bruce Evans 201d7c413d Fixed spelling error in a variable name. 1997-02-28 14:26:34 +00:00
Bruce Evans 9bb932b6f2 Print function args in the current radix instead of always in hex.
Print the stack pointer together with the frame pointer in the trap,
syscall and interrupt messages.  The frame pointer is not very useful
for locating syscall args since syscall functions don't have a frame
pointer.

Print all the numbers in the trap, syscall and interrupt messages in
the default radix.  The syscall number was confusing because it was
printed in decimal.

Use %#n format more and 0x%x less.  0x%x of course doesn't work with
a variable radix.  ddb is now fairly consistent about using %+#n to
print all numbers.  It omits the '+' for signed numbers the '#' in a
few cases (e.g., for function args) to save space.
1997-02-28 12:36:18 +00:00
Bruce Evans 93437134e2 Added a copyright and restored order. 1997-02-28 10:14:24 +00:00
Kazutaka YOKOTA a87be5f49e Removed an obsolete test which prevented mouse movement from quiting
screen saver. Added a missing `break' statement  in set_normal_mode().

Reviewed by: sos
1997-02-28 08:42:35 +00:00
KATO Takenori 75492a101b Synchronize with NetBSD/pc98 patch level 81.
Submitted by:	Naofumi Honda <honda@Kururu.math.hokudai.ac.jp>
Obtained from:	NetBSD/pc98 patch level 81
1997-02-28 08:34:06 +00:00