[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <YzLsOioaDVARFnR2@black.fi.intel.com>
Date: Tue, 27 Sep 2022 15:27:38 +0300
From: Mika Westerberg <mika.westerberg@...ux.intel.com>
To: Rajat Khandelwal <rajat.khandelwal@...el.com>
Cc: andreas.noever@...il.com, michael.jamet@...el.com,
YehezkelShB@...il.com, linux-usb@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v4] thunderbolt: Add wake on connect/disconnect on USB4
ports
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@...el.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.
Powered by blists - more mailing lists