]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - fs/ubifs/log.c
Merge tag 'iommu-updates-v3.5' of git://git.kernel.org/pub/scm/linux/kernel/git/joro...
[karo-tx-linux.git] / fs / ubifs / log.c
index f9fd068d1ae0971ea7a27a821d65c3164b1ad26c..c80b15d6c8de0a2cc49bd6a591fd482e7b30b456 100644 (file)
 
 #include "ubifs.h"
 
-#ifdef CONFIG_UBIFS_FS_DEBUG
 static int dbg_check_bud_bytes(struct ubifs_info *c);
-#else
-#define dbg_check_bud_bytes(c) 0
-#endif
 
 /**
  * ubifs_search_bud - search bud LEB.
@@ -262,7 +258,7 @@ int ubifs_add_bud_to_log(struct ubifs_info *c, int jhead, int lnum, int offs)
                 * an unclean reboot, because the target LEB might have been
                 * unmapped, but not yet physically erased.
                 */
-               err = ubifs_leb_map(c, bud->lnum, UBI_SHORTTERM);
+               err = ubifs_leb_map(c, bud->lnum);
                if (err)
                        goto out_unlock;
        }
@@ -270,7 +266,7 @@ int ubifs_add_bud_to_log(struct ubifs_info *c, int jhead, int lnum, int offs)
        dbg_log("write ref LEB %d:%d",
                c->lhead_lnum, c->lhead_offs);
        err = ubifs_write_node(c, ref, UBIFS_REF_NODE_SZ, c->lhead_lnum,
-                              c->lhead_offs, UBI_SHORTTERM);
+                              c->lhead_offs);
        if (err)
                goto out_unlock;
 
@@ -422,7 +418,7 @@ int ubifs_log_start_commit(struct ubifs_info *c, int *ltail_lnum)
 
        len = ALIGN(len, c->min_io_size);
        dbg_log("writing commit start at LEB %d:0, len %d", c->lhead_lnum, len);
-       err = ubifs_leb_write(c, c->lhead_lnum, cs, 0, len, UBI_SHORTTERM);
+       err = ubifs_leb_write(c, c->lhead_lnum, cs, 0, len);
        if (err)
                goto out;
 
@@ -623,7 +619,7 @@ static int add_node(struct ubifs_info *c, void *buf, int *lnum, int *offs,
                int sz = ALIGN(*offs, c->min_io_size), err;
 
                ubifs_pad(c, buf + *offs, sz - *offs);
-               err = ubifs_leb_change(c, *lnum, buf, sz, UBI_SHORTTERM);
+               err = ubifs_leb_change(c, *lnum, buf, sz);
                if (err)
                        return err;
                *lnum = ubifs_next_log_lnum(c, *lnum);
@@ -702,7 +698,7 @@ int ubifs_consolidate_log(struct ubifs_info *c)
                int sz = ALIGN(offs, c->min_io_size);
 
                ubifs_pad(c, buf + offs, sz - offs);
-               err = ubifs_leb_change(c, write_lnum, buf, sz, UBI_SHORTTERM);
+               err = ubifs_leb_change(c, write_lnum, buf, sz);
                if (err)
                        goto out_free;
                offs = ALIGN(offs, c->min_io_size);
@@ -734,8 +730,6 @@ out_free:
        return err;
 }
 
-#ifdef CONFIG_UBIFS_FS_DEBUG
-
 /**
  * dbg_check_bud_bytes - make sure bud bytes calculation are all right.
  * @c: UBIFS file-system description object
@@ -767,5 +761,3 @@ static int dbg_check_bud_bytes(struct ubifs_info *c)
 
        return err;
 }
-
-#endif /* CONFIG_UBIFS_FS_DEBUG */