From patchwork Wed Sep 14 07:58:40 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Tokarev X-Patchwork-Id: 669794 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3sYvhM1QJVz9sC3 for ; Wed, 14 Sep 2016 18:23:47 +1000 (AEST) Received: from localhost ([::1]:54164 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bk5Ts-00085Z-Ml for incoming@patchwork.ozlabs.org; Wed, 14 Sep 2016 04:23:44 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:32823) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bk561-0005mZ-GN for qemu-devel@nongnu.org; Wed, 14 Sep 2016 03:59:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bk55y-0004YY-N8 for qemu-devel@nongnu.org; Wed, 14 Sep 2016 03:59:05 -0400 Received: from isrv.corpit.ru ([86.62.121.231]:37558) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bk55y-0004Wa-FA; Wed, 14 Sep 2016 03:59:02 -0400 Received: from tsrv.tls.msk.ru (tsrv.tls.msk.ru [192.168.177.2]) by isrv.corpit.ru (Postfix) with ESMTP id A1B4D41847; Wed, 14 Sep 2016 10:58:58 +0300 (MSK) Received: from tls.msk.ru (mjt.vpn.tls.msk.ru [192.168.177.99]) by tsrv.tls.msk.ru (Postfix) with SMTP id 1D1CDAAB; Wed, 14 Sep 2016 10:58:58 +0300 (MSK) Received: (nullmailer pid 17339 invoked by uid 1000); Wed, 14 Sep 2016 07:58:57 -0000 From: Michael Tokarev To: qemu-devel@nongnu.org Date: Wed, 14 Sep 2016 10:58:40 +0300 Message-Id: X-Mailer: git-send-email 2.1.4 In-Reply-To: References: In-Reply-To: References: X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 86.62.121.231 Subject: [Qemu-devel] [PULL 14/27] timer: update comments X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: qemu-trivial@nongnu.org, Paolo Bonzini , Cao jin , Michael Tokarev , Peter Maydell Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: "Qemu-devel" From: Cao jin The comments is outdated. The patch has following changes: 1. tense correction. 2. all clock time value is returned in nanoseconds, so, they are same in precision. 3. virtual clock doesn't use cpu cycles. Cc: Paolo Bonzini Cc: Peter Maydell Signed-off-by: Cao jin Signed-off-by: Michael Tokarev --- include/qemu/timer.h | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/include/qemu/timer.h b/include/qemu/timer.h index 4bfcd35..bdfae00 100644 --- a/include/qemu/timer.h +++ b/include/qemu/timer.h @@ -22,23 +22,20 @@ * @QEMU_CLOCK_REALTIME: Real time clock * * The real time clock should be used only for stuff which does not - * change the virtual machine state, as it is run even if the virtual - * machine is stopped. The real time clock has a frequency of 1000 - * Hz. + * change the virtual machine state, as it runs even if the virtual + * machine is stopped. * * @QEMU_CLOCK_VIRTUAL: virtual clock * - * The virtual clock is only run during the emulation. It is stopped - * when the virtual machine is stopped. Virtual timers use a high - * precision clock, usually cpu cycles (use ticks_per_sec). + * The virtual clock only runs during the emulation. It stops + * when the virtual machine is stopped. * * @QEMU_CLOCK_HOST: host clock * - * The host clock should be use for device models that emulate accurate + * The host clock should be used for device models that emulate accurate * real time sources. It will continue to run when the virtual machine * is suspended, and it will reflect system time changes the host may - * undergo (e.g. due to NTP). The host clock has the same precision as - * the virtual clock. + * undergo (e.g. due to NTP). * * @QEMU_CLOCK_VIRTUAL_RT: realtime clock used for icount warp * @@ -77,10 +74,6 @@ struct QEMUTimer { extern QEMUTimerListGroup main_loop_tlg; /* - * QEMUClockType - */ - -/* * qemu_clock_get_ns; * @type: the clock type *