Merge pull request #33 from micrakow/master

Added sample env files and makefile to be used by functional tests
This commit is contained in:
Michał Mielewczyk
2019-01-08 13:32:17 +01:00
committed by GitHub
7 changed files with 1046 additions and 4 deletions

View File

@@ -82,16 +82,16 @@ void ocf_io_get(struct ocf_io *io)
{
struct ocf_io_meta *io_meta = ocf_io_get_meta(io);
atomic_inc_return(&io_meta->ref_count);
env_atomic_inc_return(&io_meta->ref_count);
}
void ocf_io_put(struct ocf_io *io)
{
struct ocf_io_meta *io_meta = ocf_io_get_meta(io);
if (atomic_dec_return(&io_meta->ref_count))
if (env_atomic_dec_return(&io_meta->ref_count))
return;
env_allocator_del(io->obj->type->allocator,
(void *)io - sizeof(struct ocf_io_meta));
}