summaryrefslogtreecommitdiffstats
path: root/fs/nfs/delegation.c
diff options
context:
space:
mode:
authorPanagiotis Issaris <takis@issaris.org>2006-09-27 01:49:39 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-09-27 08:26:10 -0700
commitf52720ca5f48574e347dff35ffe6b389ace61537 (patch)
tree7efc8ec6bad32b98e406a5c553149d57e46bd07e /fs/nfs/delegation.c
parentf8314dc60ccba7e41f425048c4160dc7f63377d5 (diff)
downloadop-kernel-dev-f52720ca5f48574e347dff35ffe6b389ace61537.zip
op-kernel-dev-f52720ca5f48574e347dff35ffe6b389ace61537.tar.gz
[PATCH] fs: Removing useless casts
* Removing useless casts * Removing useless wrapper * Conversion from kmalloc+memset to kzalloc Signed-off-by: Panagiotis Issaris <takis@issaris.org> Acked-by: Dave Kleikamp <shaggy@austin.ibm.com> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/nfs/delegation.c')
-rw-r--r--fs/nfs/delegation.c7
1 files changed, 1 insertions, 6 deletions
diff --git a/fs/nfs/delegation.c b/fs/nfs/delegation.c
index 5713367..841c99a 100644
--- a/fs/nfs/delegation.c
+++ b/fs/nfs/delegation.c
@@ -20,11 +20,6 @@
#include "delegation.h"
#include "internal.h"
-static struct nfs_delegation *nfs_alloc_delegation(void)
-{
- return (struct nfs_delegation *)kmalloc(sizeof(struct nfs_delegation), GFP_KERNEL);
-}
-
static void nfs_free_delegation(struct nfs_delegation *delegation)
{
if (delegation->cred)
@@ -124,7 +119,7 @@ int nfs_inode_set_delegation(struct inode *inode, struct rpc_cred *cred, struct
if ((nfsi->cache_validity & (NFS_INO_REVAL_PAGECACHE|NFS_INO_INVALID_ATTR)))
__nfs_revalidate_inode(NFS_SERVER(inode), inode);
- delegation = nfs_alloc_delegation();
+ delegation = kmalloc(sizeof(*delegation), GFP_KERNEL);
if (delegation == NULL)
return -ENOMEM;
memcpy(delegation->stateid.data, res->delegation.data,
OpenPOWER on IntegriCloud