From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44296) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMHVg-0008LT-P2 for qemu-devel@nongnu.org; Mon, 03 Aug 2015 11:18:41 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZMHVd-0005rn-CP for qemu-devel@nongnu.org; Mon, 03 Aug 2015 11:18:40 -0400 Received: from mx1.redhat.com ([209.132.183.28]:47319) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZMHVd-0005rh-7I for qemu-devel@nongnu.org; Mon, 03 Aug 2015 11:18:37 -0400 References: <1438609948-3744-1-git-send-email-lvivier@redhat.com> <55BF7A7E.1050303@redhat.com> <20150803144637.GQ29283@redhat.com> <55BF8298.9080409@redhat.com> <55BF8506.2080505@redhat.com> From: Paolo Bonzini Message-ID: <55BF864A.8060909@redhat.com> Date: Mon, 3 Aug 2015 17:18:34 +0200 MIME-Version: 1.0 In-Reply-To: <55BF8506.2080505@redhat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] i6300esb: correctly convert watchdog clock ticks into nanoseconds List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Laurent Vivier , "Richard W.M. Jones" Cc: qemu-devel@nongnu.org, David Gibson On 03/08/2015 17:13, Laurent Vivier wrote: >>> >> it says "33 MHz clock (30 ns clock ticks)" which is contradictory. >> > >> > I found that the spec allows for any speed up to 33333333 Hz (30 ns >> > cycle), so both are okay. However, at least hw/net/rtl8139.c assumes >> > it's 33000000 Hz, so it's nice to be consistent. > So, do you want I resend a patch with "1000 / 33" instead ? > > We can also update hw/net/rtl8139.c to replace "muldiv64(X, > get_ticks_per_sec(), 33000000)" by "X * 30" ? Either would do. If you modify hw/net/rtl8139.c you have to modify CLK in tests/test-rtl8139.c as well. Paolo