Lines Matching refs:ubifs_info

645 struct ubifs_info;
648 typedef int (*ubifs_lpt_scan_callback)(struct ubifs_info *c,
684 struct ubifs_info *c;
692 int (*sync_callback)(struct ubifs_info *c, int lnum, int free, int pad);
1231 struct ubifs_info { struct
1475 void ubifs_ro_mode(struct ubifs_info *c, int err); argument
1476 int ubifs_leb_read(const struct ubifs_info *c, int lnum, void *buf, int offs,
1478 int ubifs_leb_write(struct ubifs_info *c, int lnum, const void *buf, int offs,
1480 int ubifs_leb_change(struct ubifs_info *c, int lnum, const void *buf, int len);
1481 int ubifs_leb_unmap(struct ubifs_info *c, int lnum);
1482 int ubifs_leb_map(struct ubifs_info *c, int lnum);
1483 int ubifs_is_mapped(const struct ubifs_info *c, int lnum);
1486 int ubifs_wbuf_init(struct ubifs_info *c, struct ubifs_wbuf *wbuf);
1487 int ubifs_read_node(const struct ubifs_info *c, void *buf, int type, int len,
1491 int ubifs_write_node(struct ubifs_info *c, void *node, int len, int lnum,
1493 int ubifs_check_node(const struct ubifs_info *c, const void *buf, int lnum,
1495 void ubifs_prepare_node(struct ubifs_info *c, void *buf, int len, int pad);
1496 void ubifs_prep_grp_node(struct ubifs_info *c, void *node, int len, int last);
1497 int ubifs_io_init(struct ubifs_info *c);
1498 void ubifs_pad(const struct ubifs_info *c, void *buf, int pad);
1500 int ubifs_bg_wbufs_sync(struct ubifs_info *c);
1502 int ubifs_sync_wbufs_by_inode(struct ubifs_info *c, struct inode *inode);
1505 struct ubifs_scan_leb *ubifs_scan(const struct ubifs_info *c, int lnum,
1508 int ubifs_scan_a_node(const struct ubifs_info *c, void *buf, int len, int lnum,
1510 struct ubifs_scan_leb *ubifs_start_scan(const struct ubifs_info *c, int lnum,
1512 void ubifs_end_scan(const struct ubifs_info *c, struct ubifs_scan_leb *sleb,
1514 int ubifs_add_snod(const struct ubifs_info *c, struct ubifs_scan_leb *sleb,
1516 void ubifs_scanned_corruption(const struct ubifs_info *c, int lnum, int offs,
1520 void ubifs_add_bud(struct ubifs_info *c, struct ubifs_bud *bud);
1521 void ubifs_create_buds_lists(struct ubifs_info *c);
1522 int ubifs_add_bud_to_log(struct ubifs_info *c, int jhead, int lnum, int offs);
1523 struct ubifs_bud *ubifs_search_bud(struct ubifs_info *c, int lnum);
1524 struct ubifs_wbuf *ubifs_get_wbuf(struct ubifs_info *c, int lnum);
1525 int ubifs_log_start_commit(struct ubifs_info *c, int *ltail_lnum);
1526 int ubifs_log_end_commit(struct ubifs_info *c, int new_ltail_lnum);
1527 int ubifs_log_post_commit(struct ubifs_info *c, int old_ltail_lnum);
1528 int ubifs_consolidate_log(struct ubifs_info *c);
1531 int ubifs_jnl_update(struct ubifs_info *c, const struct inode *dir,
1534 int ubifs_jnl_write_data(struct ubifs_info *c, const struct inode *inode,
1536 int ubifs_jnl_write_inode(struct ubifs_info *c, const struct inode *inode);
1537 int ubifs_jnl_delete_inode(struct ubifs_info *c, const struct inode *inode);
1538 int ubifs_jnl_xrename(struct ubifs_info *c, const struct inode *fst_dir,
1544 int ubifs_jnl_rename(struct ubifs_info *c, const struct inode *old_dir,
1551 int ubifs_jnl_truncate(struct ubifs_info *c, const struct inode *inode,
1553 int ubifs_jnl_delete_xattr(struct ubifs_info *c, const struct inode *host,
1555 int ubifs_jnl_change_xattr(struct ubifs_info *c, const struct inode *inode1,
1559 int ubifs_budget_space(struct ubifs_info *c, struct ubifs_budget_req *req);
1560 void ubifs_release_budget(struct ubifs_info *c, struct ubifs_budget_req *req);
1561 void ubifs_release_dirty_inode_budget(struct ubifs_info *c,
1563 int ubifs_budget_inode_op(struct ubifs_info *c, struct inode *inode,
1565 void ubifs_release_ino_dirty(struct ubifs_info *c, struct inode *inode,
1567 void ubifs_cancel_ino_op(struct ubifs_info *c, struct inode *inode,
1569 long long ubifs_get_free_space(struct ubifs_info *c);
1570 long long ubifs_get_free_space_nolock(struct ubifs_info *c);
1571 int ubifs_calc_min_idx_lebs(struct ubifs_info *c);
1572 void ubifs_convert_page_budget(struct ubifs_info *c);
1573 long long ubifs_reported_space(const struct ubifs_info *c, long long free);
1574 long long ubifs_calc_available(const struct ubifs_info *c, int min_idx_lebs);
1577 int ubifs_find_free_space(struct ubifs_info *c, int min_space, int *offs,
1579 int ubifs_find_free_leb_for_idx(struct ubifs_info *c);
1580 int ubifs_find_dirty_leb(struct ubifs_info *c, struct ubifs_lprops *ret_lp,
1582 int ubifs_find_dirty_idx_leb(struct ubifs_info *c);
1583 int ubifs_save_dirty_idx_lnums(struct ubifs_info *c);
1586 int ubifs_lookup_level0(struct ubifs_info *c, const union ubifs_key *key,
1588 int ubifs_tnc_lookup_nm(struct ubifs_info *c, const union ubifs_key *key,
1590 int ubifs_tnc_lookup_dh(struct ubifs_info *c, const union ubifs_key *key,
1592 int ubifs_tnc_locate(struct ubifs_info *c, const union ubifs_key *key,
1594 int ubifs_tnc_add(struct ubifs_info *c, const union ubifs_key *key, int lnum,
1596 int ubifs_tnc_replace(struct ubifs_info *c, const union ubifs_key *key,
1598 int ubifs_tnc_add_nm(struct ubifs_info *c, const union ubifs_key *key,
1600 int ubifs_tnc_remove(struct ubifs_info *c, const union ubifs_key *key);
1601 int ubifs_tnc_remove_nm(struct ubifs_info *c, const union ubifs_key *key,
1603 int ubifs_tnc_remove_dh(struct ubifs_info *c, const union ubifs_key *key,
1605 int ubifs_tnc_remove_range(struct ubifs_info *c, union ubifs_key *from_key,
1607 int ubifs_tnc_remove_ino(struct ubifs_info *c, ino_t inum);
1608 struct ubifs_dent_node *ubifs_tnc_next_ent(struct ubifs_info *c,
1611 void ubifs_tnc_close(struct ubifs_info *c);
1612 int ubifs_tnc_has_node(struct ubifs_info *c, union ubifs_key *key, int level,
1614 int ubifs_dirty_idx_node(struct ubifs_info *c, union ubifs_key *key, int level,
1617 void destroy_old_idx(struct ubifs_info *c);
1618 int is_idx_node_in_tnc(struct ubifs_info *c, union ubifs_key *key, int level,
1620 int insert_old_idx_znode(struct ubifs_info *c, struct ubifs_znode *znode);
1621 int ubifs_tnc_get_bu_keys(struct ubifs_info *c, struct bu_info *bu);
1622 int ubifs_tnc_bulk_read(struct ubifs_info *c, struct bu_info *bu);
1625 struct ubifs_znode *ubifs_tnc_levelorder_next(const struct ubifs_info *c,
1628 int ubifs_search_zbranch(const struct ubifs_info *c,
1632 struct ubifs_znode *ubifs_tnc_postorder_next(const struct ubifs_info *c,
1634 long ubifs_destroy_tnc_subtree(const struct ubifs_info *c,
1636 struct ubifs_znode *ubifs_load_znode(struct ubifs_info *c,
1639 int ubifs_tnc_read_node(struct ubifs_info *c, struct ubifs_zbranch *zbr,
1643 int ubifs_tnc_start_commit(struct ubifs_info *c, struct ubifs_zbranch *zroot);
1644 int ubifs_tnc_end_commit(struct ubifs_info *c);
1654 void ubifs_commit_required(struct ubifs_info *c);
1655 void ubifs_request_bg_commit(struct ubifs_info *c);
1656 int ubifs_run_commit(struct ubifs_info *c);
1657 void ubifs_recovery_commit(struct ubifs_info *c);
1658 int ubifs_gc_should_commit(struct ubifs_info *c);
1659 void ubifs_wait_for_commit(struct ubifs_info *c);
1662 int ubifs_read_master(struct ubifs_info *c);
1663 int ubifs_write_master(struct ubifs_info *c);
1666 int ubifs_read_superblock(struct ubifs_info *c);
1667 struct ubifs_sb_node *ubifs_read_sb_node(struct ubifs_info *c);
1668 int ubifs_write_sb_node(struct ubifs_info *c, struct ubifs_sb_node *sup);
1669 int ubifs_fixup_free_space(struct ubifs_info *c);
1670 int ubifs_enable_encryption(struct ubifs_info *c);
1673 int ubifs_validate_entry(struct ubifs_info *c,
1675 int ubifs_replay_journal(struct ubifs_info *c);
1678 int ubifs_garbage_collect(struct ubifs_info *c, int anyway);
1679 int ubifs_gc_start_commit(struct ubifs_info *c);
1680 int ubifs_gc_end_commit(struct ubifs_info *c);
1681 void ubifs_destroy_idx_gc(struct ubifs_info *c);
1682 int ubifs_get_idx_gc_leb(struct ubifs_info *c);
1683 int ubifs_garbage_collect_leb(struct ubifs_info *c, struct ubifs_lprops *lp);
1686 int ubifs_add_orphan(struct ubifs_info *c, ino_t inum);
1687 void ubifs_delete_orphan(struct ubifs_info *c, ino_t inum);
1688 int ubifs_orphan_start_commit(struct ubifs_info *c);
1689 int ubifs_orphan_end_commit(struct ubifs_info *c);
1690 int ubifs_mount_orphans(struct ubifs_info *c, int unclean, int read_only);
1691 int ubifs_clear_orphans(struct ubifs_info *c);
1694 int ubifs_calc_lpt_geom(struct ubifs_info *c);
1695 int ubifs_create_dflt_lpt(struct ubifs_info *c, int *main_lebs, int lpt_first,
1697 int ubifs_lpt_init(struct ubifs_info *c, int rd, int wr);
1698 struct ubifs_lprops *ubifs_lpt_lookup(struct ubifs_info *c, int lnum);
1699 struct ubifs_lprops *ubifs_lpt_lookup_dirty(struct ubifs_info *c, int lnum);
1700 int ubifs_lpt_scan_nolock(struct ubifs_info *c, int start_lnum, int end_lnum,
1704 void ubifs_pack_lsave(struct ubifs_info *c, void *buf, int *lsave);
1705 void ubifs_pack_ltab(struct ubifs_info *c, void *buf,
1707 void ubifs_pack_pnode(struct ubifs_info *c, void *buf,
1709 void ubifs_pack_nnode(struct ubifs_info *c, void *buf,
1711 struct ubifs_pnode *ubifs_get_pnode(struct ubifs_info *c,
1713 struct ubifs_nnode *ubifs_get_nnode(struct ubifs_info *c,
1715 int ubifs_read_nnode(struct ubifs_info *c, struct ubifs_nnode *parent, int iip);
1716 void ubifs_add_lpt_dirt(struct ubifs_info *c, int lnum, int dirty);
1717 void ubifs_add_nnode_dirt(struct ubifs_info *c, struct ubifs_nnode *nnode);
1718 uint32_t ubifs_unpack_bits(const struct ubifs_info *c, uint8_t **addr, int *pos, int nrbits);
1719 struct ubifs_nnode *ubifs_first_nnode(struct ubifs_info *c, int *hght);
1721 int ubifs_unpack_nnode(const struct ubifs_info *c, void *buf,
1725 int ubifs_lpt_start_commit(struct ubifs_info *c);
1726 int ubifs_lpt_end_commit(struct ubifs_info *c);
1727 int ubifs_lpt_post_commit(struct ubifs_info *c);
1728 void ubifs_lpt_free(struct ubifs_info *c, int wr_only);
1731 const struct ubifs_lprops *ubifs_change_lp(struct ubifs_info *c,
1735 void ubifs_get_lp_stats(struct ubifs_info *c, struct ubifs_lp_stats *lst);
1736 void ubifs_add_to_cat(struct ubifs_info *c, struct ubifs_lprops *lprops,
1738 void ubifs_replace_cat(struct ubifs_info *c, struct ubifs_lprops *old_lprops,
1740 void ubifs_ensure_cat(struct ubifs_info *c, struct ubifs_lprops *lprops);
1741 int ubifs_categorize_lprops(const struct ubifs_info *c,
1743 int ubifs_change_one_lp(struct ubifs_info *c, int lnum, int free, int dirty,
1745 int ubifs_update_one_lp(struct ubifs_info *c, int lnum, int free, int dirty,
1747 int ubifs_read_one_lp(struct ubifs_info *c, int lnum, struct ubifs_lprops *lp);
1748 const struct ubifs_lprops *ubifs_fast_find_free(struct ubifs_info *c);
1749 const struct ubifs_lprops *ubifs_fast_find_empty(struct ubifs_info *c);
1750 const struct ubifs_lprops *ubifs_fast_find_freeable(struct ubifs_info *c);
1751 const struct ubifs_lprops *ubifs_fast_find_frdi_idx(struct ubifs_info *c);
1752 int ubifs_calc_dark(const struct ubifs_info *c, int spc);
1762 struct inode *ubifs_new_inode(struct ubifs_info *c, struct inode *dir,
1777 void ubifs_evict_xattr_inode(struct ubifs_info *c, ino_t xattr_inum);
1779 static inline void ubifs_evict_xattr_inode(struct ubifs_info *c, in ubifs_evict_xattr_inode()
1799 int ubifs_recover_master_node(struct ubifs_info *c);
1800 int ubifs_write_rcvrd_mst_node(struct ubifs_info *c);
1801 struct ubifs_scan_leb *ubifs_recover_leb(struct ubifs_info *c, int lnum,
1803 struct ubifs_scan_leb *ubifs_recover_log_leb(struct ubifs_info *c, int lnum,
1805 int ubifs_recover_inl_heads(struct ubifs_info *c, void *sbuf);
1806 int ubifs_clean_lebs(struct ubifs_info *c, void *sbuf);
1807 int ubifs_rcvry_gc_commit(struct ubifs_info *c);
1808 int ubifs_recover_size_accum(struct ubifs_info *c, union ubifs_key *key,
1810 int ubifs_recover_size(struct ubifs_info *c);
1811 void ubifs_destroy_size_tree(struct ubifs_info *c);
1823 void ubifs_compress(const struct ubifs_info *c, const void *in_buf, int in_len,
1825 int ubifs_decompress(const struct ubifs_info *c, const void *buf, int len,
1838 struct ubifs_info *c = inode->i_sb->s_fs_info; in ubifs_encrypt()
1846 struct ubifs_info *c = inode->i_sb->s_fs_info; in ubifs_decrypt()
1869 void ubifs_msg(const struct ubifs_info *c, const char *fmt, ...);
1871 void ubifs_err(const struct ubifs_info *c, const char *fmt, ...);
1873 void ubifs_warn(const struct ubifs_info *c, const char *fmt, ...);