From patchwork Tue Jul 18 17:25:58 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mark Salyzyn X-Patchwork-Id: 9849229 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B4A8260392 for ; Tue, 18 Jul 2017 17:26:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 98F1F285BD for ; Tue, 18 Jul 2017 17:26:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 8DF92285CB; Tue, 18 Jul 2017 17:26:24 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2A3A3285BD for ; Tue, 18 Jul 2017 17:26:24 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751789AbdGRR0K (ORCPT ); Tue, 18 Jul 2017 13:26:10 -0400 Received: from mail-pg0-f41.google.com ([74.125.83.41]:34607 "EHLO mail-pg0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751476AbdGRR0I (ORCPT ); Tue, 18 Jul 2017 13:26:08 -0400 Received: by mail-pg0-f41.google.com with SMTP id 123so16294360pgj.1 for ; Tue, 18 Jul 2017 10:26:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=android.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=+60C8PnmQoEKfU27VXfMWf0elewqXjYnM1UA3YgKKkY=; b=TQCfQwc/MrbGL2HxObwwoWoSfiAQZlvi2CRAMOWof9SLIkN+fNn5CXSr381yDskyhd V2/iZJXUUgEOCFi4dtaI7+iE/uG+u4pHSwE505OfSkihOOXnfMVC36qzNtJWq3AV6ORL WgzyE3x16j0fd/C16pjAXJfuzEaWnvmAbq47r3ETHB3Seqww6ejStbl2tQbAmcRHQnVq GOpgn4l+0Gkuyy1BfTX7n/573V1b+a4Gx2OAcETSgmmv+80RD49YSngOCVukDHcTwFPu h6JzAyRE1LuAZtMeRl1CaGCz4n2QC1sctC+CpZmBdkYz1YOi6SS1gb1hvPEbjdaMysKL 0Ysw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=+60C8PnmQoEKfU27VXfMWf0elewqXjYnM1UA3YgKKkY=; b=KA3Zkdbp0tRoue6Hhc1VWYkvUQlsZQy1V9XAeMjdtAMLtPTvewJVdl30BewkABRgwO +6rKnEZaHPYQYNDtKLdgw/PsuevORSBpCD6WlVTWun04J2PVsfSDeAoMY41FAUflOiJ1 EvwDXa32lCM01QBEcT8DpUsFJPhUmqCeiti16NpU/kml94kQDMY4m7gW+KQjH+x2Rv0u 9j+75i7depffsucYCsQq7VHh9xwZjfy/LY06v0wPUhOM3YZxg3n2cV/lSoLKQhiYBbzy HjGFf/9qEHivSZXFJBS/rS73txXkny3Tf2/JBbRYI+TaodSd69EdOQSZW2bnjRRg3Z7H 2ZDQ== X-Gm-Message-State: AIVw112ulc7blR/Dan5U+9O14KfamgvhOyZDLXaA/6OE66FniMCYUDHi zyg/YuR1h9epCsOQ X-Received: by 10.99.130.72 with SMTP id w69mr2840114pgd.70.1500398767595; Tue, 18 Jul 2017 10:26:07 -0700 (PDT) Received: from nebulus.mtv.corp.google.com ([100.98.120.17]) by smtp.gmail.com with ESMTPSA id a125sm4929216pgc.37.2017.07.18.10.26.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 18 Jul 2017 10:26:07 -0700 (PDT) From: Mark Salyzyn To: linux-kernel@vger.kernel.org Cc: rjw@rjwysocki.net, len.brown@intel.com, pavel@ucw.cz, linux-pm@vger.kernel.org, a.zummo@towertech.it, alexandre.belloni@free-electrons.com, linux-rtc@vger.kernel.org, Mark Salyzyn Subject: [PATCH 3/4] PM: Print wall time at suspend entry and exit Date: Tue, 18 Jul 2017 10:25:58 -0700 Message-Id: <20170718172600.114761-1-salyzyn@android.com> X-Mailer: git-send-email 2.13.2.932.g7449e964c-goog Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Permits power state and battery life diagnosis. Feature activated by CONFIG_RTC_SHOW_TIME. Signed-off-by: Mark Salyzyn --- kernel/power/suspend.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kernel/power/suspend.c b/kernel/power/suspend.c index 3ecf275d7e44..f44d2152ab3f 100644 --- a/kernel/power/suspend.c +++ b/kernel/power/suspend.c @@ -26,6 +26,7 @@ #include #include #include +#include #include #include #include @@ -579,6 +580,7 @@ int pm_suspend(suspend_state_t state) if (state <= PM_SUSPEND_ON || state >= PM_SUSPEND_MAX) return -EINVAL; + rtc_show_time("PM: suspend entry"); error = enter_state(state); if (error) { suspend_stats.fail++; @@ -586,6 +588,7 @@ int pm_suspend(suspend_state_t state) } else { suspend_stats.success++; } + rtc_show_time("PM: suspend exit"); return error; } EXPORT_SYMBOL(pm_suspend);