summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2014-02-08 20:42:52 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2014-04-01 23:19:31 -0400
commit86d564c84c38b1ec06d9f2120d6a7373dcaeff0c (patch)
tree4beaed1ab50eada4439301c72260d99419fd71e5 /fs
parent480f40de91e74190281309fd0ecb2d0414603c2e (diff)
downloadop-kernel-dev-86d564c84c38b1ec06d9f2120d6a7373dcaeff0c.zip
op-kernel-dev-86d564c84c38b1ec06d9f2120d6a7373dcaeff0c.tar.gz
constify blk_rq_map_user_iov() and friends
sg_iovec array passed to it can be const Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs')
-rw-r--r--fs/bio.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/bio.c b/fs/bio.c
index 8754e7b..7065837 100644
--- a/fs/bio.c
+++ b/fs/bio.c
@@ -1003,7 +1003,7 @@ struct bio_map_data {
};
static void bio_set_map_data(struct bio_map_data *bmd, struct bio *bio,
- struct sg_iovec *iov, int iov_count,
+ const struct sg_iovec *iov, int iov_count,
int is_our_pages)
{
memcpy(bmd->sgvecs, iov, sizeof(struct sg_iovec) * iov_count);
@@ -1023,7 +1023,7 @@ static struct bio_map_data *bio_alloc_map_data(int nr_segs,
sizeof(struct sg_iovec) * iov_count, gfp_mask);
}
-static int __bio_copy_iov(struct bio *bio, struct sg_iovec *iov, int iov_count,
+static int __bio_copy_iov(struct bio *bio, const struct sg_iovec *iov, int iov_count,
int to_user, int from_user, int do_free_page)
{
int ret = 0, i;
@@ -1121,7 +1121,7 @@ EXPORT_SYMBOL(bio_uncopy_user);
*/
struct bio *bio_copy_user_iov(struct request_queue *q,
struct rq_map_data *map_data,
- struct sg_iovec *iov, int iov_count,
+ const struct sg_iovec *iov, int iov_count,
int write_to_vm, gfp_t gfp_mask)
{
struct bio_map_data *bmd;
@@ -1260,7 +1260,7 @@ EXPORT_SYMBOL(bio_copy_user);
static struct bio *__bio_map_user_iov(struct request_queue *q,
struct block_device *bdev,
- struct sg_iovec *iov, int iov_count,
+ const struct sg_iovec *iov, int iov_count,
int write_to_vm, gfp_t gfp_mask)
{
int i, j;
@@ -1408,7 +1408,7 @@ EXPORT_SYMBOL(bio_map_user);
* device. Returns an error pointer in case of error.
*/
struct bio *bio_map_user_iov(struct request_queue *q, struct block_device *bdev,
- struct sg_iovec *iov, int iov_count,
+ const struct sg_iovec *iov, int iov_count,
int write_to_vm, gfp_t gfp_mask)
{
struct bio *bio;
OpenPOWER on IntegriCloud