Commit Graph

1578 Commits

Author SHA1 Message Date
Doug Rabson
aebed8b0ba Make DDB work again after I broke it :-(. 1998-06-08 08:43:20 +00:00
Poul-Henning Kamp
48115288df Add a member function more to the timecounters, this one is for use
with latch based PPS implementations.  The client that uses it will
be committed after more testing.
1998-06-07 20:36:55 +00:00
Doug Rabson
ecbb00a262 This commit fixes various 64bit portability problems required for
FreeBSD/alpha.  The most significant item is to change the command
argument to ioctl functions from int to u_long.  This change brings us
inline with various other BSD versions.  Driver writers may like to
use (__FreeBSD_version == 300003) to detect this change.

The prototype FreeBSD/alpha machdep will follow in a couple of days
time.
1998-06-07 17:13:14 +00:00
Poul-Henning Kamp
dbb3475507 Add a "this" style argument and a "void *private" so timecounters can
figure out which instance to wount with.
1998-06-07 08:40:53 +00:00
Jordan K. Hubbard
100047083e Add the DPT driver here. It's kinda ironic that it got enabled in -stable
first. :)
PR:		6848
1998-06-03 13:33:34 +00:00
Bruce Evans
56fe964551 Ifdefed the netisr support.
PR:		6760
Reviewed by:	joerg
1998-06-03 07:56:59 +00:00
Mike Smith
f9c9bbc054 If vm86 services are available, use these to perform the APM BIOS
probe and intialisation.  This will ultimately remove the grubby (but
functional) hack that copies a real-mode function into low memory
early in locore.s.
1998-06-03 01:59:42 +00:00
Steve Price
a4f54cdf08 Make this ${.OBJDIR} and ${.CURDIR} aware.
PR:		2565
1998-05-31 22:40:49 +00:00
Bruce Evans
cd55b8f46c Converted the ICU-level interrupt tests (3, 5 and 8) in sioprobe() into
a test of the irq number, and made failure of this test non-fatal.
Removed related unused complications for the APIC_IO case.  Removed the
no-test3 flag.

Deverbosified the failure messages for the other tests.  Removed the
per-port verbose flag - just use the general verbose flag.
1998-05-31 10:53:55 +00:00
Poul-Henning Kamp
e796e00de3 Some cleanups related to timecounters and weird ifdefs in <sys/time.h>.
Clean up (or if antipodic: down) some of the msgbuf stuff.

Use an inline function rather than a macro for timecounter delta.

Maintain process "on-cpu" time as 64 bits of microseconds to avoid
needless second rollover overhead.

Avoid calling microuptime the second time in mi_switch() if we do
not pass through _idle in cpu_switch()

This should reduce our context-switch overhead a bit, in particular
on pre-P5 and SMP systems.

WARNING:  Programs which muck about with struct proc in userland
will have to be fixed.

Reviewed, but found imperfect by:       bde
1998-05-28 09:30:28 +00:00
Dag-Erling Smørgrav
627d8c5f42 Use switch instead of if/else chain for 686 model identification.
Add precise model identification for 586-family CPUs.
1998-05-22 22:15:14 +00:00
Dag-Erling Smørgrav
47f4979594 Add CPU_PII to the list. 1998-05-22 00:03:23 +00:00
Dag-Erling Smørgrav
25bc695c77 Correctly identify the precise CPU model within the 686 family: instead
of just printing "Pentium Pro", check the model (cpu_id & 0xf0) and print
the appropriate information.
1998-05-21 22:53:24 +00:00
John Dyson
cf2819ccb8 Make flushing dirty pages work correctly on filesystems that
unexpectedly do not complete writes even with sync I/O requests.
This should help the behavior of mmaped files when using
softupdates (and perhaps in other circumstances also.)
1998-05-21 07:47:58 +00:00
Bill Paul
e21faf3e33 And entries for ThunderLAN driver. 1998-05-21 03:22:20 +00:00
Peter Dufault
daa2c78fae Remove option for SCHED_FIFO. With this optional, SCHED_FIFO
is the same as RTPRIO_IDLE when it falls through to the default.
1998-05-19 20:59:07 +00:00
Peter Wemm
09685dbd57 Missing parens caused cpu features not to be printed for cyrix >= M2/MX.
Althought the comments say the datasheet doesn't list the device ID
registers on the M2/MX, they seem to be there and quite alive.
(It's interesting to note that the M2/MX calls itself a 686 class cpu but
 is missing a heck of a lot of features, including VME, PGE, PSE, etc)
