splice: add O_DIRECT style splicing for block devices
authorJens Axboe <jens.axboe@oracle.com>
Wed, 19 May 2010 18:55:55 +0000 (20:55 +0200)
committerJens Axboe <axboe@nehalem.(none)>
Thu, 20 May 2010 08:43:33 +0000 (10:43 +0200)
commit2f616808378d5188784b61ec9c34d81e68a8c1db
treeca49f4fd4e78e8c027100c8cb26780f6b536cb25
parent307e449e313c72eb4ad3f367f4ba481942187aa6
splice: add O_DIRECT style splicing for block devices

We don't have to use the page cache for splicing to or from block
devices. If we bypass the page cache and go direct-to-bio, we can
make splicing much faster, cleaner, and featureful. For instance,
stealing is easy to support.

This patch adds direct splicing for block devices, if they have
been opened with O_DIRECT.

Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
fs/block_dev.c