Commit Graph

9880 Commits

Author SHA1 Message Date
kato
5ff1564039 Improve and revise fixes for locking violation.
Obtained from:	NetBSD/pc98
1998-01-18 07:56:41 +00:00
dyson
b130b30c96 Tie up some loose ends in vnode/object management. Remove an unneeded
config option in pmap.  Fix a problem with faulting in pages.  Clean-up
some loose ends in swap pager memory management.

The system should be much more stable, but all subtile bugs aren't fixed yet.
1998-01-17 09:17:02 +00:00
pst
7b3674d8fc Fix misleading comment about major # 1998-01-16 22:43:33 +00:00
pst
5b2d50825d Bring in IDE ATAPI floppy support.
This is Junichi's v1.0 driver.

NOTE: Major device numbers have been changed to avoid conflict with other
      FreeBSD 3.0 devices.  The new numbers should be considered "official."
      This driver is still considered "beta" quality, although we have been
      playing with it.  Please submit bugs to junichi and myself.

Submitted by:	junichi@astec.co.jp
1998-01-16 22:13:07 +00:00
bde
9437b36c24 Include <machine/pc/display.h>, not <i386/include/pc/display.h>. This is
not quite correct, because the Makefiles in lkm/syscons don't set up the
`machine' symlink, but other, more volatile headers in <machine> are
already used.
1998-01-16 17:58:55 +00:00
bde
a38cdc5bd4 Fixed a missing #include in the synopsis.
Fixed some wrong prototypes.
Fixed a misspelled function name.

The owner of this file should add a copyright and an Id.
1998-01-16 13:02:58 +00:00
bde
72fdc3c6eb Added prototypes for functions that were documented in libalias.3
but not prototyped here.
1998-01-16 12:56:07 +00:00
kato
3858c5f53c Synchronize with NetBSD/pc98 based on NetBSD/i386 version 1.3G patch
level 117.

Reviewed by:	Naofumi Honda <honda@Kururu.math.sci.hokudai.ac.jp>
1998-01-16 11:32:13 +00:00
kato
60cfcc8b46 Fixed bugs introduced when files were synchronized with
sys/i386/isa/mse.c and sio.c.

Submitted by:	Takahashi Yoshihiro <nyan@wyvern.cc.kogakuin.ac.jp>
1998-01-16 11:20:22 +00:00
charnier
aeb756ae62 Add rcsid. Remove unused vars. Use err(3) and change exit(-1). 1998-01-16 07:20:34 +00:00
kato
7f23b2dc4a Sync with sys/i386/conf/files.i386 revision 1.185. 1998-01-15 15:09:00 +00:00
kato
8137930038 Fix I/O port address of ed8.
Submitted by:	Chiharu Shibata <chi@rd.njk.co.jp>
1998-01-15 08:17:13 +00:00
kato
205070c064 Added comment on fe0 and fe1. Added fe1 fro C-NET(98)P2 and
C-NET(9N)E NICs.

Submitted by:	Chiharu Shibata <chi@rd.njk.co.jp>
1998-01-15 08:12:23 +00:00
gibbs
94a1492f22 Addition of splsoftvm and a VM SWI to handle bus dma related callbacks.
This SWI may be useful for other, defered, VM tasks.
1998-01-15 07:34:01 +00:00
gibbs
ea2baad210 Implementation of Bus Space for FreeBSD-x86.
Obtained From: NetBSD
1998-01-15 07:32:56 +00:00
gibbs
4467dc880b Implementation of Bus DMA for FreeBSD-x86. This is sufficient to do
page level bounce buffering, but there are still some issues left to
address.
1998-01-15 07:32:21 +00:00
gibbs
f998c56a17 Add entry for i386/i386/busdma_machdep.c 1998-01-15 07:30:54 +00:00
phk
74b3033fff Move almost all the ntp related stuff from kern_clock.c to
kern_ntptime.c.  The only bit left over is that which is executed
in all calls to hardclock().  Various cleanups and staticizing
along the road.
1998-01-14 20:48:16 +00:00
phk
83c5648e27 Make softticks static.
Remove unneeded stuff.
1998-01-14 19:42:47 +00:00
phk
232effd623 Add and document PPS_SYNC 1998-01-14 19:41:36 +00:00
kato
8e3bd62529 I forgot to synchronize some changes with sys/i386/isa/wd.c, but I
could't find exact revision numbers.

Submitted by:	Takahashi Yoshihiro <nyan@wyvern.cc.kogakuin.ac.jp>
1998-01-14 08:37:59 +00:00
kato
6c07a7020b Include pc98.h instead of isa.h when PC98 is defined. 1998-01-14 08:13:32 +00:00
kato
aae8ab24bf Fix typo. 1998-01-14 08:08:42 +00:00
brian
07d18a334d Remove __libalias_version. Ppp no longer uses it. 1998-01-14 01:24:49 +00:00
wollman
6ce595a40c Add a macro to accurately calculate the length of a struct ifreq when
it contains an address.  This can replace all the myriad (wrong) ways
in which this task is performed in the current system.  As an added
bonus, since it's a macro, then third-party software vendors have an easy
way to tell whether it's there or not.  (This will become necessary
when sizeof(struct sockaddr) is increaased, and also when additional
fields are added to struct ifreq.)
1998-01-13 02:56:21 +00:00
yokota
17a6acacdd Fix illegal numeric expressions: 08 and 09. 1998-01-12 23:54:51 +00:00
phk
ab42ed078d Remove two non-global variables.
Found by: bde (one)
Overlooked by: bde (one) :-)
1998-01-12 19:10:43 +00:00
kato
71338f7e52 Fix JIS code support.
Submitted by:	NOKUBI Hirotaka <hnokubi@yyy.or.jp>
1998-01-12 15:41:16 +00:00
kato
5da4359f26 Sync with sys/i386/i386/machdep.c revision 1.281. 1998-01-12 15:38:51 +00:00
kato
fab431349e Sync with sys/i386/isa/syscons.c revision 1.245. 1998-01-12 15:38:20 +00:00
kato
0d05a1344b Sync with sys/i386/conf/GENERIC revision 1.102. 1998-01-12 15:37:38 +00:00
kato
840200f8e9 Initialize the variables Crtat and Atrat in scvidprobe().
Submitted by:	NOKUBI Hirotaka <hnokubi@yyy.or.jp>
1998-01-12 15:34:18 +00:00
dyson
94982c0d65 Adjust upwards the size of exec map in order to take into account the
additional PAGE_SIZE needed for exec operatino.
1998-01-12 05:16:03 +00:00
julian
99f65891bd Add some devfs entries
(patch origianlly from luigi)
1998-01-12 03:45:58 +00:00
julian
a2436929c7 add devfs entries for a few more syscons devices (e.g. sysmouse) 1998-01-12 03:28:36 +00:00
dyson
9a35ec7fec Fix another vnode leak. 1998-01-12 03:15:01 +00:00
dyson
d9d8bf6d30 Fix some vnode management problems, and better mgmt of vnode free list.
Fix the UIO optimization code.
Fix an assumption in vm_map_insert regarding allocation of swap pagers.
Fix an spl problem in the collapse handling in vm_object_deallocate.
When pages are freed from vnode objects, and the criteria for putting
the associated vnode onto the free list is reached, either put the
vnode onto the list, or put it onto an interrupt safe version of the
list, for further transfer onto the actual free list.
Some minor syntax changes changing pre-decs, pre-incs to post versions.
Remove a bogus timeout (that I added for debugging) from vn_lock.

PHK will likely still have problems with the vnode list management, and
so do I, but it is better than it was.
1998-01-12 01:46:33 +00:00
dyson
2aff55e25f Implement the first page access for object type determination more
VM clean.  Also, use vm_map_insert instead of vm_mmap.
Reviewed by:	dg@freebsd.org
1998-01-11 21:35:38 +00:00
phk
dfbd942cf7 Try to solve timeout race by not touching softtics here. 1998-01-11 19:07:58 +00:00
eivind
9389702192 Remove use of <osreldate.h>.
Screwed up by: myself
1998-01-11 18:34:38 +00:00
brian
ccb6ae343d Move softc stuff into if_tunvar.h
Suggested by: Peter Wemm <peter@netplex.com.au>
Hinted at by: Bruce Evans <bde@FreeBSD.org>


1998-01-11 17:52:33 +00:00
brian
668b4ef2b2 Move softc stuff into if_tunvar.h
Suggested by: Peter Wemm <peter@netplex.com.au>
Hinted at by: Bruce Evans <bde@FreeBSD.org>
À³
1998-01-11 17:52:29 +00:00
jb
f9091e3078 Since the alpha has to use NetBSD's kernel for the time being, it also
needs the NetBSD syscall definitions.
1998-01-11 03:53:15 +00:00
jkh
4a0e83676d Add ppp, at long last, back to GENERIC. We have enough room in the
kernel for it and I'm tired of reading the "This system lacks kernel
support for PPP..." line in people's tech support messages.
1998-01-11 02:16:38 +00:00
phk
8a2e578b97 Fix softclock calling so we don't loose timeouts (I broke this ~10h ago) 1998-01-11 00:44:31 +00:00
jb
1b3b485dd9 Add a machine dependent header for the i386 jmp_buf size instead of piling
machine dependent definitions into src/include/setjmp.h.
1998-01-10 23:04:51 +00:00
jb
1a06f650e6 Add a machine dependent header to size the jmpbuf instead of piling
machine dependencies in src/include/setjmp.h.
1998-01-10 23:00:06 +00:00
jb
1d9560f590 PAL codes needed for asm.h 1998-01-10 22:42:21 +00:00
jb
58d8db41d2 Header files which are linked from /usr/include to /usr/include/machine.
NetBSD's endian.h needs sys/types.h for the typedefs that are used to
get htonl() correct when a long is 64 bits.
1998-01-10 22:09:53 +00:00
steve
b2c4a494f5 Put back __libalias_version so ppp(8) build again. 1998-01-10 19:37:19 +00:00
alex
f4a6b5e087 Sync with ipfw interface change: fw_pts is now part of a union (a
necessary evil due to the 108 byte setsockopt() limit).
1998-01-10 16:14:18 +00:00
jkh
310652e8b0 include <net/if.h> and restore this to sanity. 1998-01-10 15:04:06 +00:00
phk
2c2c366569 Whoops. softclock is called from doreti_swi as well. Abandon call from
hardclock().

Forgot this:

Pointed hat sent by:	bd
1998-01-10 14:55:14 +00:00
phk
1cc31c4aa6 Whoops. softclock is called from doreti_swi as well. Abandon call from
hardclock().
1998-01-10 14:54:05 +00:00
kato
c5bb64779d Sync with sys/i386/isa/syscons.c revision 1.244. 1998-01-10 13:31:27 +00:00
phk
7b6e03e147 Effect the divorce of kern_clock.c and kern_timeout.c (which was
repository copied from kern_clock.c)
1998-01-10 13:16:26 +00:00
jb
eb6c3ae58f These are a few of the alpha machine dependent header files - the first
referenced by the build of user-space libraries. These files were
obtained from NetBSD (with ansi.h being modified to reflect the FreeBSD
off_t and pid_t implementation).
1998-01-10 10:13:16 +00:00
kato
f9b84b4245 Added PnP I/O port address of NEC PC-98.
Submitted by:	Takahashi Yoshihiro <nyan@wyvern.cc.kogakuin.ac.jp>
1998-01-10 07:41:43 +00:00
bde
b2a951d0e4 Fixed change prerequisites for <net/if_arp.h>:
- don't declare `struct arpcom' except in the kernel, so that there is no
  dependency on <net/if.h> except in the kernel.  This may break something
  else.
