Introduce ocf_cache_is_passive()

Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
This commit is contained in:
Robert Baldyga
2021-08-31 10:20:52 +02:00
parent c662649f31
commit f96451a698
2 changed files with 16 additions and 0 deletions

View File

@@ -56,6 +56,12 @@ bool ocf_cache_is_running(ocf_cache_t cache)
return env_bit_test(ocf_cache_state_running, &cache->cache_state);
}
bool ocf_cache_is_passive(ocf_cache_t cache)
{
OCF_CHECK_NULL(cache);
return env_bit_test(ocf_cache_state_passive, &cache->cache_state);
}
bool ocf_cache_is_device_attached(ocf_cache_t cache)
{
OCF_CHECK_NULL(cache);