From: Mika Westerberg <mika.westerberg@linux.intel.com>
To: Rajat Khandelwal <rajat.khandelwal@intel.com>
Cc: andreas.noever@gmail.com, michael.jamet@intel.com,
YehezkelShB@gmail.com, linux-usb@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v4] thunderbolt: Add wake on connect/disconnect on USB4 ports
Date: Tue, 27 Sep 2022 15:27:38 +0300 [thread overview]
Message-ID: <YzLsOioaDVARFnR2@black.fi.intel.com> (raw)
In-Reply-To: <20220928115230.2031934-1-rajat.khandelwal@intel.com>
Hi,
On Wed, Sep 28, 2022 at 05:22:30PM +0530, Rajat Khandelwal wrote:
> Wake on connect/disconnect is only supported while runtime suspend
> for now, which is obviously necessary. Its also not inherently
> desired for the system to wakeup on thunderbolt hot events.
> However, we can still make user in control of waking up the system
> in the events of hot plug/unplug.
> This patch adds 'wakeup' attribute under 'usb4_portX/power' sysfs
> attribute and only enables wakes on connect/disconnect to the
> respective port when 'wakeup' is set to 'enabled'. The attribute
> is set to 'disabled' by default.
>
> Signed-off-by: Rajat Khandelwal <rajat.khandelwal@intel.com>
> ---
>
> Significant changes and reasons:
> 1. 'if (!port->cap_usb4)' is added under the loop in
> 'usb4_switch_check_wakes' function since the checks later are
> explicitly targeted to the USB4 port configuration capability.
> 'if (!tb_port_has_remote(port))' is removed because events now can
> be connection/disconnection along with USB4 events. Thus, a wake
> on connection can be triggered by user on the USB4 port (initially
> no remote).
> 2. Verified runtime wakeup. It works absolutely fine.
> 3. Wakeup count has to be increased in the 'wakeup_count' attribute
> under usb4_port/power, thus requiring another pm_wakeup_event.
>
> Fixes in v4:
Have you sent this patch previously upstream? I don't think so. So the
version number should be v1 (or ignored) and this changelog is not
needed either.
Also in future it is good to have link here to the previous versions of
the patch. I think all this is explained in
https://docs.kernel.org/process/index.html.
prev parent reply other threads:[~2022-09-27 12:29 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-09-28 11:52 [PATCH v4] thunderbolt: Add wake on connect/disconnect on USB4 ports Rajat Khandelwal
2022-09-27 12:27 ` Mika Westerberg [this message]
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=YzLsOioaDVARFnR2@black.fi.intel.com \
--to=mika.westerberg@linux.intel.com \
--cc=YehezkelShB@gmail.com \
--cc=andreas.noever@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=michael.jamet@intel.com \
--cc=rajat.khandelwal@intel.com \
/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