- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Looks like CentOS 8 backported mainline commit ca79b0c211af ("mm: convert totalram_pages and totalhigh_pages variables to atomic") so that totalram_pages is a function even if kernel version is lower than 5.0. You might try changing the version check at the beginning of HostIF_EstimateLockedPageLimit() to something like
#if (LINUX_VERSION_CODE < KERNEL_VERSION(5, 0, 0)) && \
!(defined(RHEL_RELEASE_CODE) && \
(RHEL_RELEASE_CODE >= RHEL_RELEASE_VERSION(8, 0)))
extern unsigned long totalram_pages;
PageCnt totalPhysicalPages = totalram_pages;
#else
PageCnt totalPhysicalPages = totalram_pages();
#endif