Merge branch 'svn-trunk'

This commit is contained in:
Bart Van Assche
2017-03-07 20:59:24 -08:00
2 changed files with 9 additions and 5 deletions

View File

@@ -54,10 +54,6 @@ static inline unsigned int queue_max_hw_sectors(struct request_queue *q)
}
#endif
#ifndef RQF_COPY_USER
#define RQF_COPY_USER REQ_COPY_USER
#endif
/* <linux/compiler.h> */
#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 20)

View File

@@ -8107,7 +8107,15 @@ static struct request *__blk_map_kern_sg(struct request_queue *q,
if (bw != NULL) {
atomic_set(&bw->bios_inflight, bios);
rq->cmd_flags |= RQF_COPY_USER;
#if LINUX_VERSION_CODE < KERNEL_VERSION(4, 10, 0)
/*
* See also patch "block: split out request-only flags into a
* new namespace" (commit e806402130c9).
*/
rq->cmd_flags |= REQ_COPY_USER;
#else
rq->rq_flags |= RQF_COPY_USER;
#endif
}
out: