mirror of
https://github.com/isar/libmdbx.git
synced 2025-08-24 21:34:28 +08:00
mdbx: fix cross-build & qemu-testing issues.
Change-Id: I6b2343cc4e08c3cb706a190c4c515965182733a2
This commit is contained in:
@@ -4814,7 +4814,7 @@ static int mdbx_page_flush(MDBX_txn *txn, pgno_t keep) {
|
||||
|
||||
#if MDBX_CPU_CACHE_MMAP_NONCOHERENT
|
||||
#if defined(__linux__) || defined(__gnu_linux__)
|
||||
if (linux_kernel_version >= 0x02060b00)
|
||||
if (mdbx_linux_kernel_version >= 0x02060b00)
|
||||
/* Linux kernels older than version 2.6.11 ignore the addr and nbytes
|
||||
* arguments, making this function fairly expensive. Therefore, the
|
||||
* whole cache is always flushed. */
|
||||
@@ -4839,7 +4839,7 @@ static int mdbx_page_flush(MDBX_txn *txn, pgno_t keep) {
|
||||
|
||||
#if MDBX_CPU_CACHE_MMAP_NONCOHERENT && \
|
||||
(defined(__linux__) || defined(__gnu_linux__))
|
||||
if (linux_kernel_version < 0x02060b00) {
|
||||
if (mdbx_linux_kernel_version < 0x02060b00) {
|
||||
/* Linux kernels older than version 2.6.11 ignore the addr and nbytes
|
||||
* arguments, making this function fairly expensive. Therefore, the whole
|
||||
* cache is always flushed. */
|
||||
|
@@ -174,7 +174,8 @@
|
||||
|
||||
#ifndef MDBX_USE_OFDLOCKS
|
||||
#define MDBX_USE_OFDLOCKS_CONFIG AUTO
|
||||
#if defined(F_OFD_SETLK) && defined(F_OFD_SETLKW) && defined(F_OFD_GETLK)
|
||||
#if defined(F_OFD_SETLK) && defined(F_OFD_SETLKW) && defined(F_OFD_GETLK) && \
|
||||
!defined(MDBX_SAFE4QEMU)
|
||||
#define MDBX_USE_OFDLOCKS 1
|
||||
#else
|
||||
#define MDBX_USE_OFDLOCKS 0
|
||||
|
Reference in New Issue
Block a user