diff options
author | Jens Axboe <jens.axboe@oracle.com> | 2008-09-11 07:17:37 -0400 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2008-10-09 02:56:17 -0400 |
commit | 0a0d96b03a1f3bfd6bc3ea08008699e8e59fccd9 (patch) | |
tree | 59cbbcb691a76121fba8d7af74d89558296d5834 /include | |
parent | 3e6053d76dcbd92b2f9f4ad5ece9bce83149523e (diff) |
block: add bio_kmalloc()
Not all callers need (or want!) the mempool backing guarentee, it
essentially means that you can only use bio_alloc() for short allocations
and not for preallocating some bio's at setup or init time.
So add bio_kmalloc() which does the same thing as bio_alloc(), except
it just uses kmalloc() as the backing instead of the bio mempools.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/bio.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/bio.h b/include/linux/bio.h index 7af373f253dc..6520ee1a3f6d 100644 --- a/include/linux/bio.h +++ b/include/linux/bio.h | |||
@@ -308,6 +308,7 @@ extern struct bio_set *bioset_create(int, int); | |||
308 | extern void bioset_free(struct bio_set *); | 308 | extern void bioset_free(struct bio_set *); |
309 | 309 | ||
310 | extern struct bio *bio_alloc(gfp_t, int); | 310 | extern struct bio *bio_alloc(gfp_t, int); |
311 | extern struct bio *bio_kmalloc(gfp_t, int); | ||
311 | extern struct bio *bio_alloc_bioset(gfp_t, int, struct bio_set *); | 312 | extern struct bio *bio_alloc_bioset(gfp_t, int, struct bio_set *); |
312 | extern void bio_put(struct bio *); | 313 | extern void bio_put(struct bio *); |
313 | extern void bio_free(struct bio *, struct bio_set *); | 314 | extern void bio_free(struct bio *, struct bio_set *); |