- spell ETHER_ADDR_LEN as 6 again, so that there is no dependency on
  <net/ethernet.h> even in the kernel.
1998-01-10 07:29:10 +00:00
eivind
781f5bff10 Teach libalias to work with IPFW firewalls (controlled by a flag).
Obtained from: Yes development tree (+ 10 lines of patches from
	Charles Mott, original libalias author)
1998-01-09 21:13:35 +00:00
yokota
c7fe61947c - Produce the accent letter if the user hits the accent key twice.
(accent_key + space does still print the accent letter too, as in
  the previous commit.)
  Requested by a couple of users.
- Clear the accent flag when the next_screen key is pressed.
- Added some comment lines regarding accent key processing.
1998-01-09 09:06:55 +00:00
kato
c1a394c6e7 Sync with sys/i386/conf/files.i386 revision 1.184. 1998-01-09 08:49:43 +00:00
eivind
57d4125c71 Make the BOOTP family new-style options (in opt_bootp.h) 1998-01-09 03:21:07 +00:00
eivind
7b61fe3f84 Minor fixups after INET option change. 1998-01-09 01:01:21 +00:00
eivind
6df58d9bc9 NETATALK -> opt_atalk.h 1998-01-09 00:51:57 +00:00
eivind
d0bda339f4 Make the LKMs compile with the INET option as a newstyle option in
opt_inet.h.
1998-01-08 23:50:27 +00:00
eivind
bcae2312af Make INET a proper option.
This will not make any of object files that LINT create change; there
might be differences with INET disabled, but hardly anything compiled
before without INET anyway.  Now the 'obvious' things will give a
proper error if compiled without inet - ipx_ip, ipfw, tcp_debug.  The
only thing that _should_ work (but can't be made to compile reasonably
easily) is sppp :-(

This commit move struct arpcom from <netinet/if_ether.h> to
<net/if_arp.h>.
1998-01-08 23:42:31 +00:00
jmg
48cccef792 update the AWE32 wave table driver to Iwai's 0.4.2c version. This also
includes the patches to make it work under -current from Randall Hopper.

Remove the old AWE driver.
1998-01-08 23:13:22 +00:00
jmg
ac5240c506 This commit was generated by cvs2svn to compensate for changes in r32345,
which included commits to RCS files with non-trunk default branches.
1998-01-08 22:17:17 +00:00
jmg
31528ddcdd import of GPL'd AWE32 Sound Driver v0.4.2c
Submitted by:	Randall Hopper
1998-01-08 22:17:17 +00:00
kato
6e97628d82 Sync with sys/i386/isa/syscons.c revision 1.243. 1998-01-08 10:50:46 +00:00
kato
3bb8cccf98 Sync with sys/i386/isa/sio.c revision 1.194. 1998-01-08 10:50:06 +00:00
amurai
6c81cb515e 1. Supporting a bogus 16550A compatible PCMCIA CARD stuffs
- IIR_TXRDY is never off even if reading a IIR register.
    - Know as PIAFS "Palido 321S", "DC-*S" oemed by Sharp corp.

 2. Omiting a restrict probing if it's already probed by pccardd.
    Note: Define a new id_flags as follows

           0x40000 - NO PROBE (Already probed as serial)
           0x80000 - Has a bogus IIR_TXRDY register

	Sato Junichi <junichi@astec.co.jp>
	Nrihiro Kumagai <kuma@slab.tnr.sharp.co.jp>
	Hirao Tetsuya <ai.cs.fujitsu.co.jp>
	Toshiharu Asai <asai@mbc.infoshere.or.jp>
	Shin'ya Kumabuchi <kumabu@t3.rim.or.jp>
        Freebsd-users-jp@jp.freebsd.org
	bsd-nomads@ai.cs.fujitsu.co.jp
1998-01-08 04:53:43 +00:00
alex
35f59936c3 Bump up packet and byte counters to 64-bit unsigned ints. As a
consequence, ipfw's list command now adjusts its output at runtime
based on the largest packet/byte counter values.

NOTE:
  o The ipfw struct has changed requiring a recompile of both kernel
    and userland ipfw utility.

  o This probably should not be brought into 2.2.

PR:		3738
1998-01-08 03:03:54 +00:00
alex
6734c6448e Define integer types added by POSIX.1g. We already had int8_t, int16_t,
and int32_t -- this adds their unsigned counterparts uint8_t, uint16_t,
and uint32_t.  Bruce has noted that C9x also defines these types (in a
different file), so this may have to be revisited with some ifdefs at a
later date.

Reviewed by:	bde
1998-01-08 00:27:34 +00:00
phk
1e948b4b8a Improve hardpps readability a bit:
* Rename usec to p_usec so you can search for it.
* Macroize the huge median_of_3_samples if statement.
1998-01-07 12:29:17 +00:00
dyson
66da5c4f34 Disable io optimizations again, minor bug found, and will be fixed in
a few days.
1998-01-07 09:26:29 +00:00
kato
cb8d075676 1: Fixed compile error when WB_CACH is defined.
2: Fixed !M_EPSON_PC98 case.

Reviewed by:	Chiharu Shibata <chi@rd.njk.co.jp>
1998-01-07 09:03:42 +00:00
yokota
3ed12c01d2 Added accent (dead) key support to syscons and kbdcontrol.
With a keymap with accent key definitions loaded to syscons, you press
an accent key followed by a regular letter key to produce an accented
letter.  Press an accent key followed by the space bar to get the
accent letter itself.

Code is based on the ideas and work by jmrueda@diatel.upm.es and
totii@est.is.

PR: i386/4016

console.h
- Defined structures and constants for accent (dead) keys.

syscons.c, kbdtables.h
- When an accent key is pressed, set the corresponding index to
  `accents'.  If the next key is the space key, produce the accent char
  itself.  Otherwise search the accent key map entry, indexed by
  `accents', for a matching pair of a regular char and an accented char.
- Added ioctl functions to set and get the accent key map (PIO_DEADKEYMAP
  and GIO_DEADKEYMAP).
1998-01-07 08:40:34 +00:00
dyson
cbf538c65f Turn off the VTEXT flag when an object is no longer referenced, so
that an executable that is no longer running can be written to.  Also,
clear the OBJ_OPT flag more often, when appropriate.
1998-01-07 03:12:19 +00:00
kato
743267f016 Sync with sys/i386/conf/files.i386 revision 1.183. 1998-01-06 13:47:54 +00:00
wosch
c4c39cc79f Delete a stray semicolon at the end. This only breaks gcc -pedantic
because COPYRIGHT_HPFPLIB is appended last.
Submitted by:	Bruce
1998-01-06 11:44:55 +00:00
jamil
de11a440c5 documentation changes. 1998-01-06 09:27:37 +00:00
julian
868a198eda the pt driver should make one DEVFS entry for each one found rather than
just one for the whole system..
1998-01-06 08:28:46 +00:00
dyson
cb2800cd94 Make our v_usecount vnode reference count work identically to the
original BSD code.  The association between the vnode and the vm_object
no longer includes reference counts.  The major difference is that
vm_object's are no longer freed gratuitiously from the vnode, and so
once an object is created for the vnode, it will last as long as the
vnode does.

When a vnode object reference count is incremented, then the underlying
vnode reference count is incremented also.  The two "objects" are now
more intimately related, and so the interactions are now much less
complex.

When vnodes are now normally placed onto the free queue with an object still
attached.  The rundown of the object happens at vnode rundown time, and
happens with exactly the same filesystem semantics of the original VFS
code.  There is absolutely no need for vnode_pager_uncache and other
travesties like that anymore.

A side-effect of these changes is that SMP locking should be much simpler,
the I/O copyin/copyout optimizations work, NFS should be more ponderable,
and further work on layered filesystems should be less frustrating, because
of the totally coherent management of the vnode objects and vnodes.

Please be careful with your system while running this code, but I would
greatly appreciate feedback as soon a reasonably possible.
1998-01-06 05:26:17 +00:00
sef
082257799e Use CHECKIO in procfs_ioctl() to ensure that any changes in UID/GID result
in the expected failure.
1998-01-06 01:37:12 +00:00
jmb
486344203a sigh....forgot to update the DEBUG printf
to show both the path and the length args
	to linux emulation truncate()

Submitted by:		jmb
1998-01-05 01:17:42 +00:00
jmb
ef679c74cb length argument to truncate() in linux emulation
was not being set copied to the bsd arguments..
	frequently, resulting in files of over 100MB of NULs

PR:	386/5044
Reviewed by:		jmb
Submitted by:		(Richard Winkel) rich@math.missouri.edu
1998-01-05 01:05:15 +00:00
alex
dd72def827 Use LIST_FIRST/LIST_NEXT macros instead of accessing the fields lh_first
and le_next.
1998-01-05 00:57:15 +00:00
alex
509616d101 Added missing parens from previous commit. 1998-01-05 00:14:05 +00:00
alex
147e6a553f Bound the ICMP type bitmap now that it doesn't cover all possible
ICMP type values.
1998-01-05 00:08:57 +00:00
alex
44f7a5e200 Reduce the amount of time that network interrupts are blocked while
zeroing & deleting rules.

Return EINVAL when zeroing an nonexistent entry.
1998-01-04 22:36:12 +00:00
kato
6728e0d8f3 Sync with sys/i386/isa/syscons.c (first chunk). Reorder #ifdef.
Submitted by:	NOKUBI Hirotaka <hnokubi@yyy.or.jp>
1998-01-04 09:59:23 +00:00
obrien
37a4d8d55a AMD calls the PR166 and PR200, models 2 and 3 respectively. 1998-01-03 05:43:37 +00:00
obrien
97f7aa4094 Update AMD URL for CPU recognition docs. 1998-01-03 05:36:40 +00:00
kato
359c8a3329 Fix typo. Option `CPU_SUSP_HLT' didn't work on Cyrix 486DX box.
Submitted by:	nyan@wyvern.cc.kogakuin.ac.jp (Takahashi Yoshihiro)
1998-01-03 05:35:51 +00:00
msmith
d9810a8a17 Specify the minor number correctly when creating devfs entries. 1998-01-02 13:35:06 +00:00
kato
6fb547d5b3 Sync with sys/i386/i386/microtime.s revision 1.40. 1998-01-02 09:31:16 +00:00
msmith
8acca4f677 Actually implement the internals of the 'ppi' device.
It is now possible to control the various parallel port signals from
user-space programs without having to resort to opening /dev/io
directly.
1998-01-02 09:30:39 +00:00
kato
721b8ddd8c Fixed wrong name in .file statement. 1998-01-02 09:29:15 +00:00
julian
8895d4eccd add copyrights 1998-01-02 07:31:07 +00:00
gj
f1d1f72983 Reviewed by: Joerg Wunsch
In sppp_chap_input:
1) in the CHAP_CHALLENGE case don't output the peer's name if it is not
what we expected (DEBUG) since it will be printed out in the course
of events anyway.
2) in the CHAP_SUCCESS case test whether the peer is required to
authenticate himself [(sp->lcp.opts & (1 << LCP_OPT_AUTH_PROTO))],
otherwise the state machine may never switch into the network state.
I saw this case against 2 different ISPs; they never bothered to
authenticate themselves to me.

In sppp_pap_input:
in the PAP_ACK case do the same as in 2) above for the same reason.
1998-01-01 21:27:18 +00:00
alex
017d9a9242 Added missing caddr_t --> void * conversions for sys/mman.h functions.
Submitted by:	bde
1998-01-01 17:07:46 +00:00
msmith
1b95d36e35 Don't try to call into BIOS32 handlers outside the normal ROM
address range.  They may have been trashed earlier in the boot
process, or the directory header may simply be bogus.

PR:		5140
Submitted by:	Joel Faedi <Joel.Faedi@esial.u-nancy.fr>
Brought-to-attention-by: Derek Inksetter <derek@saidev.com>, bde
1998-01-01 13:26:55 +00:00
bde
f8738048d0 Fixed cosmetic bugs:
- wrong name in .file statement.
- stale comment about CONSPEED.
- style bugs in comments.
- inconsistent defaulting of operand sizes (should never depend on default).
- inconsistent choosing between je and jz (should always use je).
1998-01-01 13:01:31 +00:00
bde
0c0865622b Removed unused #includes. 1998-01-01 12:41:44 +00:00
bde
e94cdac858 Removed unused #includes again. They thrashed when mfs_reclaim thrashed
to ufs_reclaim and back.
1998-01-01 12:40:25 +00:00
bde
62111cffb4 Use a real malloc type for M_LINKER instead of #defining it as M_TEMP.
Fixed a comment.
1998-01-01 08:56:24 +00:00
bde
fc1927fdd5 Use a real malloc type for M_LINKER instead of #defining it as M_TEMP. 1998-01-01 08:55:37 +00:00
bde
f65c51a04d Moved the SMP declarations of INTREN() and INTRDIS() to the correct header,
i.e., the same header as corresponding non-SMP #defines.
1998-01-01 08:47:17 +00:00
bde
9c98de2bba Fixed missing initialization of mp->mnt_stat. At least vm depends on
at least mp->mnt_stat.f_iosize being nonzero.

PR:		5212
1998-01-01 08:28:26 +00:00
obrien
886e6a5cbc Explain that MAXMEM maynot be nessicary for detection of >64MB RAM. 1997-12-31 21:46:17 +00:00
wosch
6f7edd1397 A Happy New Year! 1998. 1997-12-31 11:04:01 +00:00
ahasty
7eec77813b Reviewed by: Amancio Hasty
Submitted by:	Jonathan Hanna <pangolin@rogers.wave.ca>
The patch is for a Hauppauge Win/TV dbx with FM. I still need to
config OVERRIDE_TUNER, but it works nicely.
1997-12-31 05:45:56 +00:00
alex
e87ef9d530 caddr_t --> void * 1997-12-31 02:35:29 +00:00
alex
fb5c76c176 Convert caddr_t --> void * for sys/mman.h functions.
mlock, mmap, mprotect, msync, munlock, and munmap are defined by
POSIX as taking void *.  The const modifier has been added to
mlock, munlock, and mprotect as the standard dictates.

minherit comes from OpenBSD and has been updated to conform with
their recent change to void *.

madvise and mincore are not defined by POSIX, but their arguments
have been modified to be consistent with the POSIX-defined functions.
mincore takes a const pointer, but madvise does not due to the
MADV_FREE case.

Discussed with:	bde
1997-12-31 01:22:01 +00:00
nate
00293d1a14 - Accept all models of the HP C1553A tape series as usable tapes. This
is necessary for my tape drive to be found, since it's apparently a
  later model.
1997-12-30 22:26:51 +00:00
phk
8f9f6ff1df Fix a race condition I introduced.
Reviewed by: bde (with only minor complaints :-)
1997-12-30 20:11:01 +00:00
bde
05d3a8c532 Fixed a missing/misplaced/misstyled prototype. 1997-12-30 08:46:44 +00:00
julian
5ff3bce59b move punchline of joke up to rest of joke. (got moved by useful edits) 1997-12-30 04:19:54 +00:00
phk
c1be3d2c9c Fix a include gottcha in the SMP case.
Submitted by: Simon Shapiro <Shimon@Simon-Shapiro.ORG>
1997-12-29 23:36:56 +00:00
dyson
7bf56bd14a Add the vnode interlock back around vref. 1997-12-29 16:54:03 +00:00
dyson
988b240fc6 Add the vnode interlock back around vget. 1997-12-29 16:53:53 +00:00
kato
24650f8d03 Sync with sys/i386/conf/options.i386 revision 1.66. 1997-12-29 16:17:59 +00:00
kato
d3c0f0fbd0 Sync with sys/i386/i386/microtime.s revision up to 1.39. 1997-12-29 16:17:09 +00:00
kato
5ee02566eb Sync with sys/i386/isa/clock.c revision up to 1.107. 1997-12-29 16:15:57 +00:00
kato
94ab377b71 Sync with sys/i386/isa/sio.c revision up to 1.193. 1997-12-29 16:08:48 +00:00
kato
29b2fd54bd Sync with sys/i386/i386/userconfig.c revision 1.99. 1997-12-29 16:06:20 +00:00
bde
85fbb446a9 Fixed style bugs in previous commit. 1997-12-29 08:54:52 +00:00
julian
a13419db88 If available, use the device's LOGICAL blocksize as reported by
the "READ_CAPACITY" command, rather than the physical blocksize
reported in the physical geometry code-page.

Also don't print out worrying bogus messages when probing a
device that has no media. There's no point in printing out
something that is unknowable. It just confuses things.

Move the check for valid blocksize out of 'open()' to the subroutine
that actually finds this out, thus probe/attach can also report and
act on the problem.
1997-12-29 07:49:31 +00:00
dyson
8ab3ac77d2 Fix the decl of vfs_ioopt, allow LFS to compile again, fix a minor problem
with the object cache removal.
1997-12-29 01:03:55 +00:00
dyson
cd67bb82fe Lots of improvements, including restructring the caching and management
of vnodes and objects.  There are some metadata performance improvements
that come along with this.  There are also a few prototypes added when
the need is noticed.  Changes include:

1) Cleaning up vref, vget.
2) Removal of the object cache.
3) Nuke vnode_pager_uncache and friends, because they aren't needed anymore.
4) Correct some missing LK_RETRY's in vn_lock.
5) Correct the page range in the code for msync.

Be gentle, and please give me feedback asap.
1997-12-29 00:25:11 +00:00
steve
c1884e4eb8 Add back a #include <sys/types.h> so that this header is
self-sufficient again.  This is a quick fix that should
really be remedied by removing all of the gratuitous changes
made in revision 1.20.

PR:		5351
1997-12-28 22:31:59 +00:00
phk
87f11cf193 More cleanup relating to our use of the TSC.
Look in the cpu_feature (CPUID output) to see if we have it.
1997-12-28 17:33:10 +00:00
phk
ca105236ff wash, sort and put in order various nits from the i586_ctr -> tsc
commit.

Pointed out by: bde
1997-12-28 13:36:09 +00:00
julian
2519865571 back out previous commit
got a better version.
1997-12-28 09:10:37 +00:00
kato
e50e705007 Merge from sys/i386/i386/microtime.s revision 1.36. 1997-12-28 08:16:28 +00:00
julian
e8593c05aa Move the sector size check to the right place,
also cope with some drives that return funny values.
The correct fix will come in a few days.
1997-12-28 07:10:54 +00:00
bde
c4f9529d8c Fixed initialization of the divisor latch. We depended on siocnopen()
initializing it for the (usual) (siocniobase != 0) case, but
siocnopen() doesn't initialize it if the latch registers already
have the correct values.
1997-12-28 06:36:35 +00:00
bde
233f527965 YAMFsio.c (always call ttwwakeup() before returning from comstart()). 1997-12-28 06:23:03 +00:00
bde
6923614d1d Always call ttwwakeup() before returning from comstart(). It isn't
necessary to call it when the tty layer's output state has not been
changed, but siostop() sometimes changes the TS_BUSY state and then
calls comstart() mainly for its side effect of calling ttwwakeup().
1997-12-28 06:20:47 +00:00
bde
aee0b8bb68 Removed unnecessary (and broken) wakeup code in rpstart(). There is no
need to do it directly, since ttwwakeup() is always called just before
returning from rpstart().  The brokenness was waking up the wrong address
after clearing TS_SO_OLOWAT.  It's not clear how processes waiting for
output to drain below low water ever got woken up.

Found by:	when I fixed longstanding warts in output watermark
		handling, this was the only driver that knew too much
		(anything) about the watermarks
1997-12-28 05:45:07 +00:00
bde
07b5eb4e92 Removed stale comment about printf's deficiencies and rewrote the code
that worked around them for the CLI devtab listing.

Print the `conflicts' flag in the CLI devtab listing.
1997-12-28 05:20:59 +00:00
bde
e24f5de85f Handle "%...p" as "%#...x" instead of "0x%...x". This is a quick fix
for field widths being 2 larger than specified for "%<number>p".  Only
printing of null pointers is "wrong" now (it is actually "right", but
inconsistent with printf(3)).
1997-12-28 05:03:33 +00:00
bde
79c9bcac97 Unspammed nested include of <sys/malloc.h>. <sys/mbuf.h> hasn't
really used any features from <sys/malloc.h> since it was "blasted
from the past" in rev.1.15, and most .c files did not depend on
the namespace pollution (others have been fixed).  The mbuf allocation
control values M_DONTWAIT and M_WAIT were just defined in terms of
the malloc control values M_NOWAIT and M_WAITOK.  The mbuf values
are now defined directly.
1997-12-28 01:04:47 +00:00
bde
485d4efb1c Restored used include of <sys/malloc.h>. malloc() is not used
here, but kmem_malloc() is used and it takes the same "flags" as
malloc().

Use the mbuf allocation "flags" M_WAIT and M_DONTWAIT consistently.
There is really only one boolean flag, M_DONTWAIT, but the "flags"
were always treated as enum-like values, except in some places here
where the values are tacitly converted to boolean flags.  Treat
them as enum-like values everywhere, except where we tacitly assume
that there are only two values in order to convert them to the
corresponding two kmem_malloc() "flags".
1997-12-28 01:01:13 +00:00
jkh
e92c01b5e0 Update comment to match updated sb0 line (conflicts keyword no longer needed
at IRQ 5).
1997-12-28 00:28:46 +00:00
alex
7352708c98 Bring back part of rev 1.44 which was commented out by rev 1.58.
Reviewed by:	nate
1997-12-27 18:44:56 +00:00
bde
7629c0321e Unspammed nested include of <vm/vm_zone.h>. 1997-12-27 09:42:03 +00:00
peter
c97344001f Back out previous commit, the so-called "unused code" was most definately
used, and caused a reference to an uninitialised variable (state).
I think I've fixed it now, but since nothing in the tree seems to use it,
I'm not sure.
1997-12-27 03:00:59 +00:00
bde
3c1b6940fc Unspammed nested include of <vm/vm_zone.h>. 1997-12-27 02:56:39 +00:00
peter
603f05b160 #include "opt_user_ldt.h" so that the #ifdef USER_LDT checks can work, as
commented about at length in the PR audit trail.

PR: 2412
1997-12-27 02:28:28 +00:00
jkh
eff1842268 Change major number to match the one actually used (whoops!).
Submitted by:	Steve Gericke <steveg@comtrol.com>
1997-12-26 23:11:13 +00:00
phk
cadc59e511 Rename "i586_ctr" to "tsc" (both upper and lower case instances).
Fix a couple of printfs too.

Warning: This changes the names of a couple of kernel options!
1997-12-26 20:42:37 +00:00
phk
7682f91921 ename "i586_ctr" to "tsc" (both upper and lower case instances).
Fix a couple of printfs too.

Warning: This changes the names of a couple of kernel options!
1997-12-26 20:41:08 +00:00
phk
6d1e02dc52 Reorder to a more conventional if/then/else/endif structure. 1997-12-26 20:15:03 +00:00
joerg
57a71c2f00 Fix some breakage that prevented the Plasmon burners from being used
under -current.  The actual preparation of the next track will now be
deferred until just before the first write operation.  Otherwise,
opening the device with write intent will cause the execution of
commands that are illegal in `limited command set mode' (i.e., after
the write channel has been opened).

While i was at it, cleaned up the worm_open() function a bit.

Removed the volume overflow pre-check in worm_strategy().  It was
time-consuming, and rather useless in many cases anyway (with the size
being reported for just the entire volume only), so we can as well let
the actual SCSI command fail instead, where it'll properly be reported
as EIO.

Partially submitted by & discussed with: jmz
1997-12-26 14:52:29 +00:00
dyson
74cfdda9c1 The ioopt code is still buggy, but wasn't fully disabled. 1997-12-25 20:55:15 +00:00
gpalmer
bb1c31c96d Make kern.ncpu reports the number of detected processors when running
with a SMP kernel.
1997-12-25 13:14:21 +00:00
dg
2a494c06e2 The spl fixes in in_setsockaddr and in_setpeeraddr that were meant to
fix PR#3618 weren't sufficient since malloc() can block - allowing the
net interrupts in and leading to the same problem mentioned in the
PR (a panic). The order of operations has been changed so that this
is no longer a problem.
Needs to be brought into the 2.2.x branch.
PR:		3618
1997-12-25 06:57:36 +00:00
dyson
d97fabbb53 Support running with inadequate swap space. Additionally, the code
will complain with a suggestion of increasing it.
1997-12-24 15:05:25 +00:00
nate
f886ffb27e - Add prototype for adjust_timeout_calltodo().
Submitted/forgotten by:	Ken Key <key@cs.utk.edu>
1997-12-24 01:33:45 +00:00
brian
9672a80ab3 Add a PARITITON arg to SCSI_MKFIXED, and use it to
specify RAW_PART for the suopen() in sscioctl().

Now you can `scsi -f /dev/ssc -p'.
1997-12-23 19:44:45 +00:00
nate
b24853a710 This patch causes the "calltodo" timer list to be decremented by the amount
of time that the laptop was suspending.  Thus, select() calls that might have
suspended rather than firing  at 1hr + "time suspended" since the timer was
posted.

Adding:

    options  APM_FIXUP_CALLTODO

to the kernel config enables the patch.

[
This patch was slightly modified to use a consistant indent style and
I removed some unused local variables.  After this has been tested a
few weeks we'll make the options the default, so for now I'm now
documenting it in LINT.  Mike can later if he wants.
]

Reviewed by:	Mike Smith <msmith@freebsd.org>
Submitted by:	Ken Key  <key@cs.utk.edu>
1997-12-23 16:32:35 +00:00
yokota
59aba0db01 Document `flags' for the psm driver. 1997-12-23 08:01:16 +00:00
alex
064cf03a22 Removed unnecessary setting of 'error' -- binding to a privileged port
by a non-root user always returns EACCES.
1997-12-23 01:40:40 +00:00
dyson
b6fbb09bc1 Improve my copyright. 1997-12-22 11:54:00 +00:00
dyson
2a4aef5cd4 Improve my copyright. 1997-12-22 11:48:13 +00:00
dyson
edbb7fba33 Correct my previous fix for the UPAGES problem. 1997-12-22 10:06:09 +00:00
dyson
2c2d68bf78 Hopefully fix the problem with the TLB not being updated correctly.
Problem tracked down by bde@freebsd.org, but this is an attempted
efficient fix.
1997-12-22 00:36:48 +00:00
joerg
548dd1da87 Properly clean out the SI_MOUNTEDON flag iff the mount attempt fails
half the way down.  Otherwise, further attempts to mount the device
will be rejected with BUSY.

IMHO, this flag can completely go away for cd9660.  There's no reason
you need to prevent CDs from being mounted multiple times, and in case
of multisession CDs it can even make sense to mount two different
sessions by the same time (to different mount points, otherwise it
would be pointless ;).
1997-12-21 21:40:02 +00:00
bde
7fb46d4921 Moved some declarations from <sys/socket.h> to the correct places, and
fixed everything that depended on them being misplaced.
1997-12-21 16:35:12 +00:00
dyson
5640baa7c8 I added vfs_ioopt prematurely, disabled. 1997-12-21 10:41:19 +00:00
joerg
efc02439ae Duplicate the entry for the Plasmon CD-R device, so both possibilities
(read/only and write/once) will be covered.  This is necessary in order
to fill in the proper device information record.
1997-12-20 23:05:14 +00:00
joerg
3de8948e8c Protect against a null pointer dereferencation in the case of an
unknown drive.  Such a drive will be configured by worm(4)
nevertheless (albeit with a warning), but cannot be opened except of
the SCSI control device (so scsi(8) or cdrecord will continue to
work).
1997-12-20 23:03:49 +00:00
sef
7ed4538110 Add a copyright and license notice, on Jordan's request. 1997-12-20 18:36:02 +00:00
eivind
2f4a80f2e8 Remove bogus #ifdef INET - SLIP doesn't compile without INET. 1997-12-20 16:44:51 +00:00
se
f73c0ca9c8 Make the class code checks in function pci_cfgcheck less strict.
It failed to recognize the PCI bus in a system that had only an
old chip-set (class code 000000) and a Cyclom multiport serial
card on PCI bus 0, but no VGA card or disk or network controller.

PR:		i386/5300
Submitted by:	Nickolay N. Dudorov <nnd@itfs.nsk.su>
1997-12-20 09:04:25 +00:00
sef
f4669f67bc Clear the p_stops field on change of user/group id, unless the correct
flag is set in the p_pfsflags field.  This, essentially, prevents an SUID
proram from hanging after being traced.  (E.g., "truss /usr/bin/rlogin" would
fail, but leave rlogin in a stopevent state.)  Yet another case where procctl
is (hopefully ;)) no longer needed in the general case.

Reviewed by:	bde (thanks bruce :))
1997-12-20 03:05:47 +00:00
kato
6a523666f7 Sync with sys/i386/conf/Makefile.i386 revision 1.106. 1997-12-20 02:37:55 +00:00
bde
6fd5d1abfc Ifdefed some conditionally used declarations. 1997-12-20 00:28:49 +00:00
bde
b1d53f05b1 Removed a stray semicolon. 1997-12-20 00:27:03 +00:00
bde
52dbbb4e05 Added a used include.
Fixed a gratuitous ANSIism and nearby KNF violations.
1997-12-20 00:25:01 +00:00
bde
598fd6fc0b Fixed a sloppy common-style declaration.
natm_pcb.c:
Include <sys/socketvar.h> which will be used when M_PCB is declared
in the right place.
1997-12-20 00:13:51 +00:00
bde
9444575762 Fixed gratuitous ANSIisms. 1997-12-20 00:07:11 +00:00
bde
75c4ef96e7 Don't use ANSI string concatenation to misformat a string. 1997-12-19 23:46:21 +00:00
bde
1c88036d01 Removed a stale comment. (We don't declare ip_len and ip_offset as
short.  I guess we depend on bogus ANSI value-preserving extension
of u_short to int to avoid unsigned comparison bugs.)
1997-12-19 23:33:08 +00:00
bde
6409845796 Use __inline instead of inline to prevent pedantic compiler warnings. 1997-12-19 23:25:16 +00:00
bde
22c38e9fe8 Removed some bogus casts. 1997-12-19 23:18:37 +00:00
bde
8f84818ada Made N_TXTADDR() work for kernels (assume that a ZMAGIC file with an
out of bounds a_entry is a kernel and use the usual kludge to find
the text address).  If gdb had used this, it would have been able
to find the kernel text address properly.  Unfortunately, it uses
its own a.out macros, so this is mainly an example for gdb to copy.
1997-12-19 20:44:48 +00:00
ache
ae9996d766 MALLOC->malloc
Suggested-by: bde
1997-12-19 19:39:01 +00:00
bde
4191aa2363 Set the sender's low watermark to match the maximum size for atomic
writes that we advertise (PIPE_BUF = 512).
1997-12-19 18:58:14 +00:00
dyson
4c44bbc963 Change bogus usage of btoc to atop. The incorrect usage of btoc was
pointed out by bde.
1997-12-19 15:31:13 +00:00
bde
254d5ecb9e Fixed namespace pollution in previous commit.
Merged KERNEL ifdefs.
1997-12-19 10:03:31 +00:00
ache
6c0f717b7e SUNIT: use MALLOC/FREE and M_NOWAIT 1997-12-19 09:48:57 +00:00
dyson
6bd1f74dcf Some performance improvements, and code cleanups (including changing our
expensive OFF_TO_IDX to btoc whenever possible.)
1997-12-19 09:03:37 +00:00
julian
efed7b6cdc Fix an incredibly horrible bug in the ipfw code
where if you are using the "reset tcp" firewall command,
the kernel would write ethernet headers onto random kernel stack locations.

Fought to the death by: terry, julian, archie.
fix valid for 2.2 series as well.
1997-12-19 03:36:15 +00:00
dyson
21d1d08bb0 Correct the check for multiword dma. It was incorrectly checking
for multiword dma mode 4 (which doesn't exist.)
Submitted by:	John Hood
1997-12-19 02:25:51 +00:00
bde
50c5a05b16 Augment $PATH to ensure searching of /sbin and /usr/sbin for sysctl
instead of using an absolute path to sysctl.
Problem reported by: ache
1997-12-18 21:03:04 +00:00
dg
0f803af547 Fixed a missing splx(s) bug in tcp_usr_send(). 1997-12-18 09:50:38 +00:00
dg
5b21cc8b37 Call in_pcballoc() at splnet(). As near as I can tell, this won't fix
any instability problems, but it was wrong nonetheless and will be
required in an upcoming round of PCB changes.
1997-12-18 09:13:39 +00:00
peter
1c1263e645 Add missing references to Xcpuast, get_isrlock and checkstate_probed_cpus 1997-12-18 02:09:29 +00:00
wollman
438677fced Revert poll() for UFS files to traditional behavior where polling for read-
or writability always returns true.  This works around bugs in netscape and
squid, at a minimum.
1997-12-17 14:44:23 +00:00
kato
b26eaaec52 Regenerate (fix argument of linux_nice). 1997-12-17 03:16:11 +00:00
kato
ad6e872947 I should not edit linux_prot.h directly. Fix the argument of linux_nice.
Pointed out by:	Eivind Eklund <eivind@FreeBSD.ORG>
	NOPROTO	LINUX	{ int getpgrp(void); }
66	NOPROTO	LINUX	{ int setsid(void); }
67	STD	LINUX	{ int linux_sigaction(int sig, \
			    struct linux_sigaction *nsa, \
			    struct linux_sigaction *osa); }
68	STD	LINUX	{ int linux_siggetmask(void); }
69	STD	LINUX	{ int linux_sigsetmask(linux_sigset_t mask); }
70	NOPROTO	LINUX	{ int setreuid(int ruid, int euid); }
71	NOPROTO	LINUX	{ int setregid(int rgid, int egid); }
72	STD	LINUX	{ int linux_sigsuspend(int restart, \
			    linux_sigset_t oldmask, linux_sigset_t mask); }
73	STD	LINUX	{ int linux_sigpending(linux_sigset_t *mask); }
74	NOPROTO	LINUX	{ int osethostname(char *hostname, \
			    u_int len);}
75	NOPROTO	LINUX	{ int osetrlimit(u_int which, \
			    struct ogetrlimit *rlp); }
76	NOPROTO	LINUX	{ int ogetrlimit(u_int which, \
			    struct ogetrlimit *rlp); }
77	NOPROTO	LINUX	{ int getrusage(int who, struct rusage *rusage); }
78	NOPROTO	LINUX	{ int gettimeofday(struct timeval *tp, \
			    struct timezone *tzp); }
79	NOPROTO	LINUX	{ int settimeofday(struct timeval *tp, \
			    struct timezone *tzp); }
80	NOPROTO	LINUX	{ int getgroups(u_int gidsetsize, gid_t *gidset); }
81	NOPROTO	LINUX	{ int setgroups(u_int gidsetsize, gid_t *gidset); }
82	STD	LINUX	{ int linux_select(struct linux_select_argv *ptr); }
83	STD	LINUX	{ int linux_symlink(char *path, char *to); }
84	NOPROTO	LINUX	{ int ostat(char *path, struct ostat *up); }
85	STD	LINUX	{ int linux_readlink(char *name, char *buf, \
			    int count); }
86	STD	LINUX	{ int linux_uselib(char *library); }
87	NOPROTO	LINUX	{ int swapon(char *name); }
88	NOPROTO	LINUX	{ int reboot(int opt); }
89	STD	LINUX	{ int linux_readdir(int fd, struct linux_dirent *dent, \
			    unsigned int count); }
90	STD	LINUX	{ int linux_mmap(struct linux_mmap_argv *ptr); }
91	NOPROTO	LINUX	{ int munmap(caddr_t addr, int len); }
92	STD	LINUX	{ int linux_truncate(char *path, long length); }
93	NOPROTO	LINUX	{ int oftruncate(int fd, long length); }
94	NOPROTO	LINUX	{ int fchmod(int fd, int mode); }
95	NOPROTO	LINUX	{ int fchown(int fd, int uid, int gid); }
96	NOPROTO	LINUX	{ int getpriority(int which, int who); }
97	NOPROTO	LINUX	{ int setpriority(int which, int who, int prio); }
98	NOPROTO	LINUX	{ int profil(caddr_t samples, u_int size, \
			    u_int offset, u_int scale); }
99	STD	LINUX	{ int linux_statfs(char *path, \
			    struct linux_statfs_buf *buf); }
100	STD	LINUX	{ int linux_fstatfs(int fd, \
			    struct linux_statfs_buf *buf); }
101	STD	LINUX	{ int linux_ioperm(unsigned int lo, \
			    unsigned int hi, int val); }
102	STD	LINUX	{ int linux_socketcall(int what, void *args); }
103	STD	LINUX	{ int linux_ksyslog(int what); }
104	STD	LINUX	{ int linux_setitimer(u_int which, \
			    struct itimerval *itv, struct itimerval *oitv); }
105	STD	LINUX	{ int linux_getitimer(u_int which, \
			    struct itimerval *itv); }
106	STD	LINUX	{ int linux_newstat(char *path, \
			    struct linux_newstat *buf); }
107	STD	LINUX	{ int linux_newlstat(char *path, \
			    struct linux_newstat *buf); }
108	STD	LINUX	{ int linux_newfstat(int fd, struct linux_newstat *buf); }
109	STD	LINUX	{ int linux_uname(struct linux_old_utsname *up); }
110	STD	LINUX	{ int linux_iopl(int level); }
111	STD	LINUX	{ int linux_vhangup(void); }
112	STD	LINUX	{ int linux_idle(void); }
113	STD	LINUX	{ int linux_vm86(void); }
114	STD	LINUX	{ int linux_wait4(int pid, int *status, \
			    int options, struct rusage *rusage); }
115	STD	LINUX	{ int linux_swapoff(void); }
116	STD	LINUX	{ int linux_sysinfo(void); }
117	STD	LINUX	{ int linux_ipc(int what, int arg1, int arg2, int arg3, \
			    caddr_t ptr); }
118	NOPROTO	LINUX	{ int fsync(int fd); }
119	STD	LINUX	{ int linux_sigreturn(struct linux_sigcontext *scp); }
access
1997-12-17 03:12:35 +00:00
eivind
8c80194b9d EXT2FS and MSDOSFS to the opt_dontuse bin. 1997-12-16 23:59:37 +00:00
eivind
ee509b6933 Fix my typo.
Submitted by: helbig
1997-12-16 22:50:18 +00:00
eivind
0d3c659bde Make LINT compile again after wollman introduced poll() here.
Overlooked by:	wollman
1997-12-16 22:28:26 +00:00
eivind
9984ce1b48 Regenerate after changing makesyscalls.sh. 1997-12-16 22:27:22 +00:00
eivind
116485ab6e Move around opt_compat include to accomodate Linulator brokenness (for
the time being).
1997-12-16 18:51:45 +00:00
eivind
670fa6a5dd Make hidden COMPAT_43 dependencies explict. Options in headers is a
pain in the backside.
1997-12-16 18:49:23 +00:00
eivind
274059dce1 Handle COMPAT_43 define -> option change. 1997-12-16 18:45:50 +00:00
eivind
786069b3ca Whoops - fix this after yesterday's IPX option changes. Also fix
minor buglet when neither bsdcomp, deflate or filter is used.

Pointed out by:	Chris Timmons <skynyrd@opus.cts.cwu.edu>
1997-12-16 18:28:07 +00:00
eivind
01dd6091ed Make COMPAT_43 and COMPAT_SUNOS new-style options. 1997-12-16 17:40:42 +00:00
dg
78fabc0578 Fix bug where a struct buf was free()'d back to the system malloc pool.
Quite amazing that the system runs at all with this bug. Also present in
2.2.5. The bug appears to have come in with changes in rev 1.53.

PR:		might fix PR#5313
Submitted by:	bde
1997-12-16 15:40:29 +00:00
kato
fd72a030d7 Don't use PG_N if EPSON PC-486HX/HG/HA (PC-9801 compatible) are
detected.  These machine cannot make L2 cache write-through by PG_N,
and only I/O access (undocumented) can do that.  If PG_N is used,
system hangs.

Reviewed by:	tos@fa2.so-net.or.jp (Toshiyuki Kawashima)
1997-12-16 10:22:49 +00:00
eivind
d9973ba95b Convert SUIDDIR fully to a new-style option.
Forgotten by: julian
1997-12-15 21:51:45 +00:00
eivind
3452c23db8 Throw options IPX, IPXIP and IPTUNNEL into opt_ipx.h.
The #ifdef IPXIP in netipx/ipx_if.h is OK (used from ipx_usrreq.c and
ifconfig.c only).

I also fixed a typo IPXTUNNEL -> IPTUNNEL (and #ifdef'ed out the code
inside, as it never could have compiled - doh.)
1997-12-15 20:31:25 +00:00
kato
4595f412fe Sync with sys/i386/i386/microtime.s revision 1.35. 1997-12-15 08:37:13 +00:00
msmith
b878831388 As described by the submitter:
These patches enables us to play quake2 .

Support linux keyboard ioctl for setting RAW, MEDIUMRAW and XLATE.

Support linux virtual terminal operations:
 OPENQRY, GETMODE, SETMODE, GETSTATE, ACTIVATE, and WAITACTIVE.

Submitted by:	Amancio Hasty <hasty@rah.star-gate.com>
1997-12-15 06:09:11 +00:00
dyson
fc1a352788 Fix a recursive kernel_map lock problem in vm_zone allocator.
PR:	5298
1997-12-15 05:16:09 +00:00
wollman
1a06d88098 Add support for poll(2) on files. vop_nopoll() now returns POLLNVAL
if one of the new poll types is requested; hopefully this will not break
any existing code.  (This is done so that programs have a dependable
way of determining whether a filesystem supports the extended poll types
or not.)

The new poll types added are:

	POLLWRITE - file contents may have been modified
	POLLNLINK - file was linked, unlinked, or renamed
	POLLATTRIB - file's attributes may have been changed
	POLLEXTEND - file was extended

Note that the internal operation of poll() means that it is impossible
for two processes to reliably poll for the same event (this could
be fixed but may not be worth it), so it is not possible to rewrite
`tail -f' to use poll at this time.
1997-12-15 03:09:59 +00:00
msmith
22a4475679 Consult sa_len before trampling it with MSG_COMPAT set.
PR:             kern/5291
Submitted by:   pb@fasterix.freenix.org (Pierre Beyssac)
1997-12-15 02:29:11 +00:00
tegge
ba494eff3a Add support for low resolution SMP kernel profiling.
- A nonprofiling version of s_lock (called s_lock_np) is used
    by mcount.

  - When profiling is active, more registers are clobbered in
    seemingly simple assembly routines. This means that some
    callers needed to save/restore extra registers.

  - The stack pointer must have space for a 'fake' return address
    in idle, to avoid stack underflow.
1997-12-15 02:18:35 +00:00
tegge
06b61e24e4 Don't forward hardclock or statclock to stopped cpus. Disable forwarding
when a panic has occured.
1997-12-15 01:14:10 +00:00
sef
fa2097bae6 Explicitly use the _IOC macro directly. This changes the ioctl command
numbers, so any programs using it need to be recompiled.
1997-12-15 00:29:41 +00:00
jdp
8e5b281441 Make gzipped dynamically linked executables work again. There was
an old bug here that failed to copy the a.out header into memory
properly.  It didn't matter until changes were made recently to
the dynamic linker.
1997-12-14 19:36:24 +00:00
kato
9f9d754997 Sync with sys/i386/i386/machdep.c revision 1.279. 1997-12-14 12:31:44 +00:00
kato
dce0dc136e Sync with sys/i386/conf/files.i386 revision 1.182. 1997-12-14 12:30:54 +00:00
dyson
e86cd387f8 Slight improvement to the vm_zone stats output. Also, some other superficial
cleanups.
1997-12-14 05:17:44 +00:00
msmith
7bbd5d4870 As described by the submitter:
- emulate Linux IP_HDRINCL behaviour in sendto(): byte order fixed
	  Note that we do an extra getsockopt() on every sendto()
	  to check if the option is set because we don't keep state
	  in the emulator code. Is there a better way to implement
	  this?
	- correct a bug (value of "name" not passed) with
	  getsockopt()

Submitted by:	pb@fasterix.freenix.org (Pierre Beyssac)
1997-12-14 03:17:54 +00:00
msmith
c10e8d5102 As described by the submitter:
... fix a bug with orecvfrom() or recvfrom() called with
the MSG_COMPAT flag on kernels compiled with the COMPAT_43 option.
The symptom is that the fromaddr is not correctly returned.

This affects the Linux emulator.

Submitted by:	pb@fasterix.freenix.org (Pierre Beyssac)
1997-12-14 03:15:21 +00:00
dyson
738872cad6 After one of my analysis passes to evaluate methods for SMP TLB mgmt, I
noticed some major enhancements available for UP situations.  The number
of UP TLB flushes is decreased much more than significantly with these
changes.  Since a TLB flush appears to cost minimally approx 80 cycles,
this is a "nice" enhancement, equiv to eliminating between 40 and 160
instructions per TLB flush.

Changes include making sure that kernel threads all use the same PTD,
and eliminate unneeded PTD switches at context switch time.
1997-12-14 02:11:23 +00:00
jraynard
acf3f6c346 Allow slow SCSI CDROMs more time to start up.
PR:		5181
Submitted by:	Wilko Bulte <wilko@yedi.iaf.nl>
1997-12-14 00:32:33 +00:00
pst
186bde1bd3 Bring in NetBSD compatible & augmented RCSID/COPYRIGHT macros 1997-12-13 20:39:14 +00:00
bde
2c703bda5c Fixed EOF handing.
1. SS_CANTRCVMORE was initially set on the wrong socket, so reads
when there has never been a writer on the socket did not return 0.
Note that such reads are only possible if the fifo was opened in
(O_RDONLY | O_NONBLOCK) mode.

2. SS_CANTSENDMORE was initially set on the wrong socket, but this
was harmless because the wrong socket is never sent from and there
is no need to set the flag initially on the right socket (since open
in (O_WRONLY | O_NONBLOCK) mode fails if there is no reader...).

3. SS_CANTRCVMORE was cleared when read() returns.  This broke the
case where read() returns 0 - subsequent reads are supposed to
return 0 until a writer appears.  There is no need to clear the
flag when read() returns, since it is cleared correctly when a
writer appears.
1997-12-13 13:49:59 +00:00
bde
54238221e6 Restored fifo_pathconf() from rev.1.32. vop_stdpathconf() is too
general to be of much use.  Using it here weakened the _PC_MAX_CANON,
_PC_MAX_INPUT and _PC_VDISABLE cases.

fifo_pathconf() is not quite correct either.  _PC_CHOWN_RESTRICTED
and _PC_LINK_MAX should be handled by the host file system.  For
directories, the host file system should let us handle _PC_PIPE_BUF.
1997-12-13 12:58:09 +00:00
bde
6593562cbe Restored ufs_pathconf() from rev.1.61. vop_stdpathconf() is too
general to be of much use.  Using it here broke the _PC_NAME_MAX,
_PC_NO_TRUNC and _PC_PATH_MAX cases, and weakened the _PC_MAX_CANON,
_PC_MAX_INPUT and _PC_VDISABLE cases.
1997-12-13 12:30:34 +00:00
sef
f13ddbc865 Change the ioctls for procfs around a bit; in particular, whever possible,
change from

	ioctl(fd, PIOC<foo>, &i);

to

	ioctl(fd, PIOC<foo>, i);

This is going from the _IOW to _IO ioctl macro.  The kernel, procctl, and
truss must be in synch for it all to work (not doing so will get errors about
inappropriate ioctl's, fortunately).  Hopefully I didn't forget anything :).
1997-12-13 03:13:49 +00:00
tegge
982ed8caa2 Add needed #include.
Problem found by: Bruce Evans <bde@zeta.org.au>
1997-12-12 21:45:23 +00:00
peter
741a6bac34 Fix(?) some style consistancy breakage and do some other nit-picking on
the SUIDDIR changes.
1997-12-12 14:14:44 +00:00
peter
d5ef9c3e61 I've been using these tweaks to enable the sound driver to talk to the
(mutant) Crystal CSS4236 chip on the Intel PR440FX SMP motherboard.

XXX this uses some rather ugly PnP bootstrap code that is *NOT* compatable
with 'controller pnp0' or *ANY* other PnP devices.  If you use some other
PnP devices, enabling css0 will burn your house down. :-]  The
"simplified" PnP init sequence directly blats your config(8) settings onto
the chip.  I'm pretty sure 'css0' will conflict with 'mss0', this whole
area desperately needs a cleanup.

