summaryrefslogtreecommitdiff
path: root/fs/orangefs/devorangefs-req.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/orangefs/devorangefs-req.c')
-rw-r--r--fs/orangefs/devorangefs-req.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/fs/orangefs/devorangefs-req.c b/fs/orangefs/devorangefs-req.c
index c19f0787c9c6..2826859bdc2c 100644
--- a/fs/orangefs/devorangefs-req.c
+++ b/fs/orangefs/devorangefs-req.c
@@ -461,13 +461,10 @@ static ssize_t orangefs_devreq_write_iter(struct kiocb *iocb,
if (op->downcall.type != ORANGEFS_VFS_OP_READDIR)
goto wakeup;
- op->downcall.trailer_buf =
- vmalloc(op->downcall.trailer_size);
- if (op->downcall.trailer_buf == NULL) {
- gossip_err("%s: failed trailer vmalloc.\n",
- __func__);
+ op->downcall.trailer_buf = vmalloc(op->downcall.trailer_size);
+ if (!op->downcall.trailer_buf)
goto Enomem;
- }
+
memset(op->downcall.trailer_buf, 0, op->downcall.trailer_size);
if (!copy_from_iter_full(op->downcall.trailer_buf,
op->downcall.trailer_size, iter)) {