Merge pull request #163 from robertbaldyga/put-queue-after-deallocating-req
Put queue after deallocating request
This commit is contained in:
commit
4216ff78f1
@ -263,12 +263,11 @@ void ocf_req_get(struct ocf_request *req)
|
||||
void ocf_req_put(struct ocf_request *req)
|
||||
{
|
||||
env_allocator *allocator;
|
||||
ocf_queue_t queue = req->io_queue;
|
||||
|
||||
if (env_atomic_dec_return(&req->ref_count))
|
||||
return;
|
||||
|
||||
ocf_queue_put(req->io_queue);
|
||||
|
||||
OCF_DEBUG_TRACE(req->cache);
|
||||
|
||||
if (!req->d2c && req->io_queue != req->cache->mngt_queue)
|
||||
@ -282,6 +281,8 @@ void ocf_req_put(struct ocf_request *req)
|
||||
env_free(req->map);
|
||||
env_allocator_del(_ocf_req_get_allocator_1(req->cache), req);
|
||||
}
|
||||
|
||||
ocf_queue_put(queue);
|
||||
}
|
||||
|
||||
void ocf_req_clear_info(struct ocf_request *req)
|
||||
|
Loading…
Reference in New Issue
Block a user