Added a clause to call ibv_fork_init if tree is not initialized when calling ibv_reg_mr