aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/nfs_xdr.h
diff options
context:
space:
mode:
authorChuck Lever <cel@netapp.com>2006-05-25 01:40:53 -0400
committerTrond Myklebust <Trond.Myklebust@netapp.com>2006-06-09 09:34:07 -0400
commit0d0b5cb36faf7002a11736032313f06d6f3d881c (patch)
treed767ae12fde00b553546aab9f5aa3e23cd86069d /include/linux/nfs_xdr.h
parentbf3fcf89552f24657bcfb6a9d73cd167ebb496c6 (diff)
NFS: Optimize allocation of nfs_read/write_data structures
Clean up use of page_array, and fix an off-by-one error noticed by Tom Talpey which causes kmalloc calls in cases where using the page_array is sufficient. Test plan: Normal client functional testing with r/wsize=32768. Signed-off-by: Chuck Lever <cel@netapp.com> Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'include/linux/nfs_xdr.h')
-rw-r--r--include/linux/nfs_xdr.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h
index c483e239f993..e206c07080fe 100644
--- a/include/linux/nfs_xdr.h
+++ b/include/linux/nfs_xdr.h
@@ -694,7 +694,7 @@ struct nfs_read_data {
694#ifdef CONFIG_NFS_V4 694#ifdef CONFIG_NFS_V4
695 unsigned long timestamp; /* For lease renewal */ 695 unsigned long timestamp; /* For lease renewal */
696#endif 696#endif
697 struct page *page_array[NFS_PAGEVEC_SIZE + 1]; 697 struct page *page_array[NFS_PAGEVEC_SIZE];
698}; 698};
699 699
700struct nfs_write_data { 700struct nfs_write_data {
@@ -712,7 +712,7 @@ struct nfs_write_data {
712#ifdef CONFIG_NFS_V4 712#ifdef CONFIG_NFS_V4
713 unsigned long timestamp; /* For lease renewal */ 713 unsigned long timestamp; /* For lease renewal */
714#endif 714#endif
715 struct page *page_array[NFS_PAGEVEC_SIZE + 1]; 715 struct page *page_array[NFS_PAGEVEC_SIZE];
716}; 716};
717 717
718struct nfs_access_entry; 718struct nfs_access_entry;