platform/chrome: Don't treat RTC events as wakeup sources
authorStephen Boyd <swboyd@chromium.org>
Fri, 30 Oct 2020 23:25:23 +0000 (16:25 -0700)
committerEnric Balletbo i Serra <enric.balletbo@collabora.com>
Thu, 12 Nov 2020 20:24:04 +0000 (21:24 +0100)
commit853c1a789f5fe8e783586a5c2dcc2ad1b57ac20f
tree308b622ec6aae68c3401738569d1b6003937cad8
parent3650b228f83adda7e5ee532e2b90429c03f7b9ec
platform/chrome: Don't treat RTC events as wakeup sources

The EC sends an RTC host event when the RTC fires, but we don't need to
treat that as a wakeup event here. The RTC class already properly
handles activating and deactivating a wakeup source in rtc_update_irq()
by calling pm_stay_awake() at the start of processing and pm_relax()
once all expired RTC timers have been processed. This reduces one wakeup
increment but not much else. I noticed this while debugging RTC wakeups
and how they always incremented the wakeup count by two instead of one
because this is duplicated.

Signed-off-by: Stephen Boyd <swboyd@chromium.org>
Signed-off-by: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Cc: Guenter Roeck <groeck@chromium.org>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: Alexandre Belloni <alexandre.belloni@bootlin.com>
Cc: <linux-rtc@vger.kernel.org>
Link: https://lore.kernel.org/r/20201030232523.2654478-1-swboyd@chromium.org
drivers/platform/chrome/cros_ec_proto.c