Commit Graph

5749 Commits

Author SHA1 Message Date
Søren Schmidt da040b2280 Fixed bug in pasting 8bit char (ache).
Added linefeeds in cuts that extend beyond one line.
Prepared for the mousefunctions to be used in nontext modes.
1996-06-26 13:04:53 +00:00
John Dyson 4b83b27fea Fix a problem that caused system crashes after physio. This problem
was due to non-aligned 64K transfers taking 17 pages.  We currently
do not support >16 page transfers.  The transfer is unfortunately truncated,
but since buffers are usually malloced, this is a problem only once in
a while.  Savecore is a culprit, but tar/cpio usually aren't.  This
is NOT the final fix (which is likely a bouncing scheme), but will at
least keep the system from crashing.
1996-06-26 05:52:15 +00:00
John Dyson 38efa82b23 This commit does a couple of things:
Re-enables the RSS limiting, and the routine is now tail-recursive,
	making it much more safe (eliminates the possiblity of kernel stack
	overflow.) Also, the RSS limiting is a little more intelligent about
	finding the likely objects that are pushing the process over the limit.

	Added some sysctls that help with VM system tuning.

New sysctl features:
	1)	Enable/disable lru pageout algorithm.
		vm.pageout_algorithm = 0, default algorithm that works
			well, especially using X windows and heavy
			memory loading.  Can have adverse effects,
			sometimes slowing down program loading.

		vm.pageout_algorithm = 1, close to true LRU.  Works much
			better than clock, etc.  Does not work as well as
			the default algorithm in general.  Certain memory
			"malloc" type benchmarks work a little better with
			this setting.

		Please give me feedback on the performance results
		associated with these.

	2)	Enable/disable swapping.
		vm.swapping_enabled = 1, default.

		vm.swapping_enabled = 0, useful for cases where swapping
			degrades performance.

		The config option "NO_SWAPPING" is still operative, and
		takes precedence over the sysctl.  If "NO_SWAPPING" is
		specified, the sysctl still exists, but "vm.swapping_enabled"
		is hard-wired to "0".

