From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=44788 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pv2Gp-00080K-Bs for qemu-devel@nongnu.org; Thu, 03 Mar 2011 01:44:20 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pv2Go-0004y7-5B for qemu-devel@nongnu.org; Thu, 03 Mar 2011 01:44:19 -0500 Received: from [222.73.24.84] (port=60713 helo=song.cn.fujitsu.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pv2Gn-0004xX-TP for qemu-devel@nongnu.org; Thu, 03 Mar 2011 01:44:18 -0500 Message-ID: <4D6F386D.60002@cn.fujitsu.com> Date: Thu, 03 Mar 2011 14:42:53 +0800 From: Wen Congyang MIME-Version: 1.0 References: <4D6DBDA4.3050909@cn.fujitsu.com> <4D6F008E.7050308@cn.fujitsu.com> In-Reply-To: Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=UTF-8 Subject: [Qemu-devel] Re: [PATCH 3/3] correct VNC_DIRTY_WORDS on 64 bit machine List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Corentin Chary Cc: Anthony Liguori , qemu-devel At 03/03/2011 02:41 PM, Corentin Chary Write: > On Thu, Mar 3, 2011 at 3:44 AM, Wen Congyang wrote: >> VNC_DIRTY_WORDS is wrong on 64 bit long machine. >> >> Signed-off-by: Wen Congyang >> >> --- >> ui/vnc.h | 3 ++- >> 1 files changed, 2 insertions(+), 1 deletions(-) >> >> diff --git a/ui/vnc.h b/ui/vnc.h >> index 8a1e7b9..239a7a7 100644 >> --- a/ui/vnc.h >> +++ b/ui/vnc.h >> @@ -81,7 +81,8 @@ typedef void VncSendHextileTile(VncState *vs, >> >> #define VNC_MAX_WIDTH 2560 >> #define VNC_MAX_HEIGHT 2048 >> -#define VNC_DIRTY_WORDS (VNC_MAX_WIDTH / (16 * BITS_PER_LONG)) >> +#define divideup(x, y) (((x) + ((y) - 1)) / (y)) > > osdep.h:#define DIV_ROUND_UP(n,d) (((n) + (d) - 1) / (d)) Thank you for pointing out it. I will update my patch. > >