1998-05-19 19:40:45 +00:00
Poul-Henning Kamp
4b9afc97a7 Change a data type internal to the timecounters, and remove the "delta"
function.

Reviewed, but not entirely approved by: bde
1998-05-19 18:48:30 +00:00
Poul-Henning Kamp
58067a9909 Make the size of the msgbuf (dmesg) a "normal" option. 1998-05-19 08:58:53 +00:00
Tor Egge
12d311d02e Back out part of revision 1.198 commit (clearing kernel stack pages).
By request from David Greenman <dg@root.com>
1998-05-19 00:06:35 +00:00
Tor Egge
afc6ea238f Disallow reading the current kernel stack. Only the user structure and
the current registers should be accessible.
Reviewed by:	David Greenman <dg@root.com>
1998-05-19 00:00:14 +00:00
Tor Egge
5d183e9691 Change simple lock handling to not depend upon having a local apic
available.  The per-cpu variable ss_tpr has been replaced by ss_eflags.
This reduced the number of interrupts sent to the wrong CPU, due to
the cpu having the global lock being inside a critical region.

Remove some unneeded manipulation of tpr register in mplock.s.

Adjust code in mplock.s to be aware of variables on the stack being
destroyed by MPgetlock if GRAB_LOPRIO is defined.
1998-05-17 23:08:04 +00:00
Tor Egge
2f1e70693d Add forwarding of roundrobin to other cpus. This gives a more regular
update of cpu usage as shown by top when one process is cpu bound
(no system calls) while the system is otherwise idle (except for top).

Don't attempt to switch to the BSP in boot().  If the system was idle when
an interrupt caused a panic, this won't work.  Instead, switch to the BSP
in cpu_reset.

Remove some spurious forward_statclock/forward_hardclock warnings.
1998-05-17 22:12:14 +00:00
Tor Egge
167a4d818c Use a higher priority interrupt vector for 8254 timer interrupts. 1998-05-17 21:15:18 +00:00
Tor Egge
5931a9c24e For SMP, use prv_PPAGE1/prv_PMAP1 instead of PADDR1/PMAP1.
get_ptbase and pmap_pte_quick no longer generates IPIs.
This should reduce the number of IPIs during heavy paging.
1998-05-17 18:53:19 +00:00
Tor Egge
cf4b29e405 Clear kernel stack pages before usage.
Correct panic message in pmap_zero_page (s/CMAP /CMAP2 /).
1998-05-17 17:43:13 +00:00
Poul-Henning Kamp
c21410e119 s/nanoruntime/nanouptime/g
s/microruntime/microuptime/g

Reviewed by:	bde
1998-05-17 11:53:46 +00:00
KATO Takenori
8e929d6553 Some of newer PC-98 may cause "Windows Protection Fault" when booting
Windows 95 after rebooting FreeBSD without power off.  In PC-98
system, reboot mode is set via I/O port 0x37 in cpu_reset(), and
accessing of this port is the reason of the problem.  To avnoid the
fault, current status of reboot mode should be checked before
accessing the I/O port.
1998-05-16 14:44:11 +00:00
KATO Takenori
0d303cbabf Disable local APIC in UP kernel. Intel specification update describes
that local APIC should be disabled in UP system.  However, some of old
BIOS does not disable local APIC, and virtual wire mode through local
APIC may cause int 15.
1998-05-16 14:38:10 +00:00
John Dyson
424edf1b6a Disable the auto-Write Combining setup for the pmap code. This
worked on a couple of machines of mine, but appears to cause problems
on others.
1998-05-15 07:25:25 +00:00
John Dyson
cfa5644b2b Some temporary fixes to SMP to make it more scheduling and signal friendly.
This is a result of discussions on the mailing lists.  Kudos to those who
have found the issue and created work-arounds.  I have chosen Tor's fix
for now, before we can all work the issue more completely.
Submitted by:		Tor Egge
1998-05-12 18:37:10 +00:00
John Dyson
471176aa5d Fix alot of silly LINT that I left in the code. 1998-05-12 18:28:05 +00:00
Bruce Evans
b322fb5d76 Backed out previous commit. It is invalid to call d_ioctl() on
possibly non-open devices, and we don't want to restrict dumping
to swap devices anwyay.  It is especially invalid to call d_ioctl()
in non-process context for panics.  d_psize() can be called on
non-open devices, at least on non-SLICED ones that support d_dump(),
and setdumpdev() has depended on this for a long time although it
is probably wrong, but even d_psize() can't be called in non-process
context - that's why dumpsys() depends on previously computed values
although these values may be stale.  The historical restriction to
devices with dkpart(dev) == SWAP_PART should go away.
1998-05-12 17:34:02 +00:00
John Dyson
fcf1880fa0 Change some tests from CPU_CLASS686 to CPU_686 as appropriate, and
also correct a serious ommision that would cause process faulures
due to forgetting an invltlb type operatino.  This was just a
transcription problem.
1998-05-11 08:11:57 +00:00
John Dyson
5498a452bc Support better performance with P6 architectures and in SMP
mode.  Unnecessary TLB flushes removed.  More efficient
page zeroing on P6 (modify page only if non-zero.)
1998-05-11 02:13:47 +00:00
John Dyson
f0175db1ee Attempt to set write combining mode for graphics devices. 1998-05-11 01:06:08 +00:00
Julian Elischer
7f2f1b784e Add dump support to the DEVFS/slice code.
now we can actually catch our crashes :-)

