HomeFreeBSD

uiomove_object_page(): Avoid instantiating pages in sparse regions on reads.

Description

uiomove_object_page(): Avoid instantiating pages in sparse regions on reads.

Check whether the page being requested is either resident or on swap. If
not, read from the zero_region instead of instantiating an unnecessary page.

This avoids consuming memory for sparse files on tmpfs, when they are read
by applications that do not use SEEK_HOLE/SEEK_DATA (which is most of them).

Reviewed by: kib
MFC after: 1 week
Sponsored by: Spectra Logic

Details

Provenance
willAuthored on
Parents
rS281441: Add support for controlling the trackpoint when Synaptics is enabled.
Branches
Unknown
Tags
Unknown

Event Timeline