Commit Graph

23242 Commits

Author SHA1 Message Date
Marcel Moolenaar
a333d53268 Add support for COMPAT_LINUX and DEBUG_LINUX. Make the OSF1
files dependent on 'compat_linux' as well as the Linuxulator
depends on the osfulator.
2000-12-05 09:10:50 +00:00
Marcel Moolenaar
e5f2ced1ee Minor cleanups:
o  remove unused prototypes,
o  remove unused extern declarations,
o  move prototypes up.
2000-12-05 09:06:41 +00:00
Marcel Moolenaar
ec79304f0f Make osendsig global. It's used by the Linuxulator. 2000-12-05 09:04:25 +00:00
Takanori Watanabe
d55a2811f5 Update Makefile to follow acpica-1115 import. 2000-12-05 08:47:41 +00:00
Matt Jacob
4081cc88c9 Only call ISP_UNLOCK/ISP_LOCK if isp->isp_osinfo.intsok in USEC_SLEEP.
Add a test against isp->isp_osinfo.islocked prior to trying to see
whether --isp->isp_osinfo.islocked is zero to cause us to unlock
(non-SMPLOCK case).
2000-12-05 07:41:53 +00:00
Matt Jacob
bfbab17021 Replace some more printfs with isp_prt's. Use isp_prt/ISP_LOGDEBUG0
for rate setting/getting printouts.
2000-12-05 07:39:54 +00:00
Matt Jacob
f7dddf8a54 Remove more printfs and use either isp_prt or device_printf. Remember
to set ISP_LOGINFO if bootverbose is set.
2000-12-05 07:38:41 +00:00
Marcel Moolenaar
7ec9743293 Remove call to bzero after MALLOC and instead add M_ZERO
to MALLOC.
2000-12-05 06:44:22 +00:00
Warner Losh
05f80a57a7 Start to make code more generic so it can be used by the pccbb driver
in the future:
o Remove pcic_softc from pcic_handle and replace it with a void *
o Reduce dependence on accessing softc via a pcic_handle
Minor cleanups:
o Define a macro to count the size of an array and use it.
o Minor whitespace alignment
o make no slots found a printf not a panic.
2000-12-05 04:49:26 +00:00
Jake Burkholder
1eb44f0270 Remove the last of the MD netisr code. It is now all MI. Remove
spending, which was unused now that all software interrupts have
their own thread.  Make the legacy schednetisr use an atomic op
for setting bits in the netisr mask.

Reviewed by:	jhb
2000-12-05 00:36:00 +00:00
Mike Smith
4d3329891c ACPI HID's aren't limited to 7 characters. Don't check the length of the
HID passed in as an argument at all; callers are typically going to be
sending us static strings anyway.

Submitted by:	Munehiro Matsuda <haro@tk.kubota.co.jp>
2000-12-05 00:19:10 +00:00
Bill Paul
031fc810ab Initialize/grab the mutex earlier in the attach phase, so that
bailing out to the fail: label where we release/destroy the mutex
will work without exploding.
2000-12-04 22:46:50 +00:00
Peter Wemm
5ee171d264 Cleanup some leftover lint from the old interrupt system.
Also, while here, run up to 32 interrupt sources on APIC systems.
Normalize INTREN/INTRDIS so they are the same on both UP and SMP systems
rather than sometimes a macro, and sometimes a function.

