aboutsummaryrefslogtreecommitdiffstats
path: root/fs/jfs/namei.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/jfs/namei.c')
-rw-r--r--fs/jfs/namei.c17
1 files changed, 8 insertions, 9 deletions
diff --git a/fs/jfs/namei.c b/fs/jfs/namei.c
index b8d16a6aa88f..5d4ef6e4b7e9 100644
--- a/fs/jfs/namei.c
+++ b/fs/jfs/namei.c
@@ -97,8 +97,8 @@ static int jfs_create(struct inode *dip, struct dentry *dentry, int mode,
97 * begin the transaction before we search the directory. 97 * begin the transaction before we search the directory.
98 */ 98 */
99 ip = ialloc(dip, mode); 99 ip = ialloc(dip, mode);
100 if (ip == NULL) { 100 if (IS_ERR(ip)) {
101 rc = -ENOSPC; 101 rc = PTR_ERR(ip);
102 goto out2; 102 goto out2;
103 } 103 }
104 104
@@ -231,8 +231,8 @@ static int jfs_mkdir(struct inode *dip, struct dentry *dentry, int mode)
231 * begin the transaction before we search the directory. 231 * begin the transaction before we search the directory.
232 */ 232 */
233 ip = ialloc(dip, S_IFDIR | mode); 233 ip = ialloc(dip, S_IFDIR | mode);
234 if (ip == NULL) { 234 if (IS_ERR(ip)) {
235 rc = -ENOSPC; 235 rc = PTR_ERR(ip);
236 goto out2; 236 goto out2;
237 } 237 }
238 238
@@ -906,8 +906,8 @@ static int jfs_symlink(struct inode *dip, struct dentry *dentry,
906 * (iAlloc() returns new, locked inode) 906 * (iAlloc() returns new, locked inode)
907 */ 907 */
908 ip = ialloc(dip, S_IFLNK | 0777); 908 ip = ialloc(dip, S_IFLNK | 0777);
909 if (ip == NULL) { 909 if (IS_ERR(ip)) {
910 rc = -ENOSPC; 910 rc = PTR_ERR(ip);
911 goto out2; 911 goto out2;
912 } 912 }
913 913
@@ -978,7 +978,6 @@ static int jfs_symlink(struct inode *dip, struct dentry *dentry,
978 xlen = xsize >> JFS_SBI(sb)->l2bsize; 978 xlen = xsize >> JFS_SBI(sb)->l2bsize;
979 if ((rc = xtInsert(tid, ip, 0, 0, xlen, &xaddr, 0))) { 979 if ((rc = xtInsert(tid, ip, 0, 0, xlen, &xaddr, 0))) {
980 txAbort(tid, 0); 980 txAbort(tid, 0);
981 rc = -ENOSPC;
982 goto out3; 981 goto out3;
983 } 982 }
984 extent = xaddr; 983 extent = xaddr;
@@ -1350,8 +1349,8 @@ static int jfs_mknod(struct inode *dir, struct dentry *dentry,
1350 goto out; 1349 goto out;
1351 1350
1352 ip = ialloc(dir, mode); 1351 ip = ialloc(dir, mode);
1353 if (ip == NULL) { 1352 if (IS_ERR(ip)) {
1354 rc = -ENOSPC; 1353 rc = PTR_ERR(ip);
1355 goto out1; 1354 goto out1;
1356 } 1355 }
1357 jfs_ip = JFS_IP(ip); 1356 jfs_ip = JFS_IP(ip);