diff options
author | Fred Isaman <iisaman@netapp.com> | 2011-02-28 20:34:14 -0500 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2011-03-11 15:38:42 -0500 |
commit | 94ad1c80e28f9700c84b4d28d1e5302ddf63a6fd (patch) | |
tree | 2c600c1f8e85648c7693b5f0018b5d0b7e960b5f /fs/nfs/pnfs.c | |
parent | d684d2ae10a4f95d3035abf698d7d611ff2cd279 (diff) |
NFSv4.1: coelesce across layout stripes
Add a pg_test layout driver hook which is used to avoid coelescing I/O across
layout stripes.
Signed-off-by: Andy Adamson <andros@netapp.com>
Signed-off-by: Andy Adamson <andros@citi.umich.edu>
Signed-off-by: Dean Hildebrand <dhildeb@us.ibm.com>
Signed-off-by: Fred Isaman <iisaman@citi.umich.edu>
Signed-off-by: Fred Isaman <iisaman@netapp.com>
Signed-off-by: Benny Halevy <bhalevy@panasas.com>
Signed-off-by: Boaz Harrosh <bharrosh@panasas.com>
Signed-off-by: Oleg Drokin <green@linuxhacker.ru>
Signed-off-by: Tao Guo <guotao@nrchpc.ac.cn>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'fs/nfs/pnfs.c')
-rw-r--r-- | fs/nfs/pnfs.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/fs/nfs/pnfs.c b/fs/nfs/pnfs.c index 3afa82e45438..330cee115de0 100644 --- a/fs/nfs/pnfs.c +++ b/fs/nfs/pnfs.c | |||
@@ -858,6 +858,22 @@ out_forget_reply: | |||
858 | goto out; | 858 | goto out; |
859 | } | 859 | } |
860 | 860 | ||
861 | static void | ||
862 | pnfs_set_pg_test(struct inode *inode, struct nfs_pageio_descriptor *pgio) | ||
863 | { | ||
864 | struct pnfs_layoutdriver_type *ld; | ||
865 | |||
866 | ld = NFS_SERVER(inode)->pnfs_curr_ld; | ||
867 | pgio->pg_test = (ld ? ld->pg_test : NULL); | ||
868 | } | ||
869 | |||
870 | void | ||
871 | pnfs_pageio_init_read(struct nfs_pageio_descriptor *pgio, | ||
872 | struct inode *inode) | ||
873 | { | ||
874 | pnfs_set_pg_test(inode, pgio); | ||
875 | } | ||
876 | |||
861 | /* | 877 | /* |
862 | * Device ID cache. Currently supports one layout type per struct nfs_client. | 878 | * Device ID cache. Currently supports one layout type per struct nfs_client. |
863 | * Add layout type to the lookup key to expand to support multiple types. | 879 | * Add layout type to the lookup key to expand to support multiple types. |