From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:45942) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ROhhY-0002Ej-Jz for qemu-devel@nongnu.org; Thu, 10 Nov 2011 22:22:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ROhhX-00010O-GT for qemu-devel@nongnu.org; Thu, 10 Nov 2011 22:22:48 -0500 Received: from [222.73.24.84] (port=60376 helo=song.cn.fujitsu.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ROhhW-00010A-UZ for qemu-devel@nongnu.org; Thu, 10 Nov 2011 22:22:47 -0500 Received: from tang.cn.fujitsu.com (tang.cn.fujitsu.com [10.167.250.3]) by song.cn.fujitsu.com (Postfix) with ESMTP id BB8F417012F for ; Fri, 11 Nov 2011 11:22:36 +0800 (CST) Received: from mailserver.fnst.cn.fujitsu.com (tang.cn.fujitsu.com [127.0.0.1]) by tang.cn.fujitsu.com (8.14.3/8.13.1) with ESMTP id pAB3MZoX001981 for ; Fri, 11 Nov 2011 11:22:35 +0800 Message-ID: <4EBC954D.1050808@cn.fujitsu.com> Date: Fri, 11 Nov 2011 11:23:57 +0800 From: Wen Congyang MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=ISO-8859-1 Subject: [Qemu-devel] Question about cpu_get_phys_page_debug() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel In the function cpu_get_phys_page_debug()(In the file target-i386/helper.c): I find the following codes: ==================== page_offset = (addr & TARGET_PAGE_MASK) & (page_size - 1); paddr = (pte & TARGET_PAGE_MASK) + page_offset; ==================== The page_offset is always 4K aligned. I think the offset should be the offset in the page, so it should not be aligned. Who can tell me the reason? Thanks Wen Congyang