Lines Matching full:tree
2 * vhost software live migration iova tree
11 #include "qemu/iova-tree.h"
12 #include "vhost-iova-tree.h"
34 * Create a new IOVA tree
36 * Returns the new IOVA tree
40 VhostIOVATree *tree = g_new(VhostIOVATree, 1); in vhost_iova_tree_new() local
43 tree->iova_first = MAX(iova_first, iova_min_addr); in vhost_iova_tree_new()
44 tree->iova_last = iova_last; in vhost_iova_tree_new()
46 tree->iova_taddr_map = iova_tree_new(); in vhost_iova_tree_new()
47 return tree; in vhost_iova_tree_new()
51 * Delete an iova tree
62 * @tree: The iova tree
67 const DMAMap *vhost_iova_tree_find_iova(const VhostIOVATree *tree, in vhost_iova_tree_find_iova() argument
70 return iova_tree_find_iova(tree->iova_taddr_map, map); in vhost_iova_tree_find_iova()
76 * @tree: The iova tree
82 * - IOVA_ERR_NOMEM if tree cannot allocate more space.
86 int vhost_iova_tree_map_alloc(VhostIOVATree *tree, DMAMap *map) in vhost_iova_tree_map_alloc() argument
89 hwaddr iova_first = tree->iova_first ?: qemu_real_host_page_size(); in vhost_iova_tree_map_alloc()
97 return iova_tree_alloc_map(tree->iova_taddr_map, map, iova_first, in vhost_iova_tree_map_alloc()
98 tree->iova_last); in vhost_iova_tree_map_alloc()
102 * Remove existing mappings from iova tree
104 * @iova_tree: The vhost iova tree