From patchwork Tue Jan 20 16:41:30 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "pang.xunlei" X-Patchwork-Id: 43418 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-we0-f198.google.com (mail-we0-f198.google.com [74.125.82.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id BF7142034D for ; Tue, 20 Jan 2015 16:49:56 +0000 (UTC) Received: by mail-we0-f198.google.com with SMTP id q58sf8740176wes.1 for ; Tue, 20 Jan 2015 08:49:55 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:sender:precedence:list-id :x-original-sender:x-original-authentication-results:mailing-list :list-post:list-help:list-archive:list-unsubscribe; bh=GNsulut479+3ho1FxCuQ+bFrTw/HD08mcaqgf4w6Pi0=; b=V1J8eqWFHQoQl7c+/IoNPnp/SWYPepR6dALqlMXWAc0kbeTpnFt4/zcnL22hXiD1cR CQ7HWOpVEkrrUUO5ZXEYrvyFZnoXBKLDh6DiYPE3FRDSiEaQUhME0dbrBBVr86TvypWV /iSVFOUDb5dMx4ETG7q05DQv6e2jMzQOqoMzzlzPQL4iYnonLzDtME5lKEi3IN7Fb5Na Wj2mtKTI1tPozEBl2ubs+KskUygqczjlMFgIGSxzliC9BY/kPkdbhQy9SHbvpO7UO9CY +3kBAUvbXmBsPVnpwGoHhgbqFdnLpXZnhOgX0n1hjEtu6DQ0OwfBxOfDSNgkVJOBFUD7 Egdw== X-Gm-Message-State: ALoCoQkYN3/G777m1k/V5lOJlPVr90m57TdhgJEptOvuwH9JoS4IFcE24JLy7nibCKqgspGKxU/J X-Received: by 10.112.143.167 with SMTP id sf7mr660521lbb.0.1421772595972; Tue, 20 Jan 2015 08:49:55 -0800 (PST) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.43.41 with SMTP id t9ls765198lal.99.gmail; Tue, 20 Jan 2015 08:49:55 -0800 (PST) X-Received: by 10.112.125.202 with SMTP id ms10mr39598822lbb.33.1421772595733; Tue, 20 Jan 2015 08:49:55 -0800 (PST) Received: from mail-lb0-f175.google.com (mail-lb0-f175.google.com. [209.85.217.175]) by mx.google.com with ESMTPS id y9si15759939lbr.7.2015.01.20.08.49.55 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 20 Jan 2015 08:49:55 -0800 (PST) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.175 as permitted sender) client-ip=209.85.217.175; Received: by mail-lb0-f175.google.com with SMTP id z11so34717561lbi.6 for ; Tue, 20 Jan 2015 08:49:55 -0800 (PST) X-Received: by 10.152.18.135 with SMTP id w7mr38411166lad.47.1421772595316; Tue, 20 Jan 2015 08:49:55 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.9.200 with SMTP id c8csp1481927lbb; Tue, 20 Jan 2015 08:49:54 -0800 (PST) X-Received: by 10.70.40.139 with SMTP id x11mr55316075pdk.124.1421772593573; Tue, 20 Jan 2015 08:49:53 -0800 (PST) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id pu1si4991956pbb.173.2015.01.20.08.49.52; Tue, 20 Jan 2015 08:49:53 -0800 (PST) Received-SPF: none (google.com: linux-kernel-owner@vger.kernel.org does not designate permitted sender hosts) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755531AbbATQtt (ORCPT + 28 others); Tue, 20 Jan 2015 11:49:49 -0500 Received: from mail-ie0-f175.google.com ([209.85.223.175]:60605 "EHLO mail-ie0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753252AbbATQlq (ORCPT ); Tue, 20 Jan 2015 11:41:46 -0500 Received: by mail-ie0-f175.google.com with SMTP id ar1so6094207iec.6 for ; Tue, 20 Jan 2015 08:41:46 -0800 (PST) X-Received: by 10.50.50.140 with SMTP id c12mr27735906igo.5.1421772106056; Tue, 20 Jan 2015 08:41:46 -0800 (PST) Received: from ip-10-181-65-231.ec2.internal ([54.235.93.228]) by mx.google.com with ESMTPSA id q7sm3117924igx.9.2015.01.20.08.41.44 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 20 Jan 2015 08:41:45 -0800 (PST) From: Xunlei Pang To: linux-kernel@vger.kernel.org Cc: rtc-linux@googlegroups.com, Thomas Gleixner , Alessandro Zummo , Feng Tang , John Stultz , Arnd Bergmann , Xunlei Pang Subject: [PATCH 3/3] time: clocksource: Add a comment to CLOCK_SOURCE_SUSPEND_NONSTOP Date: Tue, 20 Jan 2015 16:41:30 +0000 Message-Id: <1421772090-13113-3-git-send-email-pang.xunlei@linaro.org> X-Mailer: git-send-email 2.2.1 In-Reply-To: <1421772090-13113-1-git-send-email-pang.xunlei@linaro.org> References: <1421772090-13113-1-git-send-email-pang.xunlei@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: pang.xunlei@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.175 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , When doing timekeeping_resume(), if the nonstop clocksource wraps back, "cycle_delta" will miss the wrap time. So add a comment to indicate that if have this flag set, you are aware that this nonstop clocksource won't wrap during suspension. Signed-off-by: Xunlei Pang --- include/linux/clocksource.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/include/linux/clocksource.h b/include/linux/clocksource.h index abcafaa..20bca76 100644 --- a/include/linux/clocksource.h +++ b/include/linux/clocksource.h @@ -207,6 +207,11 @@ struct clocksource { #define CLOCK_SOURCE_WATCHDOG 0x10 #define CLOCK_SOURCE_VALID_FOR_HRES 0x20 #define CLOCK_SOURCE_UNSTABLE 0x40 + +/* + * Setting this flag, also means it doesn't wrap back during + * system suspend/resume. See timekeeping_resume(). + */ #define CLOCK_SOURCE_SUSPEND_NONSTOP 0x80 #define CLOCK_SOURCE_RESELECT 0x100