---
name: "blk_rq_map_kern"
section: "9"
platform: "linux"
package: "linux-manual-4.9"
version: "4.9.228-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/blk_rq_map_kern"
---

# blk\_rq\_map\_kern(9)

map kernel data to a request, for REQ\_TYPE\_BLOCK\_PC usage

## NAME

blk\_rq\_map\_kern - map kernel data to a request, for REQ\_TYPE\_BLOCK\_PC usage

## SYNOPSIS

**int blk\_rq\_map\_kern(struct request\_queue \*** *q***, struct request \*** *rq***, void \*** *kbuf***, unsigned int** *len***, gfp\_t** *gfp\_mask***);**

## ARGUMENTS

*q*

request queue where request should be inserted

*rq*

request to fill

*kbuf*

the kernel buffer

*len*

length of user data

*gfp\_mask*

memory allocation flags

## DESCRIPTION

Data will be mapped directly if possible. Otherwise a bounce buffer is used. Can be called multiple times to append multiple buffers.

## COPYRIGHT
