qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 40/45] osdep: introduce qemu_mprotect_rwx/non


From: Richard Henderson
Subject: Re: [Qemu-devel] [PATCH v2 40/45] osdep: introduce qemu_mprotect_rwx/none
Date: Mon, 17 Jul 2017 18:26:09 -1000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.1

On 07/16/2017 10:04 AM, Emilio G. Cota wrote:
+static int qemu_mprotect__osdep(void *addr, size_t size, int prot)
+{
+    void *start = QEMU_ALIGN_PTR_DOWN(addr, qemu_real_host_page_size);
+    void *end = QEMU_ALIGN_PTR_UP(addr + size, qemu_real_host_page_size);

I'm not keen on this. Any good reason for it as opposed to asserting that the inputs are already page aligned?


r~



reply via email to

[Prev in Thread] Current Thread [Next in Thread]