[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
[dm-devel] [PATCH 1/14] barriers
- From: Mikulas Patocka <mpatocka redhat com>
- To: dm-devel redhat com
- Subject: [dm-devel] [PATCH 1/14] barriers
- Date: Mon, 23 Feb 2009 14:19:19 -0500 (EST)
Introduce a function that adds a bio to the head of the list.
It will be needed for barriers.
Signed-off-by: Mikulas Patocka <mpatocka redhat com>
---
drivers/md/dm-bio-list.h | 10 ++++++++++
1 file changed, 10 insertions(+)
Index: linux-2.6.29-rc1-devel/drivers/md/dm-bio-list.h
===================================================================
--- linux-2.6.29-rc1-devel.orig/drivers/md/dm-bio-list.h 2009-01-19 02:03:49.000000000 +0100
+++ linux-2.6.29-rc1-devel/drivers/md/dm-bio-list.h 2009-01-19 02:05:01.000000000 +0100
@@ -52,6 +52,16 @@ static inline void bio_list_add(struct b
bl->tail = bio;
}
+static inline void bio_list_add_head(struct bio_list *bl, struct bio *bio)
+{
+ bio->bi_next = bl->head;
+
+ bl->head = bio;
+
+ if (!bl->tail)
+ bl->tail = bio;
+}
+
static inline void bio_list_merge(struct bio_list *bl, struct bio_list *bl2)
{
if (!bl2->head)
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]