[PATCH] JFS: return correct error when i-node allocation failed
commit087387f90f577f5a0ab68d33ef326c9bb6d80dda
authorAkinobu Mita <mita@miraclelinux.com>
Thu, 14 Sep 2006 14:22:38 +0000 (14 09:22 -0500)
committerDave Kleikamp <shaggy@austin.ibm.com>
Mon, 2 Oct 2006 14:51:01 +0000 (2 09:51 -0500)
tree99f2ba6f672c9d98fbd628ee54120f63593f1bd0
parent2a6968a9784551c216f9379a728d4104dbad98a8
[PATCH] JFS: return correct error when i-node allocation failed

I have seen confusing behavior on JFS when I injected many intentional
slab allocation errors. The cp command failed with no disk space error
with enough disk space.

This patch makes:

- change the return value in case slab allocation failures happen
  from -ENOSPC to -ENOMEM

- ialloc() return error code so that the caller can know the reason
  of failures

Signed-off-by: Akinobu Mita <mita@miraclelinux.com>
Signed-off-by: Dave Kleikamp <shaggy@austin.ibm.com>
(cherry picked from 2b46f77976f798f3fe800809a1d0ed38763c71c8 commit)
fs/jfs/jfs_dtree.c
fs/jfs/jfs_inode.c
fs/jfs/jfs_unicode.c
fs/jfs/namei.c
fs/jfs/super.c