Skip to content

Commit d099d7b

Browse files
Peng Taotrondmypd
authored andcommitted
pnfs/flexfiles: LAYOUTSTATS ii_count should be ops instead of bytes
Turned out I misinterpreted the spec... Cc: Tom Haynes <[email protected]> Reported-by: Jean Spector <[email protected]> Signed-off-by: Peng Tao <[email protected]> Signed-off-by: Trond Myklebust <[email protected]>
1 parent 86d80f9 commit d099d7b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

fs/nfs/flexfilelayout/flexfilelayout.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1863,10 +1863,9 @@ ff_layout_mirror_prepare_stats(struct nfs42_layoutstat_args *args,
18631863
memcpy(&devinfo->dev_id, &dev->deviceid, NFS4_DEVICEID4_SIZE);
18641864
devinfo->offset = pls->pls_range.offset;
18651865
devinfo->length = pls->pls_range.length;
1866-
/* well, we don't really know if IO is continuous or not! */
1867-
devinfo->read_count = mirror->read_stat.io_stat.bytes_completed;
1866+
devinfo->read_count = mirror->read_stat.io_stat.ops_completed;
18681867
devinfo->read_bytes = mirror->read_stat.io_stat.bytes_completed;
1869-
devinfo->write_count = mirror->write_stat.io_stat.bytes_completed;
1868+
devinfo->write_count = mirror->write_stat.io_stat.ops_completed;
18701869
devinfo->write_bytes = mirror->write_stat.io_stat.bytes_completed;
18711870
devinfo->layout_type = LAYOUT_FLEX_FILES;
18721871
devinfo->layoutstats_encode = ff_layout_encode_layoutstats;

0 commit comments

Comments
 (0)