From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KzaVI-0000E8-02 for qemu-devel@nongnu.org; Mon, 10 Nov 2008 12:24:44 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KzaVD-0000CS-QG for qemu-devel@nongnu.org; Mon, 10 Nov 2008 12:24:40 -0500 Received: from [199.232.76.173] (port=41877 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KzaVD-0000CM-4a for qemu-devel@nongnu.org; Mon, 10 Nov 2008 12:24:39 -0500 Received: from yw-out-1718.google.com ([74.125.46.157]:57010) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KzaVC-0004jX-TX for qemu-devel@nongnu.org; Mon, 10 Nov 2008 12:24:39 -0500 Received: by yw-out-1718.google.com with SMTP id 6so878831ywa.82 for ; Mon, 10 Nov 2008 09:24:37 -0800 (PST) Message-ID: <49186E51.4030307@codemonkey.ws> Date: Mon, 10 Nov 2008 11:24:33 -0600 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH] Introduce kvm logging interface. References: <1226342253-8887-1-git-send-email-glommer@redhat.com> <1226342253-8887-2-git-send-email-glommer@redhat.com> <1226342253-8887-3-git-send-email-glommer@redhat.com> <1226342253-8887-4-git-send-email-glommer@redhat.com> In-Reply-To: <1226342253-8887-4-git-send-email-glommer@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Glauber Costa wrote: > Introduce functions to stop and start logging of memory regions. > We select region based on its start address. > > Signed-off-by: Glauber Costa > --- > > +/* find the slot correspondence using userspace_addr as a key */ > +static KVMSlot *kvm_lookup_slot_uaddr(KVMState *s, ram_addr_t addr) > +{ > + int i; > + > + uint64_t uaddr = (uint64_t)kvm_uaddr(addr); > warning: cast from pointer to integer of different size (64-bit host, pointer is unsigned long, uint64_t is unsigned long long). > + nr = (uint32_t)((uint64_t)kvm_uaddr(addr) - mem->userspace_addr) >> TARGET_PAGE_BITS; > warning: cast from pointer to integer of different size Regards, Anthony Liguori