Spdk/lib/bdev/ocf
Vitaliy Mysak c3d044cbd7 ocf: use vbdev_ocf_mngt_ interface in register path
This patch is a preparation for adopting ocf_cache_trylock() function.
Register OCF bdev path uses vbdev_ocf_mngt_ interface now
Register stays synchronous blocking operation in this patch,
 but with adoption of ocf_cache_trylock() function,
 register will be asynchronous, in which case we
 want to use mngt_ interface.

This series of OCF patches will enable WriteBack support for OCF bdev.
There is a lot of preparation before we will be able
 to actually implement WriteBack.
Dependencies look like this:
- WriteBack
  - Cleaner
    - trylock
  - Persistent metadata
    - asynchronous management API

Cleaner is a background agent that does synchronization
 of data between cache and its cores.
 Cleaner usually runs every ~30 seconds to perform cleaning.
 The synchronization is a simmilar operation to OCF management flushes.
We need cleaner for WriteBack because only WriteBack mode
 produces dirty data that cleaner needs to deal with.
Cleaner requires adopting trylock() because in current version
 cleaner uses management lock when performs cleaning,
 which may lead to deadlocks if cleaner runs on
 the same thread as management operations.

Peristent metadata is functionality of OCF
 that allows to restore cache state after shutdown
We need persistent metadata in context of shutdown
 with some data being dirty which may only happen
 when using WriteBack mode
Support for persistent metadata requieres
 asynchronous OCF API because in current version
 we will have a deadlock during metadata initialization
 because it is required to be done on different thread
 than cache initialization.

Change-Id: I45d84a5fa0c96581d522050dad186b06d489226e
Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/455225
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
2019-05-22 17:57:31 +00:00
..
env Makefile: Add possibility to uninstall spdk. 2019-05-16 20:56:18 +00:00
ctx.c ocf: switch to spdk_*malloc(). 2019-04-09 06:30:42 +00:00
ctx.h OCF: rebase to ocf master 276d91fcd7 2019-03-05 12:09:25 +00:00
data.c OCF: add OCF module 2019-01-28 09:41:52 +00:00
data.h OCF: add OCF module 2019-01-28 09:41:52 +00:00
Makefile OCF: add OCF module 2019-01-28 09:41:52 +00:00
stats.c OCF: rebase to ocf master 276d91fcd7 2019-03-05 12:09:25 +00:00
stats.h OCF: rebase to ocf master 276d91fcd7 2019-03-05 12:09:25 +00:00
utils.c ocf: add timeout functionality for vbdev_ocf_mngt_ interface 2019-05-15 20:34:13 +00:00
utils.h ocf: add timeout functionality for vbdev_ocf_mngt_ interface 2019-05-15 20:34:13 +00:00
vbdev_ocf_rpc.c ocf: add callback argument to vbdev_ocf_construct() 2019-05-01 17:44:03 +00:00
vbdev_ocf.c ocf: use vbdev_ocf_mngt_ interface in register path 2019-05-22 17:57:31 +00:00
vbdev_ocf.h ocf: add timeout functionality for vbdev_ocf_mngt_ interface 2019-05-15 20:34:13 +00:00
volume.c ocf: switch to dynamic queues 2019-03-12 22:21:58 +00:00
volume.h OCF: rebase to ocf master 276d91fcd7 2019-03-05 12:09:25 +00:00