]> git.karo-electronics.de Git - karo-tx-linux.git/commit
fadvise: only initiate writeback for specified range with FADV_DONTNEED
authorShawn Bohrer <sbohrer@rgmadvisors.com>
Thu, 8 Dec 2011 04:41:47 +0000 (15:41 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 14 Dec 2011 05:48:06 +0000 (16:48 +1100)
commit7b9d5c697266c373b0f4b4a0b7e3cafb3d90c901
tree6c478816957778d86c38474d09fc333af48b5c5c
parentda1040160c1262bbbf02eefbd7ed1bf3f9637425
fadvise: only initiate writeback for specified range with FADV_DONTNEED

Previously POSIX_FADV_DONTNEED would start writeback for the entire file
when the bdi was not write congested.  This negatively impacts performance
if the file contians dirty pages outside of the requested range.  This
change uses __filemap_fdatawrite_range() to only initiate writeback for
the requested range.

Signed-off-by: Shawn Bohrer <sbohrer@rgmadvisors.com>
Acked-by: Johannes Weiner <jweiner@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/fadvise.c