1 | /* |
---|---|
2 | * pagesize.c - query the host about its page size |
3 | * |
4 | * Copyright (C) 2017, Emilio G. Cota <cota@braap.org> |
5 | * License: GNU GPL, version 2 or later. |
6 | * See the COPYING file in the top-level directory. |
7 | */ |
8 | |
9 | #include "qemu/osdep.h" |
10 | |
11 | uintptr_t qemu_real_host_page_size; |
12 | intptr_t qemu_real_host_page_mask; |
13 | |
14 | static void __attribute__((constructor)) init_real_host_page_size(void) |
15 | { |
16 | qemu_real_host_page_size = getpagesize(); |
17 | qemu_real_host_page_mask = -(intptr_t)qemu_real_host_page_size; |
18 | } |
19 |