Lines Matching +full:- +full:c
4 * Copyright (C) 2006-2008 Nokia Corporation.
6 * SPDX-License-Identifier: GPL-2.0+
13 * This file contains journal replay code. It runs when the file-system is being
20 * trade-off. Also, the journal is indexed by the in-memory index (TNC), so the
33 * struct replay_entry - replay list entry.
37 * @deletion: non-zero if this entry corresponds to a node deletion
67 * struct bud_entry - entry in the list of buds to replay.
83 * set_bud_lprops - set free and dirty space used by a bud.
84 * @c: UBIFS file-system description object
91 static int set_bud_lprops(struct ubifs_info *c, struct bud_entry *b) in set_bud_lprops() argument
96 ubifs_get_lprops(c); in set_bud_lprops()
98 lp = ubifs_lpt_lookup_dirty(c, b->bud->lnum); in set_bud_lprops()
104 dirty = lp->dirty; in set_bud_lprops()
105 if (b->bud->start == 0 && (lp->free != c->leb_size || lp->dirty != 0)) { in set_bud_lprops()
109 * property values should be @lp->free == @c->leb_size and in set_bud_lprops()
110 * @lp->dirty == 0, but that is not the case. The reason is that in set_bud_lprops()
119 * @b->free. in set_bud_lprops()
125 dbg_mnt("bud LEB %d was GC'd (%d free, %d dirty)", b->bud->lnum, in set_bud_lprops()
126 lp->free, lp->dirty); in set_bud_lprops()
127 dbg_gc("bud LEB %d was GC'd (%d free, %d dirty)", b->bud->lnum, in set_bud_lprops()
128 lp->free, lp->dirty); in set_bud_lprops()
129 dirty -= c->leb_size - lp->free; in set_bud_lprops()
134 * that the dirty space may temporarily exceed c->leb_size in set_bud_lprops()
139 b->bud->lnum, lp->free, lp->dirty, b->free, in set_bud_lprops()
140 b->dirty); in set_bud_lprops()
142 lp = ubifs_change_lp(c, lp, b->free, dirty + b->dirty, in set_bud_lprops()
143 lp->flags | LPROPS_TAKEN, 0); in set_bud_lprops()
150 err = ubifs_wbuf_seek_nolock(&c->jheads[b->bud->jhead].wbuf, in set_bud_lprops()
151 b->bud->lnum, c->leb_size - b->free); in set_bud_lprops()
154 ubifs_release_lprops(c); in set_bud_lprops()
159 * set_buds_lprops - set free and dirty space for all replayed buds.
160 * @c: UBIFS file-system description object
165 static int set_buds_lprops(struct ubifs_info *c) in set_buds_lprops() argument
170 list_for_each_entry(b, &c->replay_buds, list) { in set_buds_lprops()
171 err = set_bud_lprops(c, b); in set_buds_lprops()
180 * trun_remove_range - apply a replay entry for a truncation to the TNC.
181 * @c: UBIFS file-system description object
184 static int trun_remove_range(struct ubifs_info *c, struct replay_entry *r) in trun_remove_range() argument
190 min_blk = r->new_size / UBIFS_BLOCK_SIZE; in trun_remove_range()
191 if (r->new_size & (UBIFS_BLOCK_SIZE - 1)) in trun_remove_range()
194 max_blk = r->old_size / UBIFS_BLOCK_SIZE; in trun_remove_range()
195 if ((r->old_size & (UBIFS_BLOCK_SIZE - 1)) == 0) in trun_remove_range()
196 max_blk -= 1; in trun_remove_range()
198 ino = key_inum(c, &r->key); in trun_remove_range()
200 data_key_init(c, &min_key, ino, min_blk); in trun_remove_range()
201 data_key_init(c, &max_key, ino, max_blk); in trun_remove_range()
203 return ubifs_tnc_remove_range(c, &min_key, &max_key); in trun_remove_range()
207 * apply_replay_entry - apply a replay entry to the TNC.
208 * @c: UBIFS file-system description object
213 static int apply_replay_entry(struct ubifs_info *c, struct replay_entry *r) in apply_replay_entry() argument
217 dbg_mntk(&r->key, "LEB %d:%d len %d deletion %d sqnum %llu key ", in apply_replay_entry()
218 r->lnum, r->offs, r->len, r->deletion, r->sqnum); in apply_replay_entry()
220 /* Set c->replay_sqnum to help deal with dangling branches. */ in apply_replay_entry()
221 c->replay_sqnum = r->sqnum; in apply_replay_entry()
223 if (is_hash_key(c, &r->key)) { in apply_replay_entry()
224 if (r->deletion) in apply_replay_entry()
225 err = ubifs_tnc_remove_nm(c, &r->key, &r->nm); in apply_replay_entry()
227 err = ubifs_tnc_add_nm(c, &r->key, r->lnum, r->offs, in apply_replay_entry()
228 r->len, &r->nm); in apply_replay_entry()
230 if (r->deletion) in apply_replay_entry()
231 switch (key_type(c, &r->key)) { in apply_replay_entry()
234 ino_t inum = key_inum(c, &r->key); in apply_replay_entry()
236 err = ubifs_tnc_remove_ino(c, inum); in apply_replay_entry()
240 err = trun_remove_range(c, r); in apply_replay_entry()
243 err = ubifs_tnc_remove(c, &r->key); in apply_replay_entry()
247 err = ubifs_tnc_add(c, &r->key, r->lnum, r->offs, in apply_replay_entry()
248 r->len); in apply_replay_entry()
252 if (c->need_recovery) in apply_replay_entry()
253 err = ubifs_recover_size_accum(c, &r->key, r->deletion, in apply_replay_entry()
254 r->new_size); in apply_replay_entry()
261 * replay_entries_cmp - compare 2 replay entries.
262 * @priv: UBIFS file-system description object
268 * greater sequence number and %-1 otherwise.
281 ubifs_assert(ra->sqnum != rb->sqnum); in replay_entries_cmp()
282 if (ra->sqnum > rb->sqnum) in replay_entries_cmp()
284 return -1; in replay_entries_cmp()
288 * apply_replay_list - apply the replay list to the TNC.
289 * @c: UBIFS file-system description object
294 static int apply_replay_list(struct ubifs_info *c) in apply_replay_list() argument
299 list_sort(c, &c->replay_list, &replay_entries_cmp); in apply_replay_list()
301 list_for_each_entry(r, &c->replay_list, list) { in apply_replay_list()
304 err = apply_replay_entry(c, r); in apply_replay_list()
313 * destroy_replay_list - destroy the replay.
314 * @c: UBIFS file-system description object
318 static void destroy_replay_list(struct ubifs_info *c) in destroy_replay_list() argument
322 list_for_each_entry_safe(r, tmp, &c->replay_list, list) { in destroy_replay_list()
323 if (is_hash_key(c, &r->key)) in destroy_replay_list()
324 kfree(r->nm.name); in destroy_replay_list()
325 list_del(&r->list); in destroy_replay_list()
331 * insert_node - insert a node to the replay list
332 * @c: UBIFS file-system description object
338 * @deletion: non-zero if this is a deletion
343 * This function inserts a scanned non-direntry node to the replay list. The
350 static int insert_node(struct ubifs_info *c, int lnum, int offs, int len, in insert_node() argument
359 if (key_inum(c, key) >= c->highest_inum) in insert_node()
360 c->highest_inum = key_inum(c, key); in insert_node()
364 return -ENOMEM; in insert_node()
368 r->lnum = lnum; in insert_node()
369 r->offs = offs; in insert_node()
370 r->len = len; in insert_node()
371 r->deletion = !!deletion; in insert_node()
372 r->sqnum = sqnum; in insert_node()
373 key_copy(c, key, &r->key); in insert_node()
374 r->old_size = old_size; in insert_node()
375 r->new_size = new_size; in insert_node()
377 list_add_tail(&r->list, &c->replay_list); in insert_node()
382 * insert_dent - insert a directory entry node into the replay list.
383 * @c: UBIFS file-system description object
391 * @deletion: non-zero if this is a deletion
398 static int insert_dent(struct ubifs_info *c, int lnum, int offs, int len, in insert_dent() argument
406 if (key_inum(c, key) >= c->highest_inum) in insert_dent()
407 c->highest_inum = key_inum(c, key); in insert_dent()
411 return -ENOMEM; in insert_dent()
416 return -ENOMEM; in insert_dent()
421 r->lnum = lnum; in insert_dent()
422 r->offs = offs; in insert_dent()
423 r->len = len; in insert_dent()
424 r->deletion = !!deletion; in insert_dent()
425 r->sqnum = sqnum; in insert_dent()
426 key_copy(c, key, &r->key); in insert_dent()
427 r->nm.len = nlen; in insert_dent()
430 r->nm.name = nbuf; in insert_dent()
432 list_add_tail(&r->list, &c->replay_list); in insert_dent()
437 * ubifs_validate_entry - validate directory or extended attribute entry node.
438 * @c: UBIFS file-system description object
442 * Returns zero if the node is all right and a %-EINVAL if not.
444 int ubifs_validate_entry(struct ubifs_info *c, in ubifs_validate_entry() argument
447 int key_type = key_type_flash(c, dent->key); in ubifs_validate_entry()
448 int nlen = le16_to_cpu(dent->nlen); in ubifs_validate_entry()
450 if (le32_to_cpu(dent->ch.len) != nlen + UBIFS_DENT_NODE_SZ + 1 || in ubifs_validate_entry()
451 dent->type >= UBIFS_ITYPES_CNT || in ubifs_validate_entry()
452 nlen > UBIFS_MAX_NLEN || dent->name[nlen] != 0 || in ubifs_validate_entry()
453 strnlen(dent->name, nlen) != nlen || in ubifs_validate_entry()
454 le64_to_cpu(dent->inum) > MAX_INUM) { in ubifs_validate_entry()
455 ubifs_err(c, "bad %s node", key_type == UBIFS_DENT_KEY ? in ubifs_validate_entry()
457 return -EINVAL; in ubifs_validate_entry()
461 ubifs_err(c, "bad key type %d", key_type); in ubifs_validate_entry()
462 return -EINVAL; in ubifs_validate_entry()
469 * is_last_bud - check if the bud is the last in the journal head.
470 * @c: UBIFS file-system description object
478 static int is_last_bud(struct ubifs_info *c, struct ubifs_bud *bud) in is_last_bud() argument
480 struct ubifs_jhead *jh = &c->jheads[bud->jhead]; in is_last_bud()
485 if (list_is_last(&bud->list, &jh->buds_list)) in is_last_bud()
503 * synchronized the write-buffer of current bud (A). But later this was in is_last_bud()
504 * changed and UBIFS started to always synchronize the write-buffer of in is_last_bud()
507 * But because older UBIFS always synchronized A's write-buffer before in is_last_bud()
509 * checking the contents of bud B - if it is empty, then A can be in is_last_bud()
515 next = list_entry(bud->list.next, struct ubifs_bud, list); in is_last_bud()
516 if (!list_is_last(&next->list, &jh->buds_list)) in is_last_bud()
519 err = ubifs_leb_read(c, next->lnum, (char *)&data, next->start, 4, 1); in is_last_bud()
527 * replay_bud - replay a bud logical eraseblock.
528 * @c: UBIFS file-system description object
535 static int replay_bud(struct ubifs_info *c, struct bud_entry *b) in replay_bud() argument
537 int is_last = is_last_bud(c, b->bud); in replay_bud()
538 int err = 0, used = 0, lnum = b->bud->lnum, offs = b->bud->start; in replay_bud()
543 lnum, b->bud->jhead, offs, is_last); in replay_bud()
545 if (c->need_recovery && is_last) in replay_bud()
552 sleb = ubifs_recover_leb(c, lnum, offs, c->sbuf, b->bud->jhead); in replay_bud()
554 sleb = ubifs_scan(c, lnum, offs, c->sbuf, 0); in replay_bud()
559 * The bud does not have to start from offset zero - the beginning of in replay_bud()
564 * At this point lprops thinks that this LEB has 'c->leb_size - offs' in replay_bud()
568 * But we know that real amount of free space is 'c->leb_size - in replay_bud()
569 * sleb->endpt', and the space in the 'lnum' LEB between 'offs' and in replay_bud()
570 * 'sleb->endpt' is used by bud data. We have to correctly calculate in replay_bud()
580 list_for_each_entry(snod, &sleb->nodes, list) { in replay_bud()
585 if (snod->sqnum >= SQNUM_WATERMARK) { in replay_bud()
586 ubifs_err(c, "file system's life ended"); in replay_bud()
590 if (snod->sqnum > c->max_sqnum) in replay_bud()
591 c->max_sqnum = snod->sqnum; in replay_bud()
593 switch (snod->type) { in replay_bud()
596 struct ubifs_ino_node *ino = snod->node; in replay_bud()
597 loff_t new_size = le64_to_cpu(ino->size); in replay_bud()
599 if (le32_to_cpu(ino->nlink) == 0) in replay_bud()
601 err = insert_node(c, lnum, snod->offs, snod->len, in replay_bud()
602 &snod->key, snod->sqnum, deletion, in replay_bud()
608 struct ubifs_data_node *dn = snod->node; in replay_bud()
609 loff_t new_size = le32_to_cpu(dn->size) + in replay_bud()
610 key_block(c, &snod->key) * in replay_bud()
613 err = insert_node(c, lnum, snod->offs, snod->len, in replay_bud()
614 &snod->key, snod->sqnum, deletion, in replay_bud()
621 struct ubifs_dent_node *dent = snod->node; in replay_bud()
623 err = ubifs_validate_entry(c, dent); in replay_bud()
627 err = insert_dent(c, lnum, snod->offs, snod->len, in replay_bud()
628 &snod->key, dent->name, in replay_bud()
629 le16_to_cpu(dent->nlen), snod->sqnum, in replay_bud()
630 !le64_to_cpu(dent->inum), &used); in replay_bud()
635 struct ubifs_trun_node *trun = snod->node; in replay_bud()
636 loff_t old_size = le64_to_cpu(trun->old_size); in replay_bud()
637 loff_t new_size = le64_to_cpu(trun->new_size); in replay_bud()
641 if (old_size < 0 || old_size > c->max_inode_sz || in replay_bud()
642 new_size < 0 || new_size > c->max_inode_sz || in replay_bud()
644 ubifs_err(c, "bad truncation node"); in replay_bud()
652 trun_key_init(c, &key, le32_to_cpu(trun->inum)); in replay_bud()
653 err = insert_node(c, lnum, snod->offs, snod->len, in replay_bud()
654 &key, snod->sqnum, 1, &used, in replay_bud()
659 ubifs_err(c, "unexpected node type %d in bud LEB %d:%d", in replay_bud()
660 snod->type, lnum, snod->offs); in replay_bud()
661 err = -EINVAL; in replay_bud()
668 ubifs_assert(ubifs_search_bud(c, lnum)); in replay_bud()
669 ubifs_assert(sleb->endpt - offs >= used); in replay_bud()
670 ubifs_assert(sleb->endpt % c->min_io_size == 0); in replay_bud()
672 b->dirty = sleb->endpt - offs - used; in replay_bud()
673 b->free = c->leb_size - sleb->endpt; in replay_bud()
675 lnum, b->dirty, b->free); in replay_bud()
682 ubifs_err(c, "bad node is at LEB %d:%d", lnum, snod->offs); in replay_bud()
683 ubifs_dump_node(c, snod->node); in replay_bud()
685 return -EINVAL; in replay_bud()
689 * replay_buds - replay all buds.
690 * @c: UBIFS file-system description object
695 static int replay_buds(struct ubifs_info *c) in replay_buds() argument
701 list_for_each_entry(b, &c->replay_buds, list) { in replay_buds()
702 err = replay_bud(c, b); in replay_buds()
706 ubifs_assert(b->sqnum > prev_sqnum); in replay_buds()
707 prev_sqnum = b->sqnum; in replay_buds()
714 * destroy_bud_list - destroy the list of buds to replay.
715 * @c: UBIFS file-system description object
717 static void destroy_bud_list(struct ubifs_info *c) in destroy_bud_list() argument
721 while (!list_empty(&c->replay_buds)) { in destroy_bud_list()
722 b = list_entry(c->replay_buds.next, struct bud_entry, list); in destroy_bud_list()
723 list_del(&b->list); in destroy_bud_list()
729 * add_replay_bud - add a bud to the list of buds to replay.
730 * @c: UBIFS file-system description object
739 static int add_replay_bud(struct ubifs_info *c, int lnum, int offs, int jhead, in add_replay_bud() argument
749 return -ENOMEM; in add_replay_bud()
754 return -ENOMEM; in add_replay_bud()
757 bud->lnum = lnum; in add_replay_bud()
758 bud->start = offs; in add_replay_bud()
759 bud->jhead = jhead; in add_replay_bud()
760 ubifs_add_bud(c, bud); in add_replay_bud()
762 b->bud = bud; in add_replay_bud()
763 b->sqnum = sqnum; in add_replay_bud()
764 list_add_tail(&b->list, &c->replay_buds); in add_replay_bud()
770 * validate_ref - validate a reference node.
771 * @c: UBIFS file-system description object
777 * returned if the reference node is new, otherwise %-EINVAL is returned if
780 static int validate_ref(struct ubifs_info *c, const struct ubifs_ref_node *ref) in validate_ref() argument
783 int lnum = le32_to_cpu(ref->lnum); in validate_ref()
784 unsigned int offs = le32_to_cpu(ref->offs); in validate_ref()
785 unsigned int jhead = le32_to_cpu(ref->jhead); in validate_ref()
788 * ref->offs may point to the end of LEB when the journal head points in validate_ref()
790 * So this is why we require 'offs > c->leb_size'. in validate_ref()
792 if (jhead >= c->jhead_cnt || lnum >= c->leb_cnt || in validate_ref()
793 lnum < c->main_first || offs > c->leb_size || in validate_ref()
794 offs & (c->min_io_size - 1)) in validate_ref()
795 return -EINVAL; in validate_ref()
798 bud = ubifs_search_bud(c, lnum); in validate_ref()
800 if (bud->jhead == jhead && bud->start <= offs) in validate_ref()
802 ubifs_err(c, "bud at LEB %d:%d was already referred", lnum, offs); in validate_ref()
803 return -EINVAL; in validate_ref()
810 * replay_log_leb - replay a log logical eraseblock.
811 * @c: UBIFS file-system description object
820 static int replay_log_leb(struct ubifs_info *c, int lnum, int offs, void *sbuf) in replay_log_leb() argument
828 sleb = ubifs_scan(c, lnum, offs, sbuf, c->need_recovery); in replay_log_leb()
830 if (PTR_ERR(sleb) != -EUCLEAN || !c->need_recovery) in replay_log_leb()
837 sleb = ubifs_recover_log_leb(c, lnum, offs, sbuf); in replay_log_leb()
842 if (sleb->nodes_cnt == 0) { in replay_log_leb()
847 node = sleb->buf; in replay_log_leb()
848 snod = list_entry(sleb->nodes.next, struct ubifs_scan_node, list); in replay_log_leb()
849 if (c->cs_sqnum == 0) { in replay_log_leb()
857 if (snod->type != UBIFS_CS_NODE) { in replay_log_leb()
858 ubifs_err(c, "first log node at LEB %d:%d is not CS node", in replay_log_leb()
862 if (le64_to_cpu(node->cmt_no) != c->cmt_no) { in replay_log_leb()
863 ubifs_err(c, "first CS node at LEB %d:%d has wrong commit number %llu expected %llu", in replay_log_leb()
865 (unsigned long long)le64_to_cpu(node->cmt_no), in replay_log_leb()
866 c->cmt_no); in replay_log_leb()
870 c->cs_sqnum = le64_to_cpu(node->ch.sqnum); in replay_log_leb()
871 dbg_mnt("commit start sqnum %llu", c->cs_sqnum); in replay_log_leb()
874 if (snod->sqnum < c->cs_sqnum) { in replay_log_leb()
879 * only un-maps it). So this basically means we have to in replay_log_leb()
887 if (snod->offs != 0) { in replay_log_leb()
888 ubifs_err(c, "first node is not at zero offset"); in replay_log_leb()
892 list_for_each_entry(snod, &sleb->nodes, list) { in replay_log_leb()
895 if (snod->sqnum >= SQNUM_WATERMARK) { in replay_log_leb()
896 ubifs_err(c, "file system's life ended"); in replay_log_leb()
900 if (snod->sqnum < c->cs_sqnum) { in replay_log_leb()
901 ubifs_err(c, "bad sqnum %llu, commit sqnum %llu", in replay_log_leb()
902 snod->sqnum, c->cs_sqnum); in replay_log_leb()
906 if (snod->sqnum > c->max_sqnum) in replay_log_leb()
907 c->max_sqnum = snod->sqnum; in replay_log_leb()
909 switch (snod->type) { in replay_log_leb()
911 const struct ubifs_ref_node *ref = snod->node; in replay_log_leb()
913 err = validate_ref(c, ref); in replay_log_leb()
919 err = add_replay_bud(c, le32_to_cpu(ref->lnum), in replay_log_leb()
920 le32_to_cpu(ref->offs), in replay_log_leb()
921 le32_to_cpu(ref->jhead), in replay_log_leb()
922 snod->sqnum); in replay_log_leb()
930 if (snod->offs != 0) { in replay_log_leb()
931 ubifs_err(c, "unexpected node in log"); in replay_log_leb()
936 ubifs_err(c, "unexpected node in log"); in replay_log_leb()
941 if (sleb->endpt || c->lhead_offs >= c->leb_size) { in replay_log_leb()
942 c->lhead_lnum = lnum; in replay_log_leb()
943 c->lhead_offs = sleb->endpt; in replay_log_leb()
946 err = !sleb->endpt; in replay_log_leb()
952 ubifs_err(c, "log error detected while replaying the log at LEB %d:%d", in replay_log_leb()
953 lnum, offs + snod->offs); in replay_log_leb()
954 ubifs_dump_node(c, snod->node); in replay_log_leb()
956 return -EINVAL; in replay_log_leb()
960 * take_ihead - update the status of the index head in lprops to 'taken'.
961 * @c: UBIFS file-system description object
966 static int take_ihead(struct ubifs_info *c) in take_ihead() argument
971 ubifs_get_lprops(c); in take_ihead()
973 lp = ubifs_lpt_lookup_dirty(c, c->ihead_lnum); in take_ihead()
979 free = lp->free; in take_ihead()
981 lp = ubifs_change_lp(c, lp, LPROPS_NC, LPROPS_NC, in take_ihead()
982 lp->flags | LPROPS_TAKEN, 0); in take_ihead()
990 ubifs_release_lprops(c); in take_ihead()
995 * ubifs_replay_journal - replay journal.
996 * @c: UBIFS file-system description object
1002 int ubifs_replay_journal(struct ubifs_info *c) in ubifs_replay_journal() argument
1009 free = take_ihead(c); in ubifs_replay_journal()
1013 if (c->ihead_offs != c->leb_size - free) { in ubifs_replay_journal()
1014 ubifs_err(c, "bad index head LEB %d:%d", c->ihead_lnum, in ubifs_replay_journal()
1015 c->ihead_offs); in ubifs_replay_journal()
1016 return -EINVAL; in ubifs_replay_journal()
1020 c->replaying = 1; in ubifs_replay_journal()
1021 lnum = c->ltail_lnum = c->lhead_lnum; in ubifs_replay_journal()
1024 err = replay_log_leb(c, lnum, 0, c->sbuf); in ubifs_replay_journal()
1026 if (lnum != c->lhead_lnum) in ubifs_replay_journal()
1035 * the file-system. in ubifs_replay_journal()
1037 ubifs_err(c, "no UBIFS nodes found at the log head LEB %d:%d, possibly corrupted", in ubifs_replay_journal()
1039 err = -EINVAL; in ubifs_replay_journal()
1043 lnum = ubifs_next_log_lnum(c, lnum); in ubifs_replay_journal()
1044 } while (lnum != c->ltail_lnum); in ubifs_replay_journal()
1046 err = replay_buds(c); in ubifs_replay_journal()
1050 err = apply_replay_list(c); in ubifs_replay_journal()
1054 err = set_buds_lprops(c); in ubifs_replay_journal()
1059 * UBIFS budgeting calculations use @c->bi.uncommitted_idx variable in ubifs_replay_journal()
1060 * to roughly estimate index growth. Things like @c->bi.min_idx_lebs in ubifs_replay_journal()
1064 c->bi.uncommitted_idx = atomic_long_read(&c->dirty_zn_cnt); in ubifs_replay_journal()
1065 c->bi.uncommitted_idx *= c->max_idx_node_sz; in ubifs_replay_journal()
1067 ubifs_assert(c->bud_bytes <= c->max_bud_bytes || c->need_recovery); in ubifs_replay_journal()
1069 c->lhead_lnum, c->lhead_offs, c->max_sqnum, in ubifs_replay_journal()
1070 (unsigned long)c->highest_inum); in ubifs_replay_journal()
1072 destroy_replay_list(c); in ubifs_replay_journal()
1073 destroy_bud_list(c); in ubifs_replay_journal()
1074 c->replaying = 0; in ubifs_replay_journal()