Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 12156
b: refs/heads/master
c: 496456c
h: refs/heads/master
v: v3
  • Loading branch information
Jens Axboe committed Nov 1, 2005
1 parent 161f3e5 commit c6949b0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 10 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a362357b6cd62643d4dda3b152639303d78473da
refs/heads/master: 496456c24f1f4280d50b81aa5bf439ab440b3d7e
13 changes: 4 additions & 9 deletions trunk/drivers/block/aoe/aoecmd.c
Original file line number Diff line number Diff line change
Expand Up @@ -468,16 +468,11 @@ aoecmd_ata_rsp(struct sk_buff *skb)
unsigned long duration = jiffies - buf->start_time;
unsigned long n_sect = buf->bio->bi_size >> 9;
struct gendisk *disk = d->gd;
const int rw = bio_data_dir(buf->bio);

if (bio_data_dir(buf->bio) == WRITE) {
disk_stat_inc(disk, writes);
disk_stat_add(disk, write_ticks, duration);
disk_stat_add(disk, write_sectors, n_sect);
} else {
disk_stat_inc(disk, reads);
disk_stat_add(disk, read_ticks, duration);
disk_stat_add(disk, read_sectors, n_sect);
}
disk_stat_inc(disk, ios[rw]);
disk_stat_add(disk, ticks[rw], duration);
disk_stat_add(disk, sectors[rw], n_sect);
disk_stat_add(disk, io_ticks, duration);
n = (buf->flags & BUFFL_FAIL) ? -EIO : 0;
bio_endio(buf->bio, buf->bio->bi_size, n);
Expand Down

0 comments on commit c6949b0

Please sign in to comment.