linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Berg <bberg@redhat.com>
To: Heikki Krogerus <heikki.krogerus@linux.intel.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Ulrich Huber <ulrich@huberulrich.de>, linux-usb@vger.kernel.org
Subject: Re: [PATCH 0/7] usb: typec: ucsi: Driver improvements
Date: Thu, 23 Sep 2021 16:38:00 +0200	[thread overview]
Message-ID: <52591c12693733a3caf11d2bb5999acdfe177054.camel@redhat.com> (raw)
In-Reply-To: <20210920142419.54493-1-heikki.krogerus@linux.intel.com>

[-- Attachment #1: Type: text/plain, Size: 2279 bytes --]

Hi,

On Mon, 2021-09-20 at 17:24 +0300, Heikki Krogerus wrote:
> The goal of this series was to improve the alt mode handling in the
> driver, but now it seems that we can use the "poll worker" that was
> introduced for that to handle other tasks better as well.
> 
> Ulrich reported some problems that are caused by the second
> GET_CONNECTOR_STATUS right after the first one that was introduced in
> 217504a05532 ("usb: typec: ucsi: Work around PPM losing change
> information"). In the last patch I try to improve that workaround by
> extracting it out of the generic event handler into its own task and
> executing it only when it's really needed. That seems to improve the
> situation.
> 
> These patches definitely improve the quality of the driver by making
> it a bit more readable, but they also appear to make the behaviour a
> bit more predictably and uniform on different platforms.
> 
> Benjamin, can you test these?

I just gave this a spin on a X1 Carbon Gen 8 with a Lenovo TB 3 Dock.
Unfortunately, I can still reproduce the issue occasionally. My take is
that the rate is much lower than it was before my patch was introduced.
However, unfortunately the patchset does appear to cause a regression
on the machine I tested.

As before. The "online" status of the UCSI power supply is reported as
"1" occasionally even after the cable was unplugged. And the issue
seems to only happens with a dock, not if I use a USB-C charger.

Benjamin

> Heikki Krogerus (7):
>   usb: typec: ucsi: Always cancel the command if PPM reports BUSY
>     condition
>   usb: typec: ucsi: Don't stop alt mode registration on busy condition
>   usb: typec: ucsi: Add polling mechanism for partner tasks like alt
>     mode checking
>   usb: typec: ucsi: acpi: Reduce the command completion timeout
>   usb: typec: ucsi: Check the partner alt modes always if there is PD
>     contract
>   usb: typec: ucsi: Read the PDOs in separate work
>   usb: typec: ucsi: Better fix for missing unplug events issue
> 
>  drivers/usb/typec/ucsi/ucsi.c      | 337 ++++++++++++++---------------
>  drivers/usb/typec/ucsi/ucsi.h      |   3 +-
>  drivers/usb/typec/ucsi/ucsi_acpi.c |   2 +-
>  3 files changed, 167 insertions(+), 175 deletions(-)
> 


[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

  parent reply	other threads:[~2021-09-23 14:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-20 14:24 [PATCH 0/7] usb: typec: ucsi: Driver improvements Heikki Krogerus
2021-09-20 14:24 ` [PATCH 1/7] usb: typec: ucsi: Always cancel the command if PPM reports BUSY condition Heikki Krogerus
2021-09-20 14:24 ` [PATCH 2/7] usb: typec: ucsi: Don't stop alt mode registration on busy condition Heikki Krogerus
2021-09-20 14:24 ` [PATCH 3/7] usb: typec: ucsi: Add polling mechanism for partner tasks like alt mode checking Heikki Krogerus
2021-09-20 14:24 ` [PATCH 4/7] usb: typec: ucsi: acpi: Reduce the command completion timeout Heikki Krogerus
2021-09-20 14:24 ` [PATCH 5/7] usb: typec: ucsi: Check the partner alt modes always if there is PD contract Heikki Krogerus
2021-09-20 14:24 ` [PATCH 6/7] usb: typec: ucsi: Read the PDOs in separate work Heikki Krogerus
2021-09-20 14:24 ` [PATCH 7/7] usb: typec: ucsi: Better fix for missing unplug events issue Heikki Krogerus
2021-09-23 14:38 ` Benjamin Berg [this message]
2021-09-23 16:06   ` [PATCH 0/7] usb: typec: ucsi: Driver improvements Ulrich Huber
2021-09-24 13:55     ` Heikki Krogerus

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=52591c12693733a3caf11d2bb5999acdfe177054.camel@redhat.com \
    --to=bberg@redhat.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=heikki.krogerus@linux.intel.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=ulrich@huberulrich.de \
    /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;
as well as URLs for NNTP newsgroup(s).