aboutsummaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorTrond Myklebust <trond.myklebust@fys.uio.no>2005-01-04 21:45:13 +0100
committerTrond Myklebust <trond.myklebust@fys.uio.no>2005-01-04 21:45:13 +0100
commita3056ac5666d2881ca31d3393702763ee1c291ed (patch)
tree9c43c3623aaf4118677f79ef39748a0b9bba494d /fs
parent1d809e4da2d391f6c61135577ebea098361edeb8 (diff)
downloadhistory-a3056ac5666d2881ca31d3393702763ee1c291ed.tar.gz
Subject: [PATCH] NFS: Use sizeof() instead of C macro
Replace a C macro with sizeof(). Signed-off-by: Chuck Lever <cel@netapp.com> Signed-off-by: Trond Myklebust <trond.myklebust@fys.uio.no>
Diffstat (limited to 'fs')
-rw-r--r--fs/nfs/direct.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/fs/nfs/direct.c b/fs/nfs/direct.c
index d6862fe4df4bfb..ef264e432e9899 100644
--- a/fs/nfs/direct.c
+++ b/fs/nfs/direct.c
@@ -52,7 +52,6 @@
#include <asm/uaccess.h>
#define NFSDBG_FACILITY NFSDBG_VFS
-#define VERF_SIZE (2 * sizeof(__u32))
#define MAX_DIRECTIO_SIZE (4096UL << PAGE_SHIFT)
@@ -303,11 +302,11 @@ retry:
if (tot_bytes == 0)
memcpy(&first_verf.verifier, &wdata.verf.verifier,
- VERF_SIZE);
+ sizeof(first_verf.verifier));
if (wdata.verf.committed != NFS_FILE_SYNC) {
need_commit = 1;
- if (memcmp(&first_verf.verifier,
- &wdata.verf.verifier, VERF_SIZE))
+ if (memcmp(&first_verf.verifier, &wdata.verf.verifier,
+ sizeof(first_verf.verifier)));
goto sync_retry;
}
@@ -331,8 +330,8 @@ retry:
unlock_kernel();
if (result < 0 || memcmp(&first_verf.verifier,
- &wdata.verf.verifier,
- VERF_SIZE) != 0)
+ &wdata.verf.verifier,
+ sizeof(first_verf.verifier)) != 0)
goto sync_retry;
}
result = tot_bytes;