diff mbox series

[v2,13/33] softmmu/physmem: Remove qemu_host_page_size

Message ID 20230901022331.115247-14-richard.henderson@linaro.org
State Superseded
Headers show
Series linux-user: Improve host and guest page size handling | expand

Commit Message

Richard Henderson Sept. 1, 2023, 2:23 a.m. UTC
Use qemu_real_host_page_size() instead.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
---
 softmmu/physmem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/softmmu/physmem.c b/softmmu/physmem.c
index 18277ddd67..6f963ea127 100644
--- a/softmmu/physmem.c
+++ b/softmmu/physmem.c
@@ -3472,7 +3472,7 @@  int ram_block_discard_range(RAMBlock *rb, uint64_t start, size_t length)
          *    fallocate works on hugepages and shmem
          *    shared anonymous memory requires madvise REMOVE
          */
-        need_madvise = (rb->page_size == qemu_host_page_size);
+        need_madvise = (rb->page_size == qemu_real_host_page_size());
         need_fallocate = rb->fd != -1;
         if (need_fallocate) {
             /* For a file, this causes the area of the file to be zero'd