summaryrefslogtreecommitdiff
path: root/sys/kern/kern_exec.c
Commit message (Collapse)AuthorAgeFilesLines
* Copy releng/7.2 to release/7.2.0 for FreeBSD 7.2-RELEASE.release/7.2.0_cvsKen Smith2009-05-011-1/+1
| | | | | | Approved by: re (implicit) This commit was manufactured to restore the state of the 7.2-RELEASE image.
* MFC: Add support for "superpages" on amd64 and i386. This includes adding theJohn Baldwin2009-02-261-0/+7
| | | | | | | | | | | superpage reservation system to the machine-independent VM system as well as changes to the pmap code for amd64 and i386 to support superpages. Reviewed by: alc Tested by: ps Notes: svn path=/stable/7/; revision=189075
* MFC 184700:Craig Rodrigues2009-01-061-4/+3
| | | | | | | | | | Add DTrace probes for process execution. This covers cases tested by the DTrace test suite. Approved by: jb Notes: svn path=/stable/7/; revision=186840
* MFC SVN rev 181647Christian S.J. Peron2008-10-281-1/+5
| | | | | | | | | | | | | - Reduce the scope of the vnode lock such that it does not cover the various copyouts associated with initializing the process's argv/env data in userspace. It is possible that these copyout operations can fault under memory pressure, possibly resulting in dead locks. Approved by: re@ (kib) Notes: svn path=/stable/7/; revision=184417
* MFCJohn Birrell2008-08-271-0/+31
| | | | | | | | | | DTrace support. Note that this defaults the 'make buildkernel' to build with CTF data so that the release kernel and modules are DTrace-able. Notes: svn path=/stable/7/; revision=182231
* MFC r180799:Konstantin Belousov2008-08-011-4/+2
| | | | | | | | | Call pargs_drop() unconditionally in do_execve(), the function correctly handles the NULL argument. Make pargs_free() static. Notes: svn path=/stable/7/; revision=181120
* MFC r180570:Konstantin Belousov2008-07-311-0/+9
| | | | | | | | | | Pair the VOP_OPEN call from do_execve() with the reciprocal VOP_CLOSE. Note: the change needed small adaptation to RELENG_7 because fexecve(2) is not merged into the branch. Notes: svn path=/stable/7/; revision=181055
* MFC fix for the panic("vm_thread_new: kstack allocation failed") andKonstantin Belousov2008-01-181-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | silent NULL pointer dereference in the i386 and sparc64 pmap_pinit() when the kmem_alloc_nofault() failed to allocate address space. Both functions now return error instead of panicing or dereferencing NULL. The reason for MFCing this so late in release cycle is, according to marius@, because > it fixes the crashing (though no panic) of the test suite > of the graphic/OpenEXR port on sparc64. This test suite is run > (and required to succeed) during the package build and that's > why portmgr@ bitch about at it as OpenEXR is a dependency of KDE > which in turn is supposed to end up on the release CD images. Revisions MFCed: 1.677 of src/sys/amd64/amd64/machdep.c 1.592 of src/sys/amd64/amd64/pmap.c 1.88 of src/sys/arm/arm/pmap.c 1.27 of src/sys/arm/at91/kb920x_machdep.c 1.22 of src/sys/arm/sa11x0/assabet_machdep.c 1.8 of src/sys/arm/xscale/i80321/ep80219_machdep.c 1.29 of src/sys/arm/xscale/i80321/iq31244_machdep.c 1.3 of src/sys/arm/xscale/i8134x/crb_machdep.c 1.6 of src/sys/arm/xscale/ixp425/avila_machdep.c 1.41 of src/sys/compat/pecoff/imgact_pecoff.c 1.26 of src/sys/compat/svr4/imgact_svr4.c 1.660 of src/sys/i386/i386/machdep.c 1.596 of src/sys/i386/i386/pmap.c 1.68 of src/sys/i386/ibcs2/imgact_coff.c 1.56 of src/sys/i386/linux/imgact_linux.c 1.226 of src/sys/ia64/ia64/machdep.c 1.192 of src/sys/ia64/ia64/pmap.c 1.102 of src/sys/kern/imgact_aout.c 1.179 of src/sys/kern/imgact_elf.c 1.56 of src/sys/kern/imgact_gzip.c 1.310 of src/sys/kern/kern_exec.c 1.287 of src/sys/kern/kern_fork.c 1.236 of src/sys/kern/kern_kse.c 1.253 of src/sys/kern/kern_proc.c 1.352 of src/sys/kern/kern_sig.c 1.63 of src/sys/kern/kern_thr.c 1.257 of src/sys/kern/kern_thread.c 1.397 of src/sys/pc98/pc98/machdep.c 1.104 of src/sys/powerpc/powerpc/machdep.c 1.10 of src/sys/powerpc/powerpc/pmap_dispatch.c 1.139 of src/sys/sparc64/sparc64/machdep.c 1.167 of src/sys/sparc64/sparc64/pmap.c 1.16 of src/sys/sun4v/sun4v/machdep.c 1.40 of src/sys/sun4v/sun4v/pmap.c 1.493 of src/sys/sys/proc.h 1.78 of src/sys/sys/signalvar.h 1.80 of src/sys/vm/pmap.h 1.79 of src/sys/vm/vm_extern.h 1.226 of src/sys/vm/vm_glue.c 1.390 of src/sys/vm/vm_map.c Requested by: marius Tested by: Peter Holm, marius (make universe and sparc64 runs) Approved by: re (kensmith) Notes: svn path=/stable/7/; revision=175435
* MFCKonstantin Belousov2007-12-061-0/+1
| | | | | | | | | | | | | | | | | | rev 1.182 of src/sys/kern/imgact_elf.c rev 1.288 of src/sys/kern/init_main.c rev 1.312 of src/sys/kern/kern_exec.c rev 1.85 of src/sys/kern/kern_mib.c rev 1.496 of src/sys/sys/proc.h rev 1.262 of src/sys/sys/systm.h Implement fetching of the __FreeBSD_version from the ELF ABI-tag note. The value is read into the p_osrel member of the struct proc. p_osrel is set to 0 for the binaries without the note. Approved by: re (kensmith) Notes: svn path=/stable/7/; revision=174363
* Change the management of cached pages (PQ_CACHE) in two fundamentalAlan Cox2007-09-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ways: (1) Cached pages are no longer kept in the object's resident page splay tree and memq. Instead, they are kept in a separate per-object splay tree of cached pages. However, access to this new per-object splay tree is synchronized by the _free_ page queues lock, not to be confused with the heavily contended page queues lock. Consequently, a cached page can be reclaimed by vm_page_alloc(9) without acquiring the object's lock or the page queues lock. This solves a problem independently reported by tegge@ and Isilon. Specifically, they observed the page daemon consuming a great deal of CPU time because of pages bouncing back and forth between the cache queue (PQ_CACHE) and the inactive queue (PQ_INACTIVE). The source of this problem turned out to be a deadlock avoidance strategy employed when selecting a cached page to reclaim in vm_page_select_cache(). However, the root cause was really that reclaiming a cached page required the acquisition of an object lock while the page queues lock was already held. Thus, this change addresses the problem at its root, by eliminating the need to acquire the object's lock. Moreover, keeping cached pages in the object's primary splay tree and memq was, in effect, optimizing for the uncommon case. Cached pages are reclaimed far, far more often than they are reactivated. Instead, this change makes reclamation cheaper, especially in terms of synchronization overhead, and reactivation more expensive, because reactivated pages will have to be reentered into the object's primary splay tree and memq. (2) Cached pages are now stored alongside free pages in the physical memory allocator's buddy queues, increasing the likelihood that large allocations of contiguous physical memory (i.e., superpages) will succeed. Finally, as a result of this change long-standing restrictions on when and where a cached page can be reclaimed and returned by vm_page_alloc(9) are eliminated. Specifically, calls to vm_page_alloc(9) specifying VM_ALLOC_INTERRUPT can now reclaim and return a formerly cached page. Consequently, a call to malloc(9) specifying M_NOWAIT is less likely to fail. Discussed with: many over the course of the summer, including jeff@, Justin Husted @ Isilon, peter@, tegge@ Tested by: an earlier version by kris@ Approved by: re (kensmith) Notes: svn path=/head/; revision=172317
* Fix a couple of issues with the stack limit for 32-bit processes on 64-bitJohn Baldwin2007-07-121-4/+9
| | | | | | | | | | | | | | | | kernels exposed by the recent fixes to resource limits for 32-bit processes on 64-bit kernels: - Let ABIs expose their maximum stack size via a new pointer in sysentvec and use that in preference to maxssiz during exec() rather than always using maxssiz for all processses. - Apply the ABI's limit fixup to the previous stack size when adjusting RLIMIT_STACK to determine if the existing mapping for the stack needs to be grown or shrunk (as well as how much it should be grown or shrunk). Approved by: re (kensmith) Notes: svn path=/head/; revision=171410
* Conditionally acquire Giant when dropping a reference on the ktrace vnodeJohn Baldwin2007-06-131-1/+6
| | | | | | | | | | | | | during execve() when turning off tracing due to executing a setuid binary as non-root. Previously this could fail to acquire Giant and fail an assertion if the ktrace file was on a non-MPSAFE filesystem and the executable was on an MPSAFE filesystem. MFC after: 3 days Reported by: kris Notes: svn path=/head/; revision=170684
* Eliminate now-unused SUSER_ALLOWJAIL arguments to priv_check_cred(); inRobert Watson2007-06-121-2/+1
| | | | | | | | | | | | | | | | | | some cases, move to priv_check() if it was an operation on a thread and no other flags were present. Eliminate caller-side jail exception checking (also now-unused); jail privilege exception code now goes solely in kern_jail.c. We can't yet eliminate suser() due to some cases in the KAME code where a privilege check is performed and then used in many different deferred paths. Do, however, move those prototypes to priv.h. Reviewed by: csjp Obtained from: TrustedBSD Project Notes: svn path=/head/; revision=170587
* Revert UF_OPENING workaround for CURRENT.Konstantin Belousov2007-05-311-1/+1
| | | | | | | | | | | | Change the VOP_OPEN(), vn_open() vnode operation and d_fdopen() cdev operation argument from being file descriptor index into the pointer to struct file. Proposed and reviewed by: jhb Reviewed by: daichi (unionfs) Approved by: re (kensmith) Notes: svn path=/head/; revision=170152
* Rework the support for ABIs to override resource limits (used by 32-bitJohn Baldwin2007-05-141-9/+0
| | | | | | | | | | | | | | | | | | | | | | processes under 64-bit kernels). Previously, each 32-bit process overwrote its resource limits at exec() time. The problem with this approach is that the new limits affect all child processes of the 32-bit process, including if the child process forks and execs a 64-bit process. To fix this, don't ovewrite the resource limits during exec(). Instead, sv_fixlimits() is now replaced with a different function sv_fixlimit() which asks the ABI to sanitize a single resource limit. We then use this when querying and setting resource limits. Thus, if a 32-bit process sets a limit, then that new limit will be inherited by future children. However, if the 32-bit process doesn't change a limit, then a future 64-bit child will see the "full" 64-bit limit rather than the 32-bit limit. MFC is tentative since it will break the ABI of old linux.ko modules (no other modules are affected). MFC after: 1 week Notes: svn path=/head/; revision=169565
* Update a comment: we usually call exec_vmspace_new with Giant not held,Kris Kennaway2007-03-251-1/+1
| | | | | | | but sometimes it is. Notes: svn path=/head/; revision=167876
* Further system call comment cleanup:Robert Watson2007-03-051-10/+10
| | | | | | | | | | | | | - Remove also "MP SAFE" after prior "MPSAFE" pass. (suggested by bde) - Remove extra blank lines in some cases. - Add extra blank lines in some cases. - Remove no-op comments consisting solely of the function name, the word "syscall", or the system call name. - Add punctuation. - Re-wrap some comments. Notes: svn path=/head/; revision=167232
* Remove 'MPSAFE' annotations from the comments above most system calls: allRobert Watson2007-03-041-8/+0
| | | | | | | | | | | system calls now enter without Giant held, and then in some cases, acquire Giant explicitly. Remove a number of other MPSAFE annotations in the credential code and tweak one or two other adjacent comments. Notes: svn path=/head/; revision=167211
* Sweep kernel replacing suser(9) calls with priv(9) calls, assigningRobert Watson2006-11-061-1/+5
| | | | | | | | | | | | | | | | specific privilege names to a broad range of privileges. These may require some future tweaking. Sponsored by: nCircle Network Security, Inc. Obtained from: TrustedBSD Project Discussed on: arch@ Reviewed (at least in part) by: mlaier, jmg, pjd, bde, ceri, Alex Lyashkov <umka at sevcity dot net>, Skip Ford <skip dot ford at verizon dot net>, Antoine Brodin <antoine dot brodin at laposte dot net> Notes: svn path=/head/; revision=164033
* The page queues lock is no longer required by vm_page_busy() orAlan Cox2006-10-221-3/+1
| | | | | | | vm_page_wakeup(). Reduce or eliminate its use accordingly. Notes: svn path=/head/; revision=163614
* Complete break-out of sys/sys/mac.h into sys/security/mac/mac_framework.hRobert Watson2006-10-221-1/+1
| | | | | | | | | | | | | | | | begun with a repo-copy of mac.h to mac_framework.h. sys/mac.h now contains the userspace and user<->kernel API and definitions, with all in-kernel interfaces moved to mac_framework.h, which is now included across most of the kernel instead. This change is the first step in a larger cleanup and sweep of MAC Framework interfaces in the kernel, and will not be MFC'd. Obtained from: TrustedBSD Project Sponsored by: SPARTA Notes: svn path=/head/; revision=163606
* Replace PG_BUSY with VPO_BUSY. In other words, changes to the page'sAlan Cox2006-10-221-1/+1
| | | | | | | | busy flag, i.e., VPO_BUSY, are now synchronized by the per-vm object lock instead of the global page queues lock. Notes: svn path=/head/; revision=163604
* Audit the argv and env vectors passed in on exec:Wayne Salamon2006-09-011-0/+9
| | | | | | | | | | | | | | | Add the argument auditing functions for argv and env. Add kernel-specific versions of the tokenizer functions for the arg and env represented as a char array. Implement the AUDIT_ARGV and AUDIT_ARGE audit policy commands to enable/disable argv/env auditing. Call the argument auditing from the exec system calls. Obtained from: TrustedBSD Project Approved by: rwatson (mentor) Notes: svn path=/head/; revision=161813
* - Change process_exec function handlers prototype to include structAlexander Leidinger2006-08-151-1/+2
| | | | | | | | | | | | | | | | image_params arg. - Change struct image_params to include struct sysentvec pointer and initialize it. - Change all consumers of process_exit/process_exec eventhandlers to new prototypes (includes splitting up into distinct exec/exit functions). - Add eventhandler to userret. Sponsored by: Google SoC 2006 Submitted by: rdivacky Parts suggested by: jhb (on hackers@) Notes: svn path=/head/; revision=161302
* In execve(), audit the path name being executed. In the future, itRobert Watson2006-05-281-2/+2
| | | | | | | | | would also be good to audit the interpreter pathname, if any. Obtained from: TrustedBSD Project Notes: svn path=/head/; revision=159003
* Temporarily unlock vnode for new image being executed to avoid lock orderTor Egge2006-05-051-0/+6
| | | | | | | | reversals that can lead to deadlocks. Normally vn_close(), namei() or vrele() should not be called while holding vnode locks. Notes: svn path=/head/; revision=158324
* Remove the unused sva and eva arguments from pmap_remove_pages().Peter Wemm2006-04-031-2/+1
| | | | Notes: svn path=/head/; revision=157443
* Fix exec_map resource leaks.Stephan Uphoff2006-03-081-10/+19
| | | | | | | Tested by: kris@ Notes: svn path=/head/; revision=156440
* - Always call exec_free_args() in kern_execve() instead of doing it in allJohn Baldwin2006-02-061-22/+9
| | | | | | | | | the callers if the exec either succeeds or fails early. - Move the code to call exit1() if the exec fails after the vmspace is gone to the bottom of kern_execve() to cut down on some code duplication. Notes: svn path=/head/; revision=155402
* - textvp may have been from a different mountpoint than ndp->ni_vp andJeff Roberson2006-02-021-1/+6
| | | | | | | | | | we may need to acquire giant to vrele it. Found by: mjacob MFC After: 3 days Notes: svn path=/head/; revision=155205
* Remove unneeded calls to pmap_remove_all(). The given page is not mapped.Alan Cox2005-12-111-1/+0
| | | | | | | Reviewed by: tegge Notes: svn path=/head/; revision=153311
* Register itimers_event_hook as a kernel event handler, so I don'tDavid Xu2005-12-091-4/+0
| | | | | | | have to duplicate code to call it in exec() and exit1(). Notes: svn path=/head/; revision=153259
* Reduce the scope of the page queues lock in exec_map_first_page(). The vmAlan Cox2005-12-061-4/+2
| | | | | | | | | object lock is sufficient for reading a page's PG_BUSY and busy flags. MFC after: 1 week Notes: svn path=/head/; revision=153158
* Cleanup some signal interfaces. Now the tdsignal function acceptsDavid Xu2005-11-031-1/+1
| | | | | | | | | | | | both proc pointer and thread pointer, if thread pointer is NULL, tdsignal automatically finds a thread, otherwise it sends signal to given thread. Add utility function psignal_event to send a realtime sigevent to a process according to the delivery requirement specified in struct sigevent. Notes: svn path=/head/; revision=151993
* Calling setrlimit from 32bit apps could potentially increase certainPaul Saab2005-11-021-1/+1
| | | | | | | | | | limits beyond what should be capiable in a 32bit process, so we must fixup the limits. Reviewed by: jhb Notes: svn path=/head/; revision=151980
* Make p_itimers as a pointer, so file sys/proc.h does not need to includeDavid Xu2005-10-231-0/+1
| | | | | | | sys/timers.h. Notes: svn path=/head/; revision=151585
* Implement POSIX timers. Current only CLOCK_REALTIME and CLOCK_MONOTONICDavid Xu2005-10-231-0/+3
| | | | | | | | | | | | | | | clock are supported. I have plan to merge XSI timer ITIMER_REAL and other two CPU timers into the new code, current three slots are available for the XSI timers. The SIGEV_THREAD notification type is not supported yet because our sigevent struct lacks of two member fields: sigev_notify_function sigev_notify_attributes I have found the sigevent is used in AIO, so I won't add the two members unless the AIO code is adjusted. Notes: svn path=/head/; revision=151576
* 1. Change prototype of trapsignal and sendsig to use ksiginfo_t *, mostDavid Xu2005-10-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | changes in MD code are trivial, before this change, trapsignal and sendsig use discrete parameters, now they uses member fields of ksiginfo_t structure. For sendsig, this change allows us to pass POSIX realtime signal value to user code. 2. Remove cpu_thread_siginfo, it is no longer needed because we now always generate ksiginfo_t data and feed it to libpthread. 3. Add p_sigqueue to proc structure to hold shared signals which were blocked by all threads in the proc. 4. Add td_sigqueue to thread structure to hold all signals delivered to thread. 5. i386 and amd64 now return POSIX standard si_code, other arches will be fixed. 6. In this sigqueue implementation, pending signal set is kept as before, an extra siginfo list holds additional siginfo_t data for signals. kernel code uses psignal() still behavior as before, it won't be failed even under memory pressure, only exception is when deleting a signal, we should call sigqueue_delete to remove signal from sigqueue but not SIGDELSET. Current there is no kernel code will deliver a signal with additional data, so kernel should be as stable as before, a ksiginfo can carry more information, for example, allow signal to be delivered but throw away siginfo data if memory is not enough. SIGKILL and SIGSTOP have fast path in sigqueue_add, because they can not be caught or masked. The sigqueue() syscall allows user code to queue a signal to target process, if resource is unavailable, EAGAIN will be returned as specification said. Just before thread exits, signal queue memory will be freed by sigqueue_flush. Current, all signals are allowed to be queued, not only realtime signals. Earlier patch reviewed by: jhb, deischen Tested on: i386, amd64 Notes: svn path=/head/; revision=151316
* Move execve's access time update functionality into a newDiomidis Spinellis2005-10-121-12/+2
| | | | | | | | | | | vfs_mark_atime() function, and use the new function for performing efficient atime updates in mmap(). Reviewed by: bde MFC after: 2 weeks Notes: svn path=/head/; revision=151252
* Add missing word to comment.Don Lewis2005-10-041-1/+1
| | | | Notes: svn path=/head/; revision=150895
* If sufficiently bad things happen during a call to kern_execve(), it isColin Percival2005-10-031-0/+8
| | | | | | | | | | | | | | | | | | | possible for do_execve() to call exit1() rather than returning. As a result, the sequence "allocate memory; call kern_execve; free memory" can end up leaking memory. This commit documents this astonishing behaviour and adds a call to exec_free_args() before the exit1() call in do_execve(). Since all the users of kern_execve() in the tree use exec_free_args() to free the command-line arguments after kern_execve() returns, this should be safe, and it fixes the memory leak which can otherwise occur. Submitted by: Peter Holm MFC after: 3 days Security: Local denial of service Notes: svn path=/head/; revision=150854
* Copy new process argument list in do_execve() before grabbing PROC_LOCKDon Lewis2005-10-011-10/+10
| | | | | | | | | | | | | to avoid touching pageable memory while holding a mutex. Simplify argument list replacement logic. PR: kern/84935 Submitted by: "Antoine Pelisse" apelisse AT gmail.com (in a different form) MFC after: 3 days Notes: svn path=/head/; revision=150780
* MFP4:Joseph Koshy2005-06-301-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - pmcstat(8) gprof output mode fixes: lib/libpmc/pmclog.{c,h}, sys/sys/pmclog.h: + Add a 'is_usermode' field to the PMCLOG_PCSAMPLE event + Add an 'entryaddr' field to the PMCLOG_PROCEXEC event, so that pmcstat(8) can determine where the runtime loader /libexec/ld-elf.so.1 is getting loaded. sys/kern/kern_exec.c: + Use a local struct to group the entry address of the image being exec()'ed and the process credential changed flag to the exec handling hook inside hwpmc(4). usr.sbin/pmcstat/*: + Support "-k kernelpath", "-D sampledir". + Implement the ELF bits of 'gmon.out' profile generation in a new file "pmcstat_log.c". Move all log related functions to this file. + Move local definitions and prototypes to "pmcstat.h" - Other bug fixes: + lib/libpmc/pmclog.c: correctly handle EOF in pmclog_read(). + sys/dev/hwpmc_mod.c: unconditionally log a PROCEXIT event to all attached PMCs when a process exits. + sys/sys/pmc.h: correct a function prototype. + Improve usage checks in pmcstat(8). Approved by: re (blanket hwpmc) Notes: svn path=/head/; revision=147708
* Move HWPMC_HOOKS into its own opt_hwpmc_hooks.h file. It doesn't meritPeter Wemm2005-06-241-0/+1
| | | | | | | | | | being in opt_global.h and forcing a global recompile when only a few files reference it. Approved by: re Notes: svn path=/head/; revision=147565
* MFP4:Joseph Koshy2005-06-091-2/+3
| | | | | | | | | | | | | | | | | | | - Implement sampling modes and logging support in hwpmc(4). - Separate MI and MD parts of hwpmc(4) and allow sharing of PMC implementations across different architectures. Add support for P4 (EMT64) style PMCs to the amd64 code. - New pmcstat(8) options: -E (exit time counts) -W (counts every context switch), -R (print log file). - pmc(3) API changes, improve our ability to keep ABI compatibility in the future. Add more 'alias' names for commonly used events. - bug fixes & documentation. Notes: svn path=/head/; revision=147191
* This patch addresses a standards violation issue. The standards say aKen Smith2005-05-311-1/+13
| | | | | | | | | | | | | | | | | | | | | | | | | file's access time should be updated when it gets executed. A while ago the mechanism used to exec was changed to use a more mmap based mechanism and this behavior was broken as a side-effect of that. A new vnode flag is added that gets set when the file gets executed, and the VOP_SETATTR() vnode operation gets called. The underlying filesystem is expected to handle it based on its own semantics, some filesystems don't support access time at all. Those that do should handle it in a way that does not block, does not generate I/O if possible, etc. In particular vn_start_write() has not been called. The UFS code handles it the same way as it would normally handle the access time if a file was read - the IN_ACCESS flag gets set in the inode but no other action happens at this point. The actual time update will happen later during a sync (which handles all the necessary locking). Got me into this: cperciva Discussed with: a lot with bde, a little with kan Showed patches to: phk, jeffr, standards@, arch@ Minor discussion on: arch@ Notes: svn path=/head/; revision=146829
* - Initialize vfslocked correctly early enough for MAC to compile.Jeff Roberson2005-05-031-5/+4
| | | | | | | | | | | - Fix one place where we explicitly drop Giant! Pointy hat to: me Submitted by: Max Laier Warned by: Tinderbox Notes: svn path=/head/; revision=145833
* - Use namei to acquire Giant for VFS if it is necessary. Drop the explicitJeff Roberson2005-05-031-9/+7
| | | | | | | | | Giant acquisition. - Remove GIANT_REQUIRED in the few remaining cases; the vm and vfs have both been locked. Notes: svn path=/head/; revision=145821
* - Return EACCES if we're trying to exec on a vp with no object.Jeff Roberson2005-05-011-0/+2
| | | | | | | Errno supplied by: cperciva Notes: svn path=/head/; revision=145731
* - Pass the ISOPEN flag to namei so filesystems will know we're about toJeff Roberson2005-04-271-1/+1
| | | | | | | open them or otherwise access the data. Notes: svn path=/head/; revision=145584