aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAndrew Morton <akpm@osdl.org>2006-12-10 05:19:47 -0500
committerLinus Torvalds <torvalds@woody.osdl.org>2006-12-10 12:55:41 -0500
commit98c4d57decf97bf8ddfe948a3266aa56b38b1a51 (patch)
tree5cf91db0f18654655bfcfba555a7e58ec2f550c2 /fs
parent6f88cc2e9c29c181557b477ee396375906acbc90 (diff)
[PATCH] io-accounting: direct-io
Account for direct-io. Cc: Jay Lan <jlan@sgi.com> Cc: Shailabh Nagar <nagar@watson.ibm.com> Cc: Balbir Singh <balbir@in.ibm.com> Cc: Chris Sturtivant <csturtiv@sgi.com> Cc: Tony Ernst <tee@sgi.com> Cc: Guillaume Thouvenin <guillaume.thouvenin@bull.net> Cc: David Wright <daw@sgi.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs')
-rw-r--r--fs/direct-io.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/fs/direct-io.c b/fs/direct-io.c
index 5981e17f46f0..45d34d807391 100644
--- a/fs/direct-io.c
+++ b/fs/direct-io.c
@@ -27,6 +27,7 @@
27#include <linux/slab.h> 27#include <linux/slab.h>
28#include <linux/highmem.h> 28#include <linux/highmem.h>
29#include <linux/pagemap.h> 29#include <linux/pagemap.h>
30#include <linux/task_io_accounting_ops.h>
30#include <linux/bio.h> 31#include <linux/bio.h>
31#include <linux/wait.h> 32#include <linux/wait.h>
32#include <linux/err.h> 33#include <linux/err.h>
@@ -675,6 +676,13 @@ submit_page_section(struct dio *dio, struct page *page,
675{ 676{
676 int ret = 0; 677 int ret = 0;
677 678
679 if (dio->rw & WRITE) {
680 /*
681 * Read accounting is performed in submit_bio()
682 */
683 task_io_account_write(len);
684 }
685
678 /* 686 /*
679 * Can we just grow the current page's presence in the dio? 687 * Can we just grow the current page's presence in the dio?
680 */ 688 */