diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2014-12-17 10:46:46 +0100 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2014-12-17 12:43:56 +0100 |
commit | 777eda2c5b84d6f3543f4aecbf4cd1f29b222a81 (patch) | |
tree | 0d007920c70708c178b59051b1fbf34b6e689fb6 /include | |
parent | move_extent_per_page(): get rid of unused w_flags (diff) | |
download | linux-777eda2c5b84d6f3543f4aecbf4cd1f29b222a81.tar.xz linux-777eda2c5b84d6f3543f4aecbf4cd1f29b222a81.zip |
new helper: iter_is_iovec()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/uio.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/uio.h b/include/linux/uio.h index a41e252396c0..1c5e453f7ea9 100644 --- a/include/linux/uio.h +++ b/include/linux/uio.h @@ -101,6 +101,11 @@ static inline size_t iov_iter_count(struct iov_iter *i) return i->count; } +static inline bool iter_is_iovec(struct iov_iter *i) +{ + return !(i->type & (ITER_BVEC | ITER_KVEC)); +} + /* * Cap the iov_iter by given limit; note that the second argument is * *not* the new size - it's upper limit for such. Passing it a value |