From ecbb5cbc1b398cb3eadac63c5af3ea906413972c Mon Sep 17 00:00:00 2001 From: Jan Musial Date: Tue, 21 Jan 2020 13:37:06 +0100 Subject: [PATCH] Make RAM infinite in POSIX env Since the calculation that's being used right now isn't too acurate anyways, let's just get rid of it, maybe we'll find more memory-related bugs. Signed-off-by: Jan Musial --- env/posix/ocf_env.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/env/posix/ocf_env.h b/env/posix/ocf_env.h index dc4952b..d255174 100644 --- a/env/posix/ocf_env.h +++ b/env/posix/ocf_env.h @@ -180,7 +180,7 @@ static inline void env_secure_free(const void *ptr, size_t size) static inline uint64_t env_get_free_memory(void) { - return sysconf(_SC_PAGESIZE) * sysconf(_SC_AVPHYS_PAGES); + return (uint64_t)(-1); } /* ALLOCATOR */