优化系统调用

This commit is contained in:
zhangzheng
2023-09-03 15:55:06 +08:00
parent a9969d7762
commit ad72f5e0da
28 changed files with 355 additions and 146 deletions

View File

@@ -16,6 +16,18 @@ bool_t obj_map_root(kobject_t *kobj, obj_space_t *obj_space, ram_limit_t *ram, o
slist_add(&kobj->mappable.node, &map->node);
return TRUE;
}
int obj_map_src_dst(obj_space_t *dst_space, obj_space_t *src_space,
obj_handler_t dst_inx, obj_handler_t src_inx,
ram_limit_t *ram)
{
kobject_t *source_kobj = obj_space_lookup_kobj(src_space, src_inx);
if (!source_kobj)
{
return -ENOENT;
}
return obj_map(dst_space, dst_inx, source_kobj, ram);
}
int obj_map(obj_space_t *obj_space, obj_handler_t inx, kobject_t *insert_kobj, ram_limit_t *ram)
{
obj_map_entry_t *entry = NULL;