numam-spdk/lib/env_ocf
Vitaliy Mysak 33f97fa33a lib/ocf_env: fix incorrect value for free memory estimate
OCF relies on our env to get information about free memory.
It then uses that information to return a descriptive
error if not enough memory is available.
But no other calculation done based on that value.

Our implementation was not correct because it returned
the size of available physical memory in the system,
while we use HUGEPAGE memory for most of OCF operations.

There doesn't seem to be a reliant API for getting
the size of available HUGEPAGE memory, so instead
return UINT64_MAX, as it is done in ocf/env/posix/ocf_env.h.
This way, OCF will not know ahead of time if there
is enough memory available, but it will still fail
properly on operations that require too much memory.

Change-Id: Iec2e3cfa8453253513d5861d7e6acf0e08dad1e9
Signed-off-by: Vitaliy Mysak <vitaliy.mysak@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/1976
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Darek Stojaczyk <dariusz.stojaczyk@intel.com>
Reviewed-by: Tomasz Zawadzki <tomasz.zawadzki@intel.com>
2020-04-29 06:42:33 +00:00
..
.gitignore lib/mk: update OCF build. 2019-08-27 18:49:56 +00:00
Makefile lib/mk: update OCF build. 2019-08-27 18:49:56 +00:00
ocf_env_headers.h ocf: update ocf submodule to v20.3 2020-04-17 07:32:48 +00:00
ocf_env_list.h lib/mk: update OCF build. 2019-08-27 18:49:56 +00:00
ocf_env.c ocf: update ocf submodule to v20.3 2020-04-17 07:32:48 +00:00
ocf_env.h lib/ocf_env: fix incorrect value for free memory estimate 2020-04-29 06:42:33 +00:00