]> www.infradead.org Git - users/jedix/linux-maple.git/commit
block: loop: prepare for supporing direct IO
authorMing Lei <ming.lei@canonical.com>
Sun, 28 Jun 2015 06:06:32 +0000 (23:06 -0700)
committerSantosh Shilimkar <santosh.shilimkar@oracle.com>
Wed, 29 Jul 2015 23:37:04 +0000 (16:37 -0700)
commit2ef1b02b51fe10b353ab34523885db291a1f4d7a
treea45db703cec00610ef610ceda0d6e4d219c49227
parent99ad3cf2b782232e614e50274a27739e154180f8
block: loop: prepare for supporing direct IO

This patches provides one interface for enabling direct IO
from user space:

- userspace(such as losetup) can pass 'file' which is
opened/fcntl as O_DIRECT

Also __loop_update_dio() is introduced to check if direct I/O
can be used on current loop setting.

The last big change is to introduce LO_FLAGS_DIRECT_IO flag
for userspace to know if direct IO is used to access backing
file.

Cc: linux-api@vger.kernel.org
Signed-off-by: Ming Lei <ming.lei@canonical.com>
Signed-off-by: Santosh Shilimkar <ssantosh@kernel.org>
drivers/block/loop.c
drivers/block/loop.h
include/uapi/linux/loop.h