lkml.org 
[lkml]   [2008]   [Mar]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [RFC] Stacking bio support - patch 4/4 for 2.6.23.17 (stable)

From 278ee2744eddfe67743ed3967bec3f9b773d9015 Mon Sep 17 00:00:00 2001
From: Alan D. Brunelle <alan.brunelle@hp.com>
Date: Fri, 14 Mar 2008 09:46:33 -0400
Subject: [PATCH] Fixed compilation bugs


---
drivers/md/raid1.c | 4 ++--
drivers/md/raid5.c | 6 +++---
fs/bio.c | 2 +-
3 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/md/raid1.c b/drivers/md/raid1.c
index 63ffaaf..ce6b576 100644
--- a/drivers/md/raid1.c
+++ b/drivers/md/raid1.c
@@ -910,7 +910,7 @@ static int make_request(struct request_queue *q, struct bio * bio)

mbio->bi_sector = r1_bio->sector + conf->mirrors[i].rdev->data_offset;
mbio->bi_bdev = conf->mirrors[i].rdev->bdev;
- bio_set_endio(mbio, raid1_end_write_request;)
+ bio_set_endio(mbio, raid1_end_write_request);
mbio->bi_rw = WRITE | do_barriers | do_sync;
mbio->bi_private = r1_bio;

@@ -1240,7 +1240,7 @@ static void sync_request_write(mddev_t *mddev, r1bio_t *r1_bio)
}
r1_bio->read_disk = primary;
for (i=0; i<mddev->raid_disks; i++)
- if (bio_set_endio(r1_bio->bios[i], end_sync_read)) {
+ if (bio_get_endio(r1_bio->bios[i]) == end_sync_read) {
int j;
int vcnt = r1_bio->sectors >> (PAGE_SHIFT- 9);
struct bio *pbio = r1_bio->bios[primary];
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index 9fe55db..f83feb8 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -3608,13 +3608,13 @@ static int make_request(struct request_queue *q, struct bio * bi)
spin_unlock_irq(&conf->device_lock);
if (remaining == 0) {
int bytes = bi->bi_size;
+ bio_end_io_t *endio = bio_get_endio(bi);

if ( rw == WRITE )
md_write_end(mddev);
bi->bi_size = 0;
- (bio_get_endio(bi))((bi, bytes,
- test_bit(BIO_UPTODATE, &bi->bi_flags)
- ? 0 : -EIO);
+ endio(bi, bytes,
+ test_bit(BIO_UPTODATE, &bi->bi_flags) ? 0 : -EIO);
}
return 0;
}
diff --git a/fs/bio.c b/fs/bio.c
index d57f0f3..0ecd345 100644
--- a/fs/bio.c
+++ b/fs/bio.c
@@ -199,7 +199,7 @@ void bio_init(struct bio *bio)
bio->bi_hw_back_size = 0;
bio->bi_size = 0;
bio->bi_max_vecs = 0;
- bio->bi_end_io = NULL;
+ bio_set_endio(bio, NULL);
atomic_set(&bio->bi_cnt, 1);
bio->bi_private = NULL;
}
--
1.5.2.5
\
 
 \ /
  Last update: 2008-03-14 15:09    [W:0.076 / U:0.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site