From: Tzung-Bi Shih <tzungbi@google.com>
To: Prashant Malani <pmalani@chromium.org>
Cc: bleung@chromium.org, groeck@chromium.org,
chrome-platform@lists.linux.dev
Subject: Re: [PATCH v2 3/6] platform/chrome: cros_ec: determine `wake_enabled` in cros_ec_suspend()
Date: Wed, 16 Feb 2022 12:13:16 +0800 [thread overview]
Message-ID: <Ygx53F0bziAWceqJ@google.com> (raw)
In-Reply-To: <CACeCKadSTq22aN1mwpT2re5dcA0J+GW7R8=gg4no5MB6j9m+Bw@mail.gmail.com>
On Tue, Feb 15, 2022 at 05:07:43PM -0800, Prashant Malani wrote:
> On Wed, Feb 9, 2022 at 1:36 AM Tzung-Bi Shih <tzungbi@google.com> wrote:
> >
> > On Tue, Feb 08, 2022 at 10:05:58PM -0800, Prashant Malani wrote:
> > > On Tue, Feb 8, 2022 at 8:50 PM Tzung-Bi Shih <tzungbi@google.com> wrote:
> > > >
> > > > `wake_enabled` indicates cros_ec_resume() needs to call
> > > > disable_irq_wake() to undo enable_irq_wake() in cros_ec_suspend().
> > > >
> > > > Determine `wake_enabled` in cros_ec_suspend() instead of
> > > > reset-after-used in cros_ec_resume().
> > > It sounds like we can accomplish the same thing as this patch by either:
> > > - Initializing ec_dev->wake_enabled = false during cros_ec_register()
> >
> > This doesn't sound like a good idea. Value of device_may_wakeup(dev) changes
> > during runtime. It should check in cros_ec_suspend() instead of in
> > cros_ec_register().
>
> Hmm, I'm pretty sure it shouldn't change for Cros EC. In any case, I'm
> not suggesting
> moving the check away from cros_ec_suspend(), just the initialization
> of the flag.
Got it. I misunderstood. Let's go this direction. Will fix in the next
version.
next prev parent reply other threads:[~2022-02-16 4:13 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-09 4:50 [PATCH v2 0/6] platform/chrome: cros_ec: miscellaneous cleanups Tzung-Bi Shih
2022-02-09 4:50 ` [PATCH v2 1/6] platform/chrome: cros_ec: fix error handling in cros_ec_register() Tzung-Bi Shih
2022-02-09 5:38 ` Prashant Malani
2022-02-09 9:35 ` Tzung-Bi Shih
2022-02-09 4:50 ` [PATCH v2 2/6] platform/chrome: cros_ec: remove unused variable `was_wake_device` Tzung-Bi Shih
2022-02-09 5:58 ` Prashant Malani
2022-02-09 9:36 ` Tzung-Bi Shih
2022-02-09 4:50 ` [PATCH v2 3/6] platform/chrome: cros_ec: determine `wake_enabled` in cros_ec_suspend() Tzung-Bi Shih
2022-02-09 6:05 ` Prashant Malani
2022-02-09 9:36 ` Tzung-Bi Shih
2022-02-16 1:07 ` Prashant Malani
2022-02-16 4:13 ` Tzung-Bi Shih [this message]
2022-02-16 5:55 ` Prashant Malani
2022-02-16 7:33 ` Tzung-Bi Shih
2022-02-09 4:50 ` [PATCH v2 4/6] platform/chrome: cros_ec: don't initialize `err` in cros_ec_register() Tzung-Bi Shih
2022-02-09 6:08 ` Prashant Malani
2022-02-09 9:37 ` Tzung-Bi Shih
2022-02-09 4:50 ` [PATCH v2 5/6] platform/chrome: cros_ec: sort header inclusion alphabetically Tzung-Bi Shih
2022-02-09 4:50 ` [PATCH v2 6/6] platform/chrome: cros_ec: append newline to all logs Tzung-Bi Shih
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=Ygx53F0bziAWceqJ@google.com \
--to=tzungbi@google.com \
--cc=bleung@chromium.org \
--cc=chrome-platform@lists.linux.dev \
--cc=groeck@chromium.org \
--cc=pmalani@chromium.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox