Lines Matching refs:lp

197 			struct ubifs_lprops *lp;  in add_to_lpt_heap()  local
199 lp = heap->arr[cpos]; in add_to_lpt_heap()
200 lp->flags &= ~LPROPS_CAT_MASK; in add_to_lpt_heap()
201 lp->flags |= LPROPS_UNCAT; in add_to_lpt_heap()
202 list_add(&lp->list, &c->uncat_list); in add_to_lpt_heap()
535 const struct ubifs_lprops *lp, in ubifs_change_lp() argument
543 struct ubifs_lprops *lprops = (struct ubifs_lprops *)lp; in ubifs_change_lp()
667 const struct ubifs_lprops *lp; in ubifs_change_one_lp() local
671 lp = ubifs_lpt_lookup_dirty(c, lnum); in ubifs_change_one_lp()
672 if (IS_ERR(lp)) { in ubifs_change_one_lp()
673 err = PTR_ERR(lp); in ubifs_change_one_lp()
677 flags = (lp->flags | flags_set) & ~flags_clean; in ubifs_change_one_lp()
678 lp = ubifs_change_lp(c, lp, free, dirty, flags, idx_gc_cnt); in ubifs_change_one_lp()
679 if (IS_ERR(lp)) in ubifs_change_one_lp()
680 err = PTR_ERR(lp); in ubifs_change_one_lp()
706 const struct ubifs_lprops *lp; in ubifs_update_one_lp() local
710 lp = ubifs_lpt_lookup_dirty(c, lnum); in ubifs_update_one_lp()
711 if (IS_ERR(lp)) { in ubifs_update_one_lp()
712 err = PTR_ERR(lp); in ubifs_update_one_lp()
716 flags = (lp->flags | flags_set) & ~flags_clean; in ubifs_update_one_lp()
717 lp = ubifs_change_lp(c, lp, free, lp->dirty + dirty, flags, 0); in ubifs_update_one_lp()
718 if (IS_ERR(lp)) in ubifs_update_one_lp()
719 err = PTR_ERR(lp); in ubifs_update_one_lp()
739 int ubifs_read_one_lp(struct ubifs_info *c, int lnum, struct ubifs_lprops *lp) in ubifs_read_one_lp() argument
754 memcpy(lp, lpp, sizeof(struct ubifs_lprops)); in ubifs_read_one_lp()
974 struct ubifs_lprops *lp; in dbg_check_heap() local
985 lp = ubifs_lpt_lookup(c, lprops->lnum); in dbg_check_heap()
986 if (IS_ERR(lp)) { in dbg_check_heap()
990 if (lprops != lp) { in dbg_check_heap()
992 (size_t)lprops, (size_t)lp, lprops->lnum, in dbg_check_heap()
993 lp->lnum); in dbg_check_heap()
998 lp = heap->arr[j]; in dbg_check_heap()
999 if (lp == lprops) { in dbg_check_heap()
1003 if (lp->lnum == lprops->lnum) { in dbg_check_heap()
1030 const struct ubifs_lprops *lp, int in_tree, in scan_check_cb() argument
1035 int cat, lnum = lp->lnum, is_idx = 0, used = 0, free, dirty, ret; in scan_check_cb()
1038 cat = lp->flags & LPROPS_CAT_MASK; in scan_check_cb()
1040 cat = ubifs_categorize_lprops(c, lp); in scan_check_cb()
1041 if (cat != (lp->flags & LPROPS_CAT_MASK)) { in scan_check_cb()
1043 (lp->flags & LPROPS_CAT_MASK), cat); in scan_check_cb()
1071 if (lprops == lp) { in scan_check_cb()
1087 if ((lp->hpos != -1 && heap->arr[lp->hpos]->lnum != lnum) || in scan_check_cb()
1088 lp != heap->arr[lp->hpos]) { in scan_check_cb()
1102 if (lp->free == c->leb_size) { in scan_check_cb()
1108 if (lp->free + lp->dirty == c->leb_size && in scan_check_cb()
1109 !(lp->flags & LPROPS_INDEX)) { in scan_check_cb()
1110 lst->total_free += lp->free; in scan_check_cb()
1111 lst->total_dirty += lp->dirty; in scan_check_cb()
1167 if (lp->free + lp->dirty == c->leb_size && in scan_check_cb()
1169 if ((is_idx && !(lp->flags & LPROPS_INDEX)) || in scan_check_cb()
1171 lp->free == c->leb_size) { in scan_check_cb()
1179 free = lp->free; in scan_check_cb()
1180 dirty = lp->dirty; in scan_check_cb()
1184 if (is_idx && lp->free + lp->dirty == free + dirty && in scan_check_cb()
1197 free = lp->free; in scan_check_cb()
1198 dirty = lp->dirty; in scan_check_cb()
1201 if (lp->free != free || lp->dirty != dirty) in scan_check_cb()
1204 if (is_idx && !(lp->flags & LPROPS_INDEX)) { in scan_check_cb()
1214 if (!is_idx && (lp->flags & LPROPS_INDEX)) { in scan_check_cb()
1225 if (!(lp->flags & LPROPS_INDEX)) in scan_check_cb()
1230 if (!(lp->flags & LPROPS_INDEX)) { in scan_check_cb()
1245 lnum, lp->free, lp->dirty, lp->flags, free, dirty); in scan_check_cb()