]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - fs/xfs/xfs_bmap.c
[XFS] Fix sparse warnings in kmem_* functions Patch from Victor Fusco
[linux-2.6-omap-h63xx.git] / fs / xfs / xfs_bmap.c
index 6f5d283888aa2b9ab243d93f8df1fe25c4e8cc34..3e76def1283d191c8827588b221e94b981f34845 100644 (file)
@@ -4754,10 +4754,20 @@ xfs_bmapi(
                                        error = xfs_mod_incore_sb(mp,
                                                        XFS_SBS_FDBLOCKS,
                                                        -(alen), rsvd);
-                               if (!error)
+                               if (!error) {
                                        error = xfs_mod_incore_sb(mp,
                                                        XFS_SBS_FDBLOCKS,
                                                        -(indlen), rsvd);
+                                       if (error && rt) {
+                                               xfs_mod_incore_sb(ip->i_mount,
+                                                       XFS_SBS_FREXTENTS,
+                                                       extsz, rsvd);
+                                       } else if (error) {
+                                               xfs_mod_incore_sb(ip->i_mount,
+                                                       XFS_SBS_FDBLOCKS,
+                                                       alen, rsvd);
+                                       }
+                               }
 
                                if (error) {
                                        if (XFS_IS_QUOTA_ON(ip->i_mount))