History log of /freebsd-10-stable/sys/vm/vm_object.c
Revision Date Author Comments
# 321677 29-Jul-2017 kib

MFC r321371:
Do not allocate struct kinfo_vmobject on stack.


# 307672 20-Oct-2016 kib

MFC r307218:
Fix a race in vm_page_busy_sleep(9).


# 303291 25-Jul-2016 kib

MFC r302567:
In vgonel(), postpone setting BO_DEAD until VOP_RECLAIM() is called,
if vnode is VMIO. For VMIO vnodes, set BO_DEAD in vm_object_terminate().

MFC r302580:
Fix grammar.


# 301436 05-Jun-2016 kib

MFC r300959:
Do not leak the vm object lock when swap reservation failed, in
vm_object_coalesce().


# 301184 02-Jun-2016 kib

MFC r300758:
Prevent parallel object collapses.


# 301183 02-Jun-2016 kib

MFC r300756:
Style.


# 292261 15-Dec-2015 kib

MFC r291576:
Handle invalid pages found during the sleepable collapse scan, do not free
the shadow page swap space. Combine the sleep code.


# 288499 02-Oct-2015 vangyzen

MFC r283924

Provide vnode in memory map info for files on tmpfs

When providing memory map information to userland, populate the vnode pointer
for tmpfs files. Set the memory mapping to appear as a vnode type, to match
FreeBSD 9 behavior.

This fixes the use of tmpfs files with the dtrace pid provider,
procstat -v, procfs, linprocfs, pmc (pmcstat), and ptrace (PT_VM_ENTRY).

Submitted by: Eric Badger <eric@badgerio.us> (initial revision)
Obtained from: Dell Inc.
PR: 198431


# 288453 01-Oct-2015 jhb

MFC 283624,283630:
Export a list of VM objects in the system via a sysctl. The list can be
examined via 'vmstat -o'. It can be used to determine which files are
using physical pages of memory and how much each is using.


# 286145 01-Aug-2015 kib

MFC r285878:
Revert r173708's modifications to vm_object_page_remove().
This fixes inconsistencies encountered by vm_object_unwire() or
by the buffer cache when the file is truncated.


# 284100 06-Jun-2015 jhb

MFC 261811,282660,282706:
Place VM objects on the object list when created and never remove them.

261811:
Fix function name in KASSERT().

282660:
Place VM objects on the object list when created and never remove them.
This is ok since objects come from a NOFREE zone and allows objects to
be locked while traversing the object list without triggering a LOR.

Ensure that objects on the list are marked DEAD while free or stillborn,
and that they have a refcount of zero. This required updating most of
the pagers to explicitly mark an object as dead when deallocating it.
(Only the vnode pager did this previously.)

282706:
Satisfy vm_object uma zone destructor requirements after r282660 when
vnode object creation raced.


# 281029 03-Apr-2015 alc

MFC r279720
Correct a typo in vm_object_backing_scan() that originated in r254141.
Specifically, change a lock acquire into a lock release.


# 278571 11-Feb-2015 kib

MFC r277828:
Update mtime for tmpfs files modified through memory mapping.

MFC r277969:
Update both ctime and mtime for writes to tmpfs files.

MFC r277972:
Remove single-use boolean.

MFC r278151:
Remove duplicated assignment.


# 275726 12-Dec-2014 kib

MFC r275513:
When the last reference on the vnode' vm object is dropped, read the
vp->v_vflag without taking vnode lock and without bypass.


# 270920 01-Sep-2014 kib

Fix a leak of the wired pages when unwiring of the PROT_NONE-mapped
wired region. Rework the handling of unwire to do the it in batch,
both at pmap and object level.

All commits below are by alc.

MFC r268327:
Introduce pmap_unwire().

MFC r268591:
Implement pmap_unwire() for powerpc.

MFC r268776:
Implement pmap_unwire() for arm.

MFC r268806:
pmap_unwire(9) man page.

MFC r269134:
When unwiring a region of an address space, do not assume that the
underlying physical pages are mapped by the pmap. This fixes a leak
of the wired pages on the unwiring of the region mapped with no access
allowed.

MFC r269339:
In the implementation of the new function pmap_unwire(), the call to
MOEA64_PVO_TO_PTE() must be performed before any changes are made to the
PVO. Otherwise, MOEA64_PVO_TO_PTE() will panic.

MFC r269365:
Correct a long-standing problem in moea{,64}_pvo_enter() that was revealed
by the combination of r268591 and r269134: When we attempt to add the
wired attribute to an existing mapping, moea{,64}_pvo_enter() do nothing.
(They only set the wired attribute on newly created mappings.)

MFC r269433:
Handle wiring failures in vm_map_wire() with the new functions
pmap_unwire() and vm_object_unwire().
Retire vm_fault_{un,}wire(), since they are no longer used.

MFC r269438:
Rewrite a loop in vm_map_wire() so that gcc doesn't think that the variable
"rv" is uninitialized.

MFC r269485:
Retire pmap_change_wiring().

Reviewed by: alc


# 269174 27-Jul-2014 kib

MFC r268615:
Add OBJ_TMPFS_NODE flag.

MFC r268616:
Set the OBJ_TMPFS_NODE flag for vm_object of VREG tmpfs node.