Submitted by: Luoqi Chen <luoqi@chen.ml.org> (the man who's everywhere)
1998-05-06 22:14:48 +00:00
Justin T. Gibbs
8fddb21ee2 Implement bus_dmamem_* functions and correct a few nits reported by Peter Wemm. 1998-05-06 01:45:55 +00:00
Eivind Eklund
288078be0f Translate T_PROTFLT to SIGSEGV instead of SIGBUS when running under
Linux emulation.  This make Allegro Common Lisp 4.3 work under
FreeBSD!

Submitted by: Fred Gilham <gilham@csl.sri.com>
Commented on by: bde, dg, msmith, tg
Hoping he got everything right:  eivind
1998-04-28 18:15:08 +00:00
Dag-Erling Smørgrav
bf69d84c0a Cast return values to the appropriate fp_*_t. Note that the man page
incorrectly refers to them as e.g. fp_except rather than fp_except_t.

PR:		misc/6310
Submitted by:	Niall Smart
1998-04-27 14:17:30 +00:00
John Dyson
e8f1b8b02a Add the PAT cpuid feature. 1998-04-26 03:18:38 +00:00
Tor Egge
beede91e58 Mask the interrupt before setting the corresponding bit in ipending if
the interrupt is already active.
Don't use lock prefix for operations on ipending.
Always use lock prefix for operations on iactive.
1998-04-22 22:49:29 +00:00
Matt Jacob
8bafc2452a Add support for the Qlogic ISP SCSI && FC/AL Adapters 1998-04-22 18:18:16 +00:00
Julian Elischer
751e9ca706 Remove an LFS clause, now that it is in the history,
anyone who wants to see what was needed cto revive LFS can see it.
1998-04-20 21:53:07 +00:00
Julian Elischer
c0bab11dfe Make the devfs SLICE option a standard type option.
(hopefully it will go away eventually anyhow)
1998-04-20 03:57:41 +00:00
Julian Elischer
3e425b968d Add changes and code to implement a functional DEVFS.
This code will be turned on with the TWO options
DEVFS and SLICE. (see LINT)
Two labels PRE_DEVFS_SLICE and POST_DEVFS_SLICE will deliniate these changes.

/dev will be automatically mounted by init (thanks phk)
on bootup. See /sys/dev/slice/slice.4 for more info.
All code should act the same without these options enabled.

Mike Smith, Poul Henning Kamp, Soeren, and a few dozen others

This code does not support the following:
bad144 handling.
Persistance. (My head is still hurting from the last time we discussed this)
ATAPI flopies are not handled by the SLICE code yet.

When this code is running, all major numbers are arbitrary and COULD
be dynamically assigned. (this is not done, for POLA only)
Minor numbers for disk slices ARE arbitray and dynamically assigned.
1998-04-19 23:32:49 +00:00
Bruce Evans
212b37ff18 Support compiling with `gcc -pedantic' (don't use hard newlines in
(asm) string constants).
1998-04-19 15:41:06 +00:00
Bruce Evans
1696756396 Support compiling with `gcc -pedantic' (don't use hard newlines in
(asm) string constants or hard long long constants).
1998-04-19 15:39:26 +00:00
Bruce Evans
8c4a6d7452 Support compiling with `gcc-pedantic' (don't use hard newlines in
(asm) string constants or trailing commas in enum declarations).
1998-04-19 15:28:30 +00:00
Bruce Evans
78a8182665 Support compiling with gcc -pedantic (don't use a bogus, null cast). 1998-04-19 15:22:48 +00:00