Each of these can be changed "on the fly."
1996-06-26 05:39:27 +00:00
John Dyson f43467241e When page table pages were removed from process address space, the
resident page stats were not being decremented.  This mode corrects
that problem.
1996-06-26 05:05:52 +00:00
Bruce Evans c673fe98d7 Added #include of <machine/md_var.h>. This will be needed when
some declarations are moved from <machine/cpufunc.h> to better
places.
1996-06-25 20:31:01 +00:00
Bruce Evans c11bd94104 Fixed the `machine' link. It pointed to the wrong place, and was created
too late to be used in all cases.  It should probably be created (early)
in bsd.kmod.mk for all LKMs.

Use cc instead of cpp | as for the same reasons as in the kernel makefile.
CFLAGS isn't split up as well as in the kernel makefile, but cc doesn't
pass compiler warning flags to cpp, so there is no need to split it.
1996-06-25 20:13:12 +00:00
Bruce Evans 79df6d8597 trap.c:
Fixed profiling of system times.  It was pre-4.4Lite and didn't support
statclocks.  System times were too small by a factor of 8.

Handle deferred profiling ticks the 4.4Lite way: use addupc_task() instead
of addupc().  Call addupc_task() directly instead of using the ADDUPC()
macro.

Removed vestigial support for PROFTIMER.

switch.s:
Removed addupc().

resourcevar.h:
Removed ADDUPC() and declarations of addupc().

cpu.h:
Updated a comment.  i386's never were tahoe's, and the deferred profiling
tick became (possibly) multiple ticks in 4.4Lite.

Obtained from:	mostly from NetBSD
1996-06-25 20:02:16 +00:00
Bruce Evans 93f4b1bf1b Save John Polstra's initial fix for profiling for reference. The
multiplication in addupc() overflowed for addresses >= 256K, assuming
the usual profil(2) scale parameter of 0x8000.  addupc() will go away
soon.

Submitted by:	John Polstra <jdp@polstra.com>
1996-06-25 19:25:25 +00:00
Søren Schmidt ad0c0c784f Change the way moused talk to syscons, now its only delivering mouseevents
via an ioctl (MOUSE_ACTION).
Fixed a couple of bugs (destructive cursor, uncut, jitter).
Now applications can use the mouse via the MOUSE_MODE ioctl, its
possible to have a signal sent on mouseevents, makeing an event loop
in the application take over mouseevents.
1996-06-25 08:54:57 +00:00
David Greenman b9355dedd9 Fixed end condition for clustered reads.
Submitted by:	Kirk McKusick via Lite-2 and email
1996-06-25 03:00:44 +00:00
John Dyson cb87c9be58 Limit the scan for preloading pte's to the end of an object. 1996-06-25 00:39:21 +00:00
John Dyson f0e2953e5e Fix some serious problems with limits checking in the sbrk(2)/brk(2)
code.
Reviewed by:	bde
1996-06-25 00:36:46 +00:00
Alexander Langer 830b0d3039 Allow fragment checking to work with specific protocols.
Reviewed by:	phk

Reject the addition of rules that will never match (for example,
1.2.3.4:255.255.255.0).  User level utilities specify the policy by either
masking the IP address for the user (as ipfw(8) does) or rejecting the
entry with an error.  In either case, the kernel should not modify chain
entries to make them work.
1996-06-25 00:22:20 +00:00
Gary Palmer 545f9f440b Remove another extraneous setting of if_lastchange 1996-06-24 21:56:39 +00:00
Justin T. Gibbs 6a2631bf25 Ensure that media protection is released before attempting to eject the
media in all cases.

Remove SCSI_2_MAX_DENSITY_CODE definition and rely on the device to tell
us if we attempt an invalid setting.

Closes PR 1245.

Submitted by:	fredriks@mcs.com a few changes by me.
1996-06-24 04:54:32 +00:00
John Dyson a001376dc3 Remove RSS limiting until I rewrite the code to be non-recursive. The
code can overrun the kernel stack under very stressful conditions.
1996-06-24 04:30:24 +00:00
Jordan K. Hubbard cd9a2f5c28 Bring in my changes for removing the pestilent obj links (unless you
really want them) from /usr/src.  This is the final version of the
patches, incorporating the feedback I've received from -current.
1996-06-24 04:26:21 +00:00
Justin T. Gibbs 356cbcce49 Fix problem with scb flag handing that crept in with the SCB paging support.
This only affected userland initiated device resets (using the reset command
from cdplay for instance).

Convert some spaces to tabs.
1996-06-23 20:02:37 +00:00
Andrey A. Chernov e72a188ebc Oops, forget the fact that LINT compiles (fixing previos PAS commi) 1996-06-23 19:46:46 +00:00
Andrey A. Chernov 5839779af2 Describe the way how to add OPL for PAS without conflict 1996-06-23 19:41:34 +00:00
Bruce Evans cc3d522683 Unstaticize psratio and staticize profprocs. psratio needs to be exported
to trap.c to fix user profiling.
1996-06-23 17:40:47 +00:00
Bruce Evans 8cd5acbce0 Don't truncate minor or major numbers in the nfsv3 client. 1996-06-23 17:19:25 +00:00
Bruce Evans ea959743cb Moved declarations of static functions to the correct file. This fixes
hundreds of warnings from -Wunused in lkm/syscons/*.
1996-06-23 17:12:05 +00:00
Bruce Evans 6fe10f76c3 Removed unused #include. Linux doesn't support SCO consoles. 1996-06-23 17:08:11 +00:00
Bruce Evans 946a489fe1 Forward-declare a struct tag so that this doesn't depend on a side effect
of indirectly including <i386/isa/isa_device.h>.
1996-06-23 15:02:02 +00:00
Bruce Evans 488ed21e9f Don't add -I/sys to CFLAGS. bsd.kmod.mk adds the correct (relative)
path.
1996-06-23 14:58:14 +00:00
Bruce Evans e0ddbefc46 Don't claim to be a VFS_LKM - generate vnode_if.h by putting it in SRCS.
Don't add -I/sys to CFLAGS.  bsd.kmod.mk adds the correct (relative)
path.
1996-06-23 14:56:04 +00:00
Bruce Evans a7d87a6714 Don't (re)define ACTUALLY_LKM_NOT_KERNEL. It wasn't even used by the
joy driver proper.

Don't add -I/sys to CFLAGS.  bsd.kmod.mk adds the correct (relative)
path.
1996-06-23 14:52:20 +00:00
Bruce Evans fb2604799e Finished converting ipfw to use opt_ipfw.h. 1996-06-23 14:43:55 +00:00
Bruce Evans 5c496ee31e Don't (re)define or use ACTUALLY_LKM_NOT_KERNEL - use the existing
definition of QCAM_MODULE for everything involving LKM'ness.

Makefile:
Don't add -I/sys to CFLAGS.  bsd.kmod.mk adds the correct (relative)
path.
1996-06-23 14:41:55 +00:00
Bruce Evans 7472e2e0f8 Use IPFIREWALL_MODULE instead of ACTUALLY_LKM_NOT_KERNEL to indicate
LKM'ness.  ACTUALLY_LKM_NOT_KERNEL is supposed to be so ugly that it
only gets used until <machine/conf.h> goes away.  bsd.kmod.mk should
define a better-named general macro for this.  Some places use
PSEUDO_LKM.  This is another bad name.

Makefile:
Added IPFIREWALL_VERBOSE_LIMIT option (commented out).
1996-06-23 14:28:02 +00:00
Bruce Evans a24ed11695 Disabled unusable union lkm. 1996-06-23 13:31:20 +00:00
Bruce Evans a675c0c67e Describe MAXMEM better. Enable it by default. (It's a positive option.
Only negative options in LINT should be enabled.)
1996-06-23 13:28:04 +00:00
Gary Palmer 0cf8755c9b Remove an un-necessary call to microtime() to set if_lastchange
as it is set in the call to if_down in the line above
1996-06-23 00:51:05 +00:00
Joerg Wunsch 06e958d471 Dump the timeout for st_erase().
Fixes PR # kern/1341: Bug fix for SCSI tape

Submitted by:	tundra@tundrware.com
1996-06-22 14:57:55 +00:00
Peter Wemm 51a109a174 Set the rmx.rmx_expire to 0 when creating fake ethernet addresses for the
broadcast and multicast routes, otherwise they will be expired by
arptimeout after a few minutes, reverting to " (incomplete)". This makes
the work done by rev 1.27 stay around until the route itself is deleted.
This is mainly cosmetic for 'arp' and 'netstat -r'.
1996-06-21 21:45:58 +00:00
Peter Wemm 17b944a6a7 When writing the settings for stop bits and output hardware flow control,
things tend to work better if you write the settings to the correct
register.. (*blush*).  This subtle bug has been haunting me for ages, and
will solve a few problems that have been reported to me.

Also, take a shot at fixing the serial BREAK processing, what was there
before never really worked.  (There is a PR on this I think)
1996-06-21 21:35:01 +00:00
Søren Schmidt ab35f219ac Oops, fix a bug that caused updates to the screen to happen, without
anything actually changed, in this case the mousepointer logic.
1996-06-21 11:31:09 +00:00
Søren Schmidt de4d1b835e Some news for syscons (long overdue):
Real support for a Textmode mousecursor, works by reprogramming the
charset. Together with this support for cut&paste in text mode.
To use it a userland daemon is needed (moused), which provides
the interface to the various mice protokols.
Bug fixes here and there, all known PR's closed by this update.
1996-06-21 07:19:18 +00:00
John Dyson 2a4eb04bfd Improve algorithm for page hash queue. It was previously about
as bad as it could be.  This algorithm appears to improve fork
performance (barely) measurably.
1996-06-21 05:39:22 +00:00
Bill Fenner 94334d8fc4 Use the route that's guaranteed to exist when picking a source address
for ARP requests.

The NetBSD version of this patch (see NetBSD PR kern/2381) has this change
already.  This should close our PR kern/1140 .

Although it's not quite what he submitted, I got the idea from him so
Submitted by:	Jin Guojun <jin@george.lbl.gov>
1996-06-20 22:53:08 +00:00
Bill Fenner d7e74838d6 Remove one last rip_output from inetsw (gpalmer missed it in rev 1.30) 1996-06-20 17:52:32 +00:00
Nate Williams 17040b78cd Put the 'debug' messages of the type:
/kernel: in_rtqtimo: adjusted rtq_reallyold to 1066
  /kernel: in_rtqtimo: adjusted rtq_reallyold to 710
inside of #ifdef DIAGNOSTIC to avoid the support questions from folks
asking what this means.
1996-06-20 15:41:23 +00:00
David Greenman 1293685583 Properly account for non-page aligned buffers. 1996-06-20 08:07:30 +00:00
David Greenman ac269d78be Minor KNF formatting change to vmapbuf() and vunmapbuf(). 1996-06-20 01:47:21 +00:00
Garrett Wollman b8dc74a3a8 Set IFF_RUNNING on the loopback interface. 1996-06-19 16:24:10 +00:00
Nate Williams a85fadfc45 Macro expressions should be fully parenthesized! Fix the MAXMEM
definition although it would work as it was written.

options        "MAXMEM=(128*1024)"

Suggested by:	bde
1996-06-19 15:37:52 +00:00
John Dyson 0157d6d925 Clean up vmapbuf and vunmapbuf significantly. The previous code was
very rough.
1996-06-19 03:39:24 +00:00
Julian Elischer 8e3bda0682 Submitted by: archie@whistle.com
gary went a little overboard on commenting out unused variables.
Variables needed for ISO, LLC and NETATALK
were only enabled for ISO &  LLC.. so NETATALK bombed.
1996-06-19 01:50:10 +00:00
Nate Williams b279668708 Document MAXMEM option.
[ Closes PR#1334, slightly modified by me ]

Submitted by:	James Raynard <james@jraynard.demon.co.uk>
1996-06-18 23:21:28 +00:00