I have been using the following with some success on the PR440FX:
controller   snd0
device css0  at isa? port 0x534 irq 5 drq 1 flags 0x08 vector adintr
device opl0  at isa? port 0x388
device mpu0  at isa? port 0x330 irq 10 vector mpuintr
1997-12-12 14:08:50 +00:00
dyson
1835b7ab0e We have had support for running the kernel daemons as threads for
quite a while, but forgot to do so.  For now, this code supports
most daemons  running as kernel threads in UP kernels, and as
full processes in SMP.  We will soon be able to run them as
threads in SMP, but not yet.
1997-12-12 04:00:59 +00:00
sef
9fd84ad693 Fix a problem with procfs_exit() that resulted in missing some procfs
nodes; this also apparantly caused a panic in some circumstances.
Also, since procfs_exit() is getting rid of the nodes when a process
exits, don't bother checking for the process' existance in procfs_inactive().
1997-12-12 03:33:43 +00:00
dyson
043ed4f1ba Fix the prototype for swapout_procs();
Submitted by:	dima@best.net
1997-12-11 02:10:55 +00:00
kato
9c8df1263b Sync with sys/i386/conf/files.i386, majors.i386 and options.i386
revisions 1.181, 1.23 and 1.64, respectively.
1997-12-10 09:28:59 +00:00
dyson
eb84a1691e Quiet some lint. 1997-12-10 04:14:23 +00:00
jamil
4953cd7c9e eliminated a previously unnoticde compile warning about use of
__inline, not good to use anyway ?!?!!
1997-12-09 12:41:13 +00:00
jamil
5dfabcb950 the alog.c file respectively, added in wrong order by accident 1997-12-09 12:07:50 +00:00
jamil
751d260ffd add entry in LINT for alog driver
added line to files.i386 to compile in alog.c optionally as a driver
1997-12-09 12:04:49 +00:00