1BIO_ALLOC_BIOSET(9) The Linux VFS BIO_ALLOC_BIOSET(9)
2
3
4
6 bio_alloc_bioset - allocate a bio for I/O
7
9 struct bio * bio_alloc_bioset(gfp_t gfp_mask, int nr_iovecs,
10 struct bio_set * bs);
11
13 gfp_mask
14 the GFP_ mask given to the slab allocator
15
16 nr_iovecs
17 number of iovecs to pre-allocate
18
19 bs
20 the bio_set to allocate from.
21
23 bio_alloc_bioset will try its own mempool to satisfy the allocation. If
24 __GFP_WAIT is set then we will block on the internal pool waiting for a
25 struct bio to become free.
26
27 Note that the caller must set ->bi_destructor on successful return of a
28 bio, to do the appropriate freeing of the bio once the reference count
29 drops to zero.
30
32Kernel Hackers Manual 2.6. November 2011 BIO_ALLOC_BIOSET(9)