summaryrefslogtreecommitdiffstats
path: root/sys/vm
Commit message (Collapse)AuthorAgeFilesLines
* - Complete the vm object locking in vm_pageout_object_deactivate_pages().alc2003-07-071-21/+27
| | | | | | | | | - Change vm_pageout_object_deactivate_pages()'s first parameter from a vm_map_t to a pmap_t. - Change vm_pageout_object_deactivate_pages()'s and vm_pageout_map_deactivate_pages()'s last parameter from a vm_pindex_t to a long. Since the number of pages in an address space doesn't require 64 bits on an i386, vm_pindex_t is overkill.
* Lock a vm object when freeing a page from it.alc2003-07-051-0/+7
|
* Remove unnecessary cast.phk2003-07-041-1/+1
|
* Background: pmap_object_init_pt() premaps the pages of a object inalc2003-07-032-3/+75
| | | | | | | | | | | | | | | | order to avoid the overhead of later page faults. In general, it implements two cases: one for vnode-backed objects and one for device-backed objects. Only the device-backed case is really machine-dependent, belonging in the pmap. This commit moves the vnode-backed case into the (relatively) new function vm_map_pmap_enter(). On amd64 and i386, this commit only amounts to code rearrangement. On alpha and ia64, the new machine independent (MI) implementation of the vnode case is smaller and more efficient than their pmap-based implementations. (The MI implementation takes advantage of the fact that objects in -CURRENT are ordered collections of pages.) On sparc64, pmap_object_init_pt() hadn't (yet) been implemented.
* Fix a few style(9) nits.mux2003-07-021-13/+9
|
* Modify vm_page_alloc() and vm_page_select_cache() to allow the page thatalc2003-07-011-2/+4
| | | | | is returned by vm_page_select_cache() to belong to the object that is already locked by the caller to vm_page_alloc().
* Check the address provided to vm_map_stack() against the vm map's maximum,alc2003-07-011-1/+2
| | | | returning an error if the address is too high.
* Introduce vm_map_pmap_enter(). Presently, this is a stub calling the MDalc2003-06-292-7/+21
| | | | pmap_object_init_pt().
* - Export pmap_enter_quick() to the MI VM. This will permit thealc2003-06-291-1/+3
| | | | | | | | | | | implementation of a largely MI pmap_object_init_pt() for vnode-backed objects. pmap_enter_quick() is implemented via pmap_enter() on sparc64 and powerpc. - Correct a mismatch between pmap_object_init_pt()'s prototype and its various implementations. (I plan to keep pmap_object_init_pt() as the MD hook for device-backed objects on i386 and amd64.) - Correct an error in ia64's pmap_enter_quick() and adjust its interface to match the other versions. Discussed with: marcel
* Add vm object locking to vm_pageout_map_deactivate_pages().alc2003-06-291-9/+18
|
* Remove GIANT_REQUIRED from kmem_malloc().alc2003-06-281-3/+0
|
* - Add vm object locking to vm_pageout_clean().alc2003-06-281-5/+7
|
* - Use an int rather than a vm_pindex_t to represent the desired pagealc2003-06-281-24/+6
| | | | | | color in vm_page_alloc(). (This also has small performance benefits.) - Eliminate vm_page_select_free(); vm_page_alloc() might as well call vm_pageq_find() directly.
* Simple read-modify-write operations on a vm object's flags, ref_count, andalc2003-06-271-4/+0
| | | | | shadow_count can now rely on its mutex for synchronization. Remove one use of Giant from vm_map_insert().
* vm_page_select_cache() enforces a number of conditions on the returnedalc2003-06-261-1/+6
| | | | page. Add the ability to lock the containing object to those conditions.
* Modify vm_pageq_requeue() to handle a PQ_NONE page without dereferencingalc2003-06-261-14/+5
| | | | a NULL pointer; remove some now unused code.
* Move the pcpu lock out of the uma_cache and instead have a single setbmilekic2003-06-252-50/+25
| | | | | | | of pcpu locks. This makes uma_zone somewhat smaller (by (LOCKNAME_LEN * sizeof(char) + sizeof(struct mtx) * maxcpu) bytes, to be exact). No Objections from jeff.
* Make sure that the zone destructor doesn't get called twice inbmilekic2003-06-251-2/+6
| | | | certain free paths.
* Remove a GIANT_REQUIRED on the kernel object that we no longer need.alc2003-06-251-2/+0
|
* Maintain the lock on a vm object when calling vm_page_grab().alc2003-06-251-3/+0
|
* Assert that the vm object is locked on entry to dev_pager_getpages().alc2003-06-241-0/+1
|
* Assert that the vm object is locked on entry to vm_pager_get_pages().alc2003-06-231-5/+1
|
* Maintain a lock on the vm object of interest throughout vm_fault(),alc2003-06-224-12/+15
| | | | | | releasing the lock only if we are about to sleep (e.g., vm_pager_get_pages() or vm_pager_has_pages()). If we sleep, we have marked the vm object with the paging-in-progress flag.
* Add a f_vnode field to struct file.phk2003-06-221-1/+1
| | | | | | | | | | | | Several of the subtypes have an associated vnode which is used for stuff like the f*() functions. By giving the vnode a speparate field, a number of checks for the specific subtype can be replaced simply with a check for f_vnode != NULL, and we can later free f_data up to subtype specific use. At this point in time, f_data still points to the vnode, so any code I might have overlooked will still work.
* As vm_fault() descends the chain of backing objects, set paging-in-alc2003-06-221-8/+8
| | | | progress on the next object before clearing it on the current object.
* Complete the vm object locking in vm_object_backing_scan(); specifically,alc2003-06-221-5/+12
| | | | | deal with the case where we need to sleep on a busy page with two vm object locks held.
* Make some style and white-space changes to the copy-on-write path throughalc2003-06-221-10/+5
| | | | vm_fault(); remove a pointless assignment statement from that path.
* Use a do {...} while (0); and a couple of breaks to reduce the levelphk2003-06-211-78/+80
| | | | of indentation a bit.
* Lock one of the vm objects involved in an optimized copy-on-write fault.alc2003-06-211-2/+5
|
* - Increase the scope of the vm object lock in vm_object_collapse().alc2003-06-211-3/+4
| | | | | - Assert that the vm object and its backing vm object are both locked in vm_object_qcollapse().
* Make swap_pager_haspages() static; remove unused function prototypes.alc2003-06-202-5/+3
|
* Initialize b_saveaddr when we hand out pbufsphk2003-06-201-2/+3
|
* The so-called "optimized copy-on-write fault" case should not requirealc2003-06-201-9/+2
| | | | | | | the vm map lock. What's really needed is vm object locking, which is (for the moment) provided Giant. Reviewed by: tegge
* Assert that the vm object is locked in vm_page_try_to_free().alc2003-06-191-0/+2
|
* Fix a vm object reference leak in the page-based copy-on-write mechanismalc2003-06-191-1/+1
| | | | | | used by the zero-copy sockets implementation. Reviewed by: gallatin
* Lock the vm object when freeing a vm page.alc2003-06-181-0/+14
|
* This file was ignored by CVS in my last commit for some reason:phk2003-06-161-1/+0
| | | | | Remove pointless initialization of b_spc field, which now no longer exists.
* Add the same KASSERT to all VOP_STRATEGY and VOP_SPECSTRATEGY implementationsphk2003-06-151-0/+2
| | | | to check that the buffer points to the correct vnode.
* Remove an unnecessary forward declaration.alc2003-06-151-2/+1
|
* Use #ifdef __alpha__, not __alpha.alc2003-06-151-2/+2
|
* Migrate the thread stack management functions from the machine-dependentalc2003-06-143-9/+177
| | | | | | | | | | | | | | | | to the machine-independent parts of the VM. At the same time, this introduces vm object locking for the non-i386 platforms. Two details: 1. KSTACK_GUARD has been removed in favor of KSTACK_GUARD_PAGES. The different machine-dependent implementations used various combinations of KSTACK_GUARD and KSTACK_GUARD_PAGES. To disable guard page, set KSTACK_GUARD_PAGES to 0. 2. Remove the (unnecessary) clearing of PG_ZERO in vm_thread_new. In 5.x, (but not 4.x,) PG_ZERO can only be set if VM_ALLOC_ZERO is passed to vm_page_alloc() or vm_page_grab().
* Move the *_new_altkstack() and *_dispose_altkstack() functions out of thealc2003-06-143-2/+33
| | | | | various pmap implementations into the machine-independent vm. They were all identical.
* Extend the scope of the vm object lock in swp_pager_async_iodone() to coveralc2003-06-131-3/+4
| | | | a vm_page_free().
* Add vm object locking to various pagers' "get pages" methods, i386 stackalc2003-06-135-7/+17
| | | | management functions, and a u area management function.
* Use __FBSDID().obrien2003-06-1123-41/+69
|
* GC unused cpu_wait() functionpeter2003-06-111-1/+0
|
* - Finish vm object and page locking in vnode_pager_setsize().alc2003-06-101-26/+21
| | | | | - Make some small style changes to vnode_pager_setsize(); most notably, move two comments to a more logical place.
* Revert last commit, I have no idea what happened.phk2003-06-091-1/+1
|
* A white-space nit I noticed.phk2003-06-091-1/+1
|
* Hold the vm object's lock when performing vm_page_lookup().alc2003-06-091-0/+2
|
OpenPOWER on IntegriCloud