Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=097c94a4e8bde978c8d12683d9a34048e9139e4b
Commit:     097c94a4e8bde978c8d12683d9a34048e9139e4b
Parent:     1c5093ba036b5e1a4befdcd6036d241178a720a8
Author:     Kiyoshi Ueda <[EMAIL PROTECTED]>
AuthorDate: Tue Dec 11 17:44:06 2007 -0500
Committer:  Jens Axboe <[EMAIL PROTECTED]>
CommitDate: Mon Jan 28 10:36:37 2008 +0100

    blk_end_request: changing nbd (take 4)
    
    This patch converts nbd to use blk_end_request interfaces.
    Related 'uptodate' arguments are converted to 'error'.
    
    Cc: Paul Clements <[EMAIL PROTECTED]>
    Signed-off-by: Kiyoshi Ueda <[EMAIL PROTECTED]>
    Signed-off-by: Jun'ichi Nomura <[EMAIL PROTECTED]>
    Signed-off-by: Jens Axboe <[EMAIL PROTECTED]>
---
 drivers/block/nbd.c |    8 +++-----
 1 files changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c
index ba9b17e..ae31060 100644
--- a/drivers/block/nbd.c
+++ b/drivers/block/nbd.c
@@ -100,17 +100,15 @@ static const char *nbdcmd_to_ascii(int cmd)
 
 static void nbd_end_request(struct request *req)
 {
-       int uptodate = (req->errors == 0) ? 1 : 0;
+       int error = req->errors ? -EIO : 0;
        struct request_queue *q = req->q;
        unsigned long flags;
 
        dprintk(DBG_BLKDEV, "%s: request %p: %s\n", req->rq_disk->disk_name,
-                       req, uptodate? "done": "failed");
+                       req, error ? "failed" : "done");
 
        spin_lock_irqsave(q->queue_lock, flags);
-       if (!end_that_request_first(req, uptodate, req->nr_sectors)) {
-               end_that_request_last(req, uptodate);
-       }
+       __blk_end_request(req, error, req->nr_sectors << 9);
        spin_unlock_irqrestore(q->queue_lock, flags);
 }
 
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to