Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 54a94fcf authored by Dan Carpenter's avatar Dan Carpenter Committed by Michael Ellerman
Browse files

powerpc/cell: Add missing error code in spufs_mkgang()



We should return -ENOMEM if alloc_spu_gang() fails.

Signed-off-by: default avatarDan Carpenter <dan.carpenter@oracle.com>
Acked-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarMichael Ellerman <mpe@ellerman.id.au>
parent 880a3d6a
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -496,8 +496,10 @@ spufs_mkgang(struct inode *dir, struct dentry *dentry, umode_t mode)
	gang = alloc_spu_gang();
	SPUFS_I(inode)->i_ctx = NULL;
	SPUFS_I(inode)->i_gang = gang;
	if (!gang)
	if (!gang) {
		ret = -ENOMEM;
		goto out_iput;
	}

	inode->i_op = &simple_dir_inode_operations;
	inode->i_fop = &simple_dir_operations;