Skip to content

Commit

Permalink
softmmu/physmem: Remove qemu_host_page_size
Browse files Browse the repository at this point in the history
Use qemu_real_host_page_size() instead.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Ilya Leoshkevich <iii@linux.ibm.com>
Acked-by: Helge Deller <deller@gmx.de>
Message-Id: <20240102015808.132373-14-richard.henderson@linaro.org>
  • Loading branch information
rth7680 committed Feb 22, 2024
1 parent 9f9fe60 commit 9ecacd2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion system/physmem.c
Original file line number Diff line number Diff line change
Expand Up @@ -3511,7 +3511,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
Expand Down

0 comments on commit 9ecacd2

Please sign in to comment.