Lines Matching full:tree
2 * An very simplified iova tree implementation based on GTree.
15 * Currently the iova tree will only allow to keep ranges
18 * tree. It can save a lot of memory when the ranges are split but
22 * protections. Callers of the iova tree should be responsible
46 * Create a new GPA->IOVA tree.
48 * Returns: the tree point on success, or NULL otherwise.
55 * @tree: The GPA->IOVA tree we're inserting the mapping to
58 * Inserts a GPA range to the GPA->IOVA tree. If there are overlapped
63 int gpa_tree_insert(IOVATree *tree, const DMAMap *map);
68 * Create a new iova tree.
70 * Returns: the tree pointer when succeeded, or NULL if error.
77 * @tree: the iova tree to insert
80 * Insert an iova range to the tree. If there is overlapped
85 int iova_tree_insert(IOVATree *tree, const DMAMap *map);
90 * @tree: the iova tree to remove range from
93 * Remove mappings from the tree that are covered by the map range
96 * removed from the tree. Here map->translated_addr is meaningless.
98 void iova_tree_remove(IOVATree *tree, DMAMap map);
103 * @tree: the iova tree to search from
106 * Search for a mapping in the iova tree that iova overlaps with the
116 const DMAMap *iova_tree_find(const IOVATree *tree, const DMAMap *map);
121 * @tree: the iova tree to search from
124 * Search for a mapping in the iova tree that translated_addr overlaps with the
134 const DMAMap *iova_tree_find_iova(const IOVATree *tree, const DMAMap *map);
139 * @tree: the iova tree to allocate from
147 * iova tree is out of free contiguous range. The caller gets the assigned iova
150 int iova_tree_alloc_map(IOVATree *tree, DMAMap *map, hwaddr iova_begin,
156 * @tree: the iova tree to destroy
158 * Destroy an existing iova tree.
162 void iova_tree_destroy(IOVATree *tree);