void oc_bpt_test_utl_init(void) { oc_bpt_test_utl_setup_wu(&utl_wu, &utl_rm_ticket); if (utl_wu.po_id != 0) ERR(("the initial po_id has to be zero")); pl_utl_set_hns(); vd_create(); oc_bpt_init(); oc_bpt_test_fs_create("BPT free-space", 10000, FALSE); // setup memset(&cfg, 0, sizeof(cfg)); cfg.key_size = sizeof(Oc_bpt_test_key); cfg.data_size = sizeof(Oc_bpt_test_data); cfg.node_size = NODE_SIZE; cfg.root_fanout = param->max_root_fanout; cfg.non_root_fanout = param->max_non_root_fanout; cfg.min_num_ent = param->min_fanout; cfg.node_alloc = node_alloc; cfg.node_dealloc = node_dealloc; cfg.node_get_sl = node_get_sl; cfg.node_get_xl = node_get_xl; cfg.fs_inc_refcount = oc_bpt_test_fs_inc_refcount; cfg.fs_get_refcount = oc_bpt_test_fs_get_refcount; cfg.node_release = node_release; cfg.node_mark_dirty = node_mark_dirty; cfg.key_compare = key_compare; cfg.key_inc = key_inc; cfg.key_to_string = key_to_string; cfg.data_release = data_release; cfg.data_to_string = data_to_string; memset(&alt_cfg, 0, sizeof(alt_cfg)); alt_cfg.key_size = sizeof(Oc_bpt_test_key); alt_cfg.data_size = sizeof(Oc_bpt_test_data); alt_cfg.key_compare = key_compare; alt_cfg.key_inc = key_inc; alt_cfg.key_to_string = key_to_string; alt_cfg.data_release = data_release; alt_cfg.data_to_string = data_to_string; oc_bpt_init_config(&cfg); }
void oc_xt_test_nd_init(void) { vd_create(); }