X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=block%2Fll_rw_blk.c;h=7eb36c53f4b7868247141a105ef82e8be3e2d96f;hb=6d56ab936237b429366ade0d2a1540c7e41beb87;hp=eac48bec14791533a594af0e2909b7ed5347c091;hpb=0d38eddab9ce6de3a9d6d583043dfa97b6bc0d3b;p=linux-2.6 diff --git a/block/ll_rw_blk.c b/block/ll_rw_blk.c index eac48bec14..7eb36c53f4 100644 --- a/block/ll_rw_blk.c +++ b/block/ll_rw_blk.c @@ -3452,7 +3452,12 @@ void end_that_request_last(struct request *req, int uptodate) if (unlikely(laptop_mode) && blk_fs_request(req)) laptop_io_completion(); - if (disk && blk_fs_request(req)) { + /* + * Account IO completion. bar_rq isn't accounted as a normal + * IO on queueing nor completion. Accounting the containing + * request is enough. + */ + if (disk && blk_fs_request(req) && req != &req->q->bar_rq) { unsigned long duration = jiffies - req->start_time; const int rw = rq_data_dir(req);