.\" This manpage has been automatically generated by docbook2man
.\" from a DocBook document. This tool can be found at:
.\"
.\" Please send any bug reports, improvements, comments, patches,
.\" etc. to Steve Cheng .
.TH "BLK_RQ_MAP_USER" "9" "09 October 2005" "" ""
.SH NAME
blk_rq_map_user \- map user data to a request, for REQ_BLOCK_PC usage
.SH SYNOPSIS
"SYNOPSIS"
.sp
\fB
.sp
struct request * blk_rq_map_user (request_queue_t * \fIq\fB, int \fIrw\fB, void __user * \fIubuf\fB, unsigned int \fIlen\fB);
\fR
.SH "ARGUMENTS"
.TP
\fB\fIq\fB\fR
request queue where request should be inserted
.TP
\fB\fIrw\fB\fR
READ or WRITE data
.TP
\fB\fIubuf\fB\fR
the user buffer
.TP
\fB\fIlen\fB\fR
length of user data
.SH "DESCRIPTION"
.PP
Data will be mapped directly for zero copy io, if possible. Otherwise
a kernel bounce buffer is used.
.PP
A matching \fBblk_rq_unmap_user\fR must be issued at the end of io, while
still in process context.
.SH "NOTE"
.PP
The mapped bio may need to be bounced through \fBblk_queue_bounce\fR
before being submitted to the device, as pages mapped may be out of
reach. It's the callers responsibility to make sure this happens. The
original bio must be passed back in to \fBblk_rq_unmap_user\fR for proper
unmapping.