From 2b2aeb4a4469ace5b1f269e340237841c39d3c46 Mon Sep 17 00:00:00 2001 From: Jim Rees Date: Mon, 9 Apr 2012 22:33:39 -0400 Subject: [PATCH] --- yaml --- r: 299892 b: refs/heads/master c: 10bd295a0b6488ebe634b72a11d8986bd3af3819 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/fs/nfs/blocklayout/blocklayout.c | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/[refs] b/[refs] index 3158b2f718a3..4122391612ec 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: e5265a0c587423bbd21a6b39a572cecff16b9346 +refs/heads/master: 10bd295a0b6488ebe634b72a11d8986bd3af3819 diff --git a/trunk/fs/nfs/blocklayout/blocklayout.c b/trunk/fs/nfs/blocklayout/blocklayout.c index 9c94297bb70e..7f6a23f0244e 100644 --- a/trunk/fs/nfs/blocklayout/blocklayout.c +++ b/trunk/fs/nfs/blocklayout/blocklayout.c @@ -38,6 +38,8 @@ #include /* various write calls */ #include +#include "../pnfs.h" +#include "../internal.h" #include "blocklayout.h" #define NFSDBG_FACILITY NFSDBG_PNFS_LD @@ -868,7 +870,7 @@ nfs4_blk_get_deviceinfo(struct nfs_server *server, const struct nfs_fh *fh, * GETDEVICEINFO's maxcount */ max_resp_sz = server->nfs_client->cl_session->fc_attrs.max_resp_sz; - max_pages = max_resp_sz >> PAGE_SHIFT; + max_pages = nfs_page_array_len(0, max_resp_sz); dprintk("%s max_resp_sz %u max_pages %d\n", __func__, max_resp_sz, max_pages);