diff options
Diffstat (limited to 'drivers/block/aoe/aoecmd.c')
-rw-r--r-- | drivers/block/aoe/aoecmd.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/block/aoe/aoecmd.c b/drivers/block/aoe/aoecmd.c index 44beb17e8090..d00293ba3b45 100644 --- a/drivers/block/aoe/aoecmd.c +++ b/drivers/block/aoe/aoecmd.c | |||
@@ -751,15 +751,15 @@ gettgt(struct aoedev *d, char *addr) | |||
751 | } | 751 | } |
752 | 752 | ||
753 | static inline void | 753 | static inline void |
754 | diskstats(struct gendisk *disk, struct bio *bio, ulong duration) | 754 | diskstats(struct gendisk *disk, struct bio *bio, ulong duration, sector_t sector) |
755 | { | 755 | { |
756 | unsigned long n_sect = bio->bi_size >> 9; | 756 | unsigned long n_sect = bio->bi_size >> 9; |
757 | const int rw = bio_data_dir(bio); | 757 | const int rw = bio_data_dir(bio); |
758 | 758 | ||
759 | disk_stat_inc(disk, ios[rw]); | 759 | all_stat_inc(disk, ios[rw], sector); |
760 | disk_stat_add(disk, ticks[rw], duration); | 760 | all_stat_add(disk, ticks[rw], duration, sector); |
761 | disk_stat_add(disk, sectors[rw], n_sect); | 761 | all_stat_add(disk, sectors[rw], n_sect, sector); |
762 | disk_stat_add(disk, io_ticks, duration); | 762 | all_stat_add(disk, io_ticks, duration, sector); |
763 | } | 763 | } |
764 | 764 | ||
765 | void | 765 | void |
@@ -879,7 +879,7 @@ aoecmd_ata_rsp(struct sk_buff *skb) | |||
879 | } | 879 | } |
880 | 880 | ||
881 | if (buf && --buf->nframesout == 0 && buf->resid == 0) { | 881 | if (buf && --buf->nframesout == 0 && buf->resid == 0) { |
882 | diskstats(d->gd, buf->bio, jiffies - buf->stime); | 882 | diskstats(d->gd, buf->bio, jiffies - buf->stime, buf->sector); |
883 | n = (buf->flags & BUFFL_FAIL) ? -EIO : 0; | 883 | n = (buf->flags & BUFFL_FAIL) ? -EIO : 0; |
884 | bio_endio(buf->bio, n); | 884 | bio_endio(buf->bio, n); |
885 | mempool_free(buf, d->bufpool); | 885 | mempool_free(buf, d->bufpool); |