Spdk/lib/bdev/ocf
Vitaliy Mysak 80a2ff01f3 ocf: implement OCF cleaner
Implement cleaner that is used in WriteBack mode.

Cleaner is a background agent that does synchronization
 of data between cache and its cores.
 Cleaner usually runs every ~20 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.

WriteBack mode is fully functional after this change,
  but persistent metadata support is required to use it for production.

Cleaner will run on management thread for now.
  We plan to implement functionality of
  chosing a CPU core where cleaner should run.
Cleaning policy is not configurable yet.
  The default is ALRU with 20 sec interval.

Change-Id: I35aa7e00c44e0d7a77e64e60df1f66f20be03f55
Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/448537
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Jim Harris <james.r.harris@intel.com>
2019-05-23 19:01:38 +00:00
..
env Makefile: Add possibility to uninstall spdk. 2019-05-16 20:56:18 +00:00
ctx.c ocf: implement OCF cleaner 2019-05-23 19:01:38 +00:00
ctx.h ocf: implement OCF cleaner 2019-05-23 19:01:38 +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: create management channel 2019-05-23 19:01:38 +00:00
vbdev_ocf.h ocf: create management channel 2019-05-23 19:01:38 +00:00
volume.c ocf: implement OCF cleaner 2019-05-23 19:01:38 +00:00
volume.h OCF: rebase to ocf master 276d91fcd7 2019-03-05 12:09:25 +00:00