diff options
Diffstat (limited to 'migration')
-rw-r--r-- | migration/ram.c | 2 | ||||
-rw-r--r-- | migration/rdma.c | 5 |
2 files changed, 2 insertions, 5 deletions
diff --git a/migration/ram.c b/migration/ram.c index a3d70c4c62..a6e1c63a08 100644 --- a/migration/ram.c +++ b/migration/ram.c @@ -73,7 +73,7 @@ static const uint8_t ZERO_TARGET_PAGE[TARGET_PAGE_SIZE]; static inline bool is_zero_range(uint8_t *p, uint64_t size) { - return buffer_find_nonzero_offset(p, size) == size; + return buffer_is_zero(p, size); } /* struct contains XBZRLE cache and a static page diff --git a/migration/rdma.c b/migration/rdma.c index 5110ec828d..88bdb64457 100644 --- a/migration/rdma.c +++ b/migration/rdma.c @@ -1934,10 +1934,7 @@ retry: * memset() + madvise() the entire chunk without RDMA. */ - if (can_use_buffer_find_nonzero_offset((void *)(uintptr_t)sge.addr, - length) - && buffer_find_nonzero_offset((void *)(uintptr_t)sge.addr, - length) == length) { + if (buffer_is_zero((void *)(uintptr_t)sge.addr, length)) { RDMACompress comp = { .offset = current_addr, .value = 0, |