Reviewed by:  jhb, jakeb
2000-12-04 21:15:14 +00:00
Joerg Wunsch
50088f2089 Turn off the load_eject bit in cdstartunit(). It causes an `Invalid
field in CDB' error when attempting to start a caddy-type CD drive,
since those drives apparently in general refuse to load a medium.  Since
we never advertised the feature to load the medium upon calling
cdstartunit() (i. e. upon receipt of a CDIOCSTART ioctl command), nobody
should have relied on it.  Besides, nobody noticed so far at all that
this command is failing for caddy-type drives...  Only few applications
seem to use it at all (among them is workman, which made me notice it).

Reviewed by:	ken
2000-12-04 20:16:06 +00:00
Matt Jacob
b741a1c581 Fix for vanilla PC164 systems to use a slightly different PALcode magic
tweak to enable/disable interrupt sources. Seems to work. It is unclear
how many of the PC164 models actually might needs this, and whether or
not there are other hidden issues.

Obtained from:Bernd Walter <ticso@cicely8.cicely.de>
2000-12-04 17:21:46 +00:00
Jake Burkholder
f315dbdbd4 (1) Allow a stray lock prefix to be compiled out with the
MPLOCKED macro
(2)	Use decimal 12 rather than hex 0xc in an addl
(3)	Implement MTX_ENTER for the I386_CPU case
(4)	Use semi-colons between instructions to allow MTX_ENTER
	and MTX_ENTER_WITH_RECURSION to be assembled
(5)	Use incl instead of incw to increment the recusion count
(6)	10 is not a valid label, use 7, 8 and 9 rather than 8, 9 and 10
(7)	Sort numeric labels

Submitted by:	bde (2, 4, and 5)
2000-12-04 12:38:03 +00:00
Jake Burkholder
8dd431fcf7 Whitespace. Fix indentation, align comments. 2000-12-04 10:23:29 +00:00
Jake Burkholder
f6a6e37a2c Whitespace. Fix an overly long line. 2000-12-04 09:52:39 +00:00
Jake Burkholder
85b039fe64 Remove if defined(tahoe) cobwebs. 2000-12-04 09:49:34 +00:00
Alfred Perlstein
7a8671e9b7 remove struct mount from useland visibility 2000-12-04 09:21:05 +00:00
Matt Jacob
bd1c746647 Comment out debug printfs about enable/disable ints.
Current now appears to work at least fitfully on one Rawhide.
2000-12-04 01:33:44 +00:00
David Malone
ea8b5a9ae9 More M_ZERO patches.
Submitted by:	josh@zipperup.org
Submitted by:	Robert Drehmel <robd@gmx.net>
Approved by:	mjacob
2000-12-03 20:46:54 +00:00
Alexander Langer
b2ca55728b Add the NS DP83815 to the list of supported chips by the sis driver.
Inspired by:	Oliver Fromme
2000-12-03 18:43:41 +00:00
Nick Sayer
305501d329 We now have the ability to assign the correct IRQ when PNP-OS is turned
on. So stop failing the attach if the IRQ is unassigned. With this
patch, I can now boot with PNP-OS YES in my BIOS no differently than
PNP-OS NO (which is a good thing since Windows hangs with PNP-OS NO).

Obtained from:	msmith
2000-12-03 17:07:19 +00:00
Hellmuth Michaelis
1fa9b0422d Bugfix: enable interrupt sharing for ELSA Microlink ISDN PCI 2000-12-03 16:20:33 +00:00
David Malone
087e2cb75a Use M_ZERO.
Submitted by:	josh@zipperup.org
Submitted by:	Robert Drehmel <robd@gmx.net>
Approved by:	mark_salyzyn@adaptec.com
2000-12-03 13:21:55 +00:00
David Malone
0863e00340 Check return value of malloc correctly and use M_ZERO. 2000-12-03 13:18:49 +00:00
Mike Smith
b09d2ca319 - add support for crashdumps (courtesy of ps and Y!)
- standardise error reporting for commands
 - simplify the driver-to-controller bio transfer
 - add bio in/out accounting
 - correctly preserve the command ID in twe_ioctl (thanks to joel@3ware)
2000-12-03 02:11:35 +00:00
John Baldwin
ab8b98a151 Fix up a whitespace glitch in PHOLD() and fix it to use do { ... } while(0)
instead of { ... }.
2000-12-03 02:09:47 +00:00
Marcel Moolenaar
4c9671ee0f Include machine/cpu.h for cpu_getstack().
Spotted by: jake
2000-12-03 01:56:15 +00:00
David Greenman
8f9a5273a3 Changed second argument in a call to sf_buf_free() to be NULL instead of
PAGE_SIZE to match the prototype better. The argument is ignored, so this
is just to silence the compile-time warning.

Pointed out by:	jhb
2000-12-03 01:35:46 +00:00
Marcel Moolenaar
b4c6727a3a Don't auto-generate the syscalls. 2000-12-03 01:30:31 +00:00
Marcel Moolenaar
a7e693e3a0 Don't auto-generate syscalls. 2000-12-03 01:28:51 +00:00
John Baldwin
4971f62a86 - Add a mutex to the proc structure p_mtx that will be used to lock accesses
to each individual proc.
- Initialize the lock during fork1(), and destroy it in wait1().
2000-12-03 01:22:34 +00:00
Jake Burkholder
1306962a43 Change cpu_switch to explicitly popl the callers program counter and
pushl that of the new process, rather than doing a movl (%esp) and
assuming that the stack has been setup right.  This make the initial
stack setup slightly more sane, and will make it easier to stick
an interrupted process onto the run queue without its knowing.
2000-12-03 01:09:59 +00:00
Marcel Moolenaar
fa581ad823 Fix dependency for auto-generated files. This commit is
for archiving purposes only; auto-generation is going to
be reverted.

requested by: obrien
submitted: gallatin
2000-12-02 23:47:41 +00:00
Andrew Gallatin
19f085228f Correct int/long type mismatch in the proper place this time. freevnodes
and numvnodes are longs in the kernel.  They should remain longs in systat,
what really needs to change is that they should be using SYSCTL_LONG rather
than SYSCTL_INT.   I also changed wantfreevnodes to SYSCTL_LONG because I
happened to notice it.

I wish there was a way to find all of these automatically..

Pointed out by: bde
2000-12-02 20:08:33 +00:00
Mark Murray
84d4f509f0 Major speedup to /dev/random and the kernel thread that reseeds it.
There is no more TAILQ fifo to harvest the entropy; instead, there
is a circular buffer of constant size (changeable by macro) that
pretty dramatically improves the speed and fixes potential slowdowns-
by-locking.

Also gone are a slew of malloc(9) and free(9) calls; all harvesting
buffers are static.

All-in-all, this is a good performance improvement.

Thanks-to:	msmith for the circular buffer concept-code.
2000-12-02 18:40:16 +00:00
Matt Jacob
e5f2f488c5 Add USEC_SLEEP macro support. Change the location at which we define
ISP_LOCK/ISP_UNLOCK macros.
2000-12-02 18:33:29 +00:00
Mark Murray
5f7f65f124 Default the /dev/random loadable module to blocking-on-bootup,
but leave a commented-out macro to change this.
2000-12-02 18:29:18 +00:00
Matt Jacob
81babfd043 Make the Not RESPONSE in RESPONSE QUEUE message have a bit more info
(specifically, how many entries we've looked at so far). Maintain
interrupt instrumentation. Use USEC_SLEEP instead of USEC_DELAY in
a number of places (this allows us to drop locks and sleep instead
of spin). Track changes to configuration options for topology preference.
Fix botched order of printout for Channel, Target, Lun.
2000-12-02 18:08:35 +00:00
Matt Jacob
67afe757a2 Add interrupt instrumentation. Change ISP_CFG_NPORT config option to
a set of options that allows specific loop, loop-only, nport, nport-only
topology settings. Define a required macro for all platforms (USEC_SLEEP).
2000-12-02 18:06:03 +00:00
Mark Murray
4a3a2f0704 Namespace cleanup. Remove some #includes in favour of an explicit
declaration.

Asked for by:	bde
2000-12-02 17:59:41 +00:00
Mark Murray
4cb1e53914 Recouple arc4random(9) to the entropy device. This works whether the
entropy device is loaded or not.

If the entropy device is NOT loaded, the the quality of perturbations
supplied by this will suffer.
2000-12-02 16:23:54 +00:00
Julian Elischer
e8a49db233 Add splhigh()s to protect against a race condition
that shows up when running with ethernet bridging
at high speed.

Submitted by: Chris Csanady <ccsanady@iastate.edu>
(and extended by me)
2000-12-02 13:27:58 +00:00
Bruce Evans
03b67a395f Backed out previous commit. Don't depend on namespace pollution in
<sys/buf.h>.
2000-12-02 12:03:58 +00:00
John Baldwin
c5a44a6af6 Protect p_stat with sched_lock. 2000-12-02 06:09:44 +00:00
Jake Burkholder
a4bd171dbf Regen. 2000-12-02 05:45:32 +00:00
Jake Burkholder
0ad84a819c Forgot this file in previous commit to remove file kern_threads.c 2000-12-02 05:42:30 +00:00
Jake Burkholder
86360fee54 Remove thr_sleep and thr_wakeup. Remove fields p_nthread and p_wakeup
from struct proc, which are now unused (p_nthread already was).
Remove process flag P_KTHREADP which was untested and only set
in vfs_aio.c (it should use kthread_create).  Move the yield
system call to kern_synch.c as kern_threads.c has been removed
completely.

moral support from:	alfred, jhb
2000-12-02 05:41:30 +00:00