summaryrefslogtreecommitdiffstats
path: root/sys/kern
Commit message (Collapse)AuthorAgeFilesLines
...
* aio_qphysio: Eliminate one instance of an out-of-range check that isalc2000-09-261-18/+3
| | | | | | | | performed twice. Eliminate initialization that is already performed by _aio_aqueue. aio_physwakeup: Eliminate redundant synchronization that is already performed by bufdone.
* Make size of dynamic loader argument variable to supporttakawata2000-09-261-14/+22
| | | | | | various executable file format. Reviewed by: peter
* Add a lock structure to vnode structure. Previously it was either allocatedbp2000-09-253-60/+28
| | | | | | | | | | | | | | | | | | | separately (nfs, cd9660 etc) or keept as a first element of structure referenced by v_data pointer(ffs). Such organization leads to known problems with stacked filesystems. From this point vop_no*lock*() functions maintain only interlock lock. vop_std*lock*() functions maintain built-in v_lock structure using lockmgr(). vop_sharedlock() is compatible with vop_stdunlock(), but maintains a shared lock on vnode. If filesystem wishes to export lockmgr compatible lock, it can put an address of this lock to v_vnlock field. This indicates that the upper filesystem can take advantage of it and use single lock structure for entire (or part) of stack of vnodes. This field shouldn't be examined or modified by VFS code except for initialization purposes. Reviewed in general by: mckusick
* Add a KASSERT() to catch instances where the mutex that we pass in tojhb2000-09-241-0/+2
| | | | | | msleep() are recursed. Suggested by: cp
* Move MAXCPU from machine/smp.h to machine/param.h to fix breakageps2000-09-231-2/+2
| | | | | with !SMP kernels. Also, replace NCPUS with MAXCPU since they are redundant.
* Don't #include <sys/proc.h>, since machine/mutex.h does it now.jasone2000-09-231-1/+1
|
* Remove the NCPU, NAPIC, NBUS, NINTR config options. Make NAPIC,ps2000-09-221-36/+54
| | | | | | NBUS, NINTR dynamic and set NCPU to a maximum of 16 under SMP. Reviewed by: peter
* o Introduce vn_extattr_rm(), a helper function in the style ofrwatson2000-09-221-0/+23
| | | | | | | | vn_extattr_get() and vn_extattr_set(). vn_extattr_rm() removes the specified extended attribute from a vnode, authorizing the change as the kernel (NULL cred). Obtained from: TrustedBSD Project
* Style fixes:eivind2000-09-222-104/+214
| | | | | | | | | | * Add lots of comments * Convert a couple of assertions to KASSERT() * Minimal whitespace & misapplied {} fixes * Convert #if 0 to #if COMPILING_LINT for code we presently do not support, but want to keep available. Reviewed by: adrian, markm
* Staticize addalias()eivind2000-09-222-2/+4
|
* Create an event (idle_event) which is invoked every time around themsmith2000-09-221-0/+7
| | | | | idle loop. Machine-dependant code can elect to eg. take power-saving actions when this event is invoked.
* Make the EVENTHANDLER mechanism MP-safe. Events can now be invokedmsmith2000-09-221-3/+21
| | | | without holding the Giant lock.
* o Change locking rules for VOP_GETACL() to indicate that vnode locksrwatson2000-09-214-4/+13
| | | | | | | | | | must be held when retrieving ACLs from vnodes. This is required for EA-based UFS ACL implementations. o Update vacl_get_acl() so that it does appropriate vnode locking. o Remove static from M_ACL malloc define so that it is accessible for consumers of ACLs other than in kern_acl.c Obtained from: TrustedBSD Project
* comment vfs_export functions, requested by: eivindalfred2000-09-212-2/+24
|
* Remove unneeded #include that was a remnant of an earlier version oftruckman2000-09-211-1/+0
| | | | | | my uidinfo patch. Found by: phk
* o Add additional comment describing vaccess() behavior.rwatson2000-09-202-0/+14
| | | | | Requested by: eivind Reviewed by: eivind, adrian
* Fully initialize msqids[]. This could lead to ENOSPC and other strangepeter2000-09-191-0/+1
| | | | | | | stuff. PR: 21085 Submitted by: Marcin Cieslak <saper@SYSTEM.PL>
* Rename lminor() to dev2unit(). This function gives a linear unit numberphk2000-09-194-7/+14
| | | | | | | | | | | | which hides the 'hole' in the minor bits. Introduce unit2minor() to do the reverse operation. Fix some some make_dev() calls which didn't use UID_* or GID_* macros. Kill the v_hashchain alias macro, it hides the real relationship. Introduce experimental SI_CHEAPCLONE flag set it on cloned bpfs.
* Add new line character to debugging printf's.ps2000-09-181-4/+4
|
* Initialize 'hints_loaded' to 0.mdodd2000-09-171-1/+1
| | | | This allows static hints to work properly.
* Unpessimized CURSIG(). The fast path through CURSIG() was broken inbde2000-09-171-6/+6
| | | | | | | | | | the 128-bit sigset_t changes by moving conditionally (rarely) executed code to the beginning where it is always executed, and since this code now involves 3 128-bit operations, the pessimization was relatively large. This change speeds up lmbench's pipe latency benchmark by 3.5%. Fixed style bugs in CURSIG().
* Uninlined CURSIG() and unpolluted <sys/signalvar.h>. CURSIG() had becomebde2000-09-171-0/+26
| | | | | | | | | very bloated, first with 128-bit sigset_t's, then with locking in the SMP case, then with locking in all cases. The space bloat was probably also time bloat, partly because the fast path through CURSIG() was pessimized by the sigset_t changes. This change speeds up lmbench's pipe-based latency benchmark by 4% on a Celeron. <sys/signalvar.h> had become very polluted to support the bloat.
* Added used include of <sys/mutex.h> (don't depend on pollution inbde2000-09-174-0/+6
| | | | <sys/signalvar.h>).
* Add new flag PDIRUNLOCK to the component.cn_flags which should be set bybp2000-09-172-9/+25
| | | | | | | | | | | | | | | | | | filesystem lookup() routine if it unlocks parent directory. This flag should be carefully tracked by filesystems if they want to work properly with nullfs and other stacked filesystems. VFS takes advantage of this flag to perform symantically correct usage of vrele() instead of vput() if parent directory already unlocked. If filesystem fails to track this flag then previous codepath in VFS left unchanged. Convert UFS code to set PDIRUNLOCK flag if necessary. Other filesystmes will be changed after some period of testing. Reviewed in general by: mckusick, dillon, adrian Obtained from: NetBSD
* Make LINT compile.phk2000-09-161-2/+0
|
* Turn dkcksum() into an __inline function.phk2000-09-161-17/+0
| | | | Change its type to u_int_16_t.
* Remove some commented out cruft.jhb2000-09-151-7/+0
|
* - Add a new process flag P_NOLOAD that marks a process that should bejhb2000-09-151-0/+1
| | | | | ignored during load average calcuations. - Set this flag for the idle processes and the softinterrupt process.
* Idle processes are always runnable, so let them state at SRUN.jhb2000-09-152-3/+1
|
* Release Giant before starting up init.jhb2000-09-151-1/+3
| | | | Submitted by: jake
* Enforce process limit policy in one place to keep proccnt from divergingtruckman2000-09-141-2/+2
| | | | from reality.
* Remove the mtx_t, witness_t, and witness_blessed_t types. Instead, justjhb2000-09-145-182/+185
| | | | | | use struct mtx, struct witness, and struct witness_blessed. Requested by: bde
* Pipes are not writeable while a direct write is in progress. However,jlemon2000-09-141-1/+1
| | | | | | the kqueue filter got the sense of the test reversed, so fix it. Spotted by: Michael Elkins <me@sigpipe.org>
* Add function comments for functions missing themeivind2000-09-142-2/+58
|
* Blow away COMPAT_43 support for mounteivind2000-09-142-42/+0
|
* GC vax-only codeeivind2000-09-141-47/+0
|
* - Remove the inthand2_t type and use the equivalent driver_intr_t type fromjhb2000-09-132-0/+40
| | | | | | | | | | | | | newbus for referencing device interrupt handlers. - Move the 'struct intrec' type which describes interrupt sources into sys/interrupt.h instead of making it just be a x86 structure. - Don't create 'ithd' and 'intrec' typedefs, instead, just use 'struct ithd' and 'struct intrec' - Move the code to translate new-bus interrupt flags into an interrupt thread priority out of the x86 nexus code and into a MI ithread_priority() function in sys/kern/kern_intr.c. - Remove now-uneeded x86-specific headers from sys/dev/ata/ata-all.c and sys/pci/pci_compat.c.
* Fixed hang on booting with -d. mtx_enter() was called on an uninitializedbde2000-09-131-4/+2
| | | | | lock. The quick fix in trap.c was not quite the version tested and had no effect; back it out.
* Unlock current directory when calling VFS_ROOT() because underlyingbp2000-09-131-3/+10
| | | | | | | filesystem may hold the lock. Otherwise unavoidable deadlock will occur. This shouldn't have any side effects as long as we hold vfs lock. Obtained from: NetBSD
* Clean up process accounting some more. Unfortunately, it is still notjhb2000-09-122-32/+26
| | | | | quite right on i386 as the CPU who runs statclock() doesn't have a valid clockframe to calculate statistics with.
* Quick fix for hang on booting with -d. mtx_enter() was called beforebde2000-09-121-2/+4
| | | | | | curproc was initialized. curproc == NULL was interpreted as matching the process holding Giant... Just skip mtx_enter() and mtx_exit() in trap() if (curproc == NULL && cold) (&& cold for safety).
* Add three new VOPs: VOP_CREATEVOBJECT, VOP_DESTROYVOBJECT and VOP_GETVOBJECT.bp2000-09-1211-166/+189
| | | | | | | They will be used by nullfs and other stacked filesystems to support full cache coherency. Reviewed in general by: mckusick, dillon
* Fix some printf format string warnings due to sizeof(int) != sizeof(long) onjhb2000-09-112-12/+12
| | | | the alpha.
* revent multiple make_dev() calls on the same dev_t and similar bogosities.phk2000-09-111-0/+16
| | | | | | A couple of new warnings may be emitted during boot if drivers DTWT. Tested by: George Cox <gjvc@gjvc.com>
* When doing statistics for statclock on other CPU's, use the other CPUs'jhb2000-09-111-3/+3
| | | | | | idleproc pointers instead of our own for comparisons. Submitted by: tegge
* aio processes need to have the Giant mutex before doing work.jhb2000-09-111-0/+1
| | | | Submitted by: tegge
* Add malloc_mtx to protect malloc and friends, so that they're thread-safe.jasone2000-09-111-1/+30
| | | | Reviewed by: peter
* Rename tsleep to msleep and add a mutex argument, which isjake2000-09-111-4/+19
| | | | | | | | | | | | | | | | released before sleeping and re-acquired before msleep returns. A compatibility cpp macro has been provided for tsleep to avoid changing all occurences of it in the kernel. Remove an assertion that the Giant mutex be held before calling tsleep or asleep. This is intended to serve the same purpose as condition variables, but does not preclude their addition in the future. Approved by: jasone Obtained from: BSD/OS
* Allow interrupt threads to run during shutdown. This should fix thejasone2000-09-101-2/+15
| | | | | | "dirty buffers during shutdown" problem introduced by the SMPng commit. Submitted by: tegge, cg
* Move the include of <sys/systm.h> so that KTR gets a declaration fordfr2000-09-103-3/+3
| | | | snprintf().
OpenPOWER on IntegriCloud