Remove unused core_io_allocator
Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
This commit is contained in:
parent
ab2fc6d3c3
commit
57bc19103d
@ -30,7 +30,6 @@ struct ocf_ctx {
|
||||
|
||||
struct {
|
||||
struct ocf_req_allocator *req;
|
||||
env_allocator *core_io_allocator;
|
||||
} resources;
|
||||
};
|
||||
|
||||
|
@ -11,33 +11,10 @@
|
||||
|
||||
int ocf_utils_init(struct ocf_ctx *ocf_ctx)
|
||||
{
|
||||
int result;
|
||||
|
||||
result = ocf_req_allocator_init(ocf_ctx);
|
||||
if (result)
|
||||
goto ocf_utils_init_ERROR;
|
||||
|
||||
ocf_ctx->resources.core_io_allocator =
|
||||
env_allocator_create(sizeof(struct ocf_core_io),
|
||||
"ocf_io");
|
||||
if (!ocf_ctx->resources.core_io_allocator)
|
||||
goto ocf_utils_init_ERROR;
|
||||
|
||||
return 0;
|
||||
|
||||
ocf_utils_init_ERROR:
|
||||
|
||||
ocf_utils_deinit(ocf_ctx);
|
||||
|
||||
return -1;
|
||||
return ocf_req_allocator_init(ocf_ctx);
|
||||
}
|
||||
|
||||
void ocf_utils_deinit(struct ocf_ctx *ocf_ctx)
|
||||
{
|
||||
ocf_req_allocator_deinit(ocf_ctx);
|
||||
|
||||
if (ocf_ctx->resources.core_io_allocator) {
|
||||
env_allocator_destroy(ocf_ctx->resources.core_io_allocator);
|
||||
ocf_ctx->resources.core_io_allocator = NULL;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user