MFC r269053:
Correct assertion. tmpfs vm object is always at the bottom of
the shadow chain.


# 263359 19-Mar-2014 kib

MFC r263092:
Do not vdrop() the tmpfs vnode until it is unlocked. The hold
reference might be the last, and then vdrop() would free the vnode.


# 262291 21-Feb-2014 attilio

MFC r261867:
Use the right index to free swapspace after vm_page_rename().


# 258037 12-Nov-2013 kib

MFC r257680:
Do not coalesce if the swap object belongs to tmpfs vnode.

Approved by: re (glebius)


# 288499 02-Oct-2015 vangyzen

MFC r283924

Provide vnode in memory map info for files on tmpfs

When providing memory map information to userland, populate the vnode pointer
for tmpfs files. Set the memory mapping to appear as a vnode type, to match
FreeBSD 9 behavior.

This fixes the use of tmpfs files with the dtrace pid provider,
procstat -v, procfs, linprocfs, pmc (pmcstat), and ptrace (PT_VM_ENTRY).

Submitted by: Eric Badger <eric@badgerio.us> (initial revision)
Obtained from: Dell Inc.
PR: 198431


# 288453 01-Oct-2015 jhb

MFC 283624,283630:
Export a list of VM objects in the system via a sysctl. The list can be
examined via 'vmstat -o'. It can be used to determine which files are
using physical pages of memory and how much each is using.


# 286145 01-Aug-2015 kib

MFC r285878:
Revert r173708's modifications to vm_object_page_remove().
This fixes inconsistencies encountered by vm_object_unwire() or
by the buffer cache when the file is truncated.


# 284100 06-Jun-2015 jhb

MFC 261811,282660,282706:
Place VM objects on the object list when created and never remove them.

261811:
Fix function name in KASSERT().

282660:
Place VM objects on the object list when created and never remove them.
This is ok since objects come from a NOFREE zone and allows objects to
be locked while traversing the object list without triggering a LOR.

Ensure that objects on the list are marked DEAD while free or stillborn,
and that they have a refcount of zero. This required updating most of
the pagers to explicitly mark an object as dead when deallocating it.
(Only the vnode pager did this previously.)

282706:
Satisfy vm_object uma zone destructor requirements after r282660 when
vnode object creation raced.


# 281029 03-Apr-2015 alc

MFC r279720
Correct a typo in vm_object_backing_scan() that originated in r254141.
Specifically, change a lock acquire into a lock release.


# 278571 11-Feb-2015 kib

MFC r277828:
Update mtime for tmpfs files modified through memory mapping.

MFC r277969:
Update both ctime and mtime for writes to tmpfs files.

MFC r277972:
Remove single-use boolean.

MFC r278151:
Remove duplicated assignment.


# 275726 12-Dec-2014 kib

MFC r275513:
When the last reference on the vnode' vm object is dropped, read the
vp->v_vflag without taking vnode lock and without bypass.


# 270920 01-Sep-2014 kib

Fix a leak of the wired pages when unwiring of the PROT_NONE-mapped
wired region. Rework the handling of unwire to do the it in batch,
both at pmap and object level.

All commits below are by alc.

MFC r268327:
Introduce pmap_unwire().

MFC r268591:
Implement pmap_unwire() for powerpc.

MFC r268776:
Implement pmap_unwire() for arm.

MFC r268806:
pmap_unwire(9) man page.

MFC r269134:
When unwiring a region of an address space, do not assume that the
underlying physical pages are mapped by the pmap. This fixes a leak
of the wired pages on the unwiring of the region mapped with no access
allowed.

MFC r269339:
In the implementation of the new function pmap_unwire(), the call to
MOEA64_PVO_TO_PTE() must be performed before any changes are made to the
PVO. Otherwise, MOEA64_PVO_TO_PTE() will panic.

MFC r269365:
Correct a long-standing problem in moea{,64}_pvo_enter() that was revealed
by the combination of r268591 and r269134: When we attempt to add the
wired attribute to an existing mapping, moea{,64}_pvo_enter() do nothing.
(They only set the wired attribute on newly created mappings.)

MFC r269433:
Handle wiring failures in vm_map_wire() with the new functions
pmap_unwire() and vm_object_unwire().
Retire vm_fault_{un,}wire(), since they are no longer used.

MFC r269438:
Rewrite a loop in vm_map_wire() so that gcc doesn't think that the variable
"rv" is uninitialized.

MFC r269485:
Retire pmap_change_wiring().

Reviewed by: alc


# 269174 27-Jul-2014 kib

MFC r268615:
Add OBJ_TMPFS_NODE flag.

MFC r268616:
Set the OBJ_TMPFS_NODE flag for vm_object of VREG tmpfs node.

MFC r269053:
Correct assertion. tmpfs vm object is always at the bottom of
the shadow chain.


# 263359 19-Mar-2014 kib

MFC r263092:
Do not vdrop() the tmpfs vnode until it is unlocked. The hold
reference might be the last, and then vdrop() would free the vnode.


# 262291 21-Feb-2014 attilio

MFC r261867:
Use the right index to free swapspace after vm_page_rename().


# 258037 12-Nov-2013 kib

MFC r257680:
Do not coalesce if the swap object belongs to tmpfs vnode.

Approved by: re (glebius)