summaryrefslogtreecommitdiff
path: root/drivers/usb/typec/ucsi/ucsi.h
diff options
context:
space:
mode:
authorHeikki Krogerus <heikki.krogerus@linux.intel.com>2021-09-20 17:24:15 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-10-05 12:42:37 +0200
commitb9aa02ca39a49740926c2c450a1505a4a0f8954a (patch)
treed37cfed37bdfe762b8f0d691f98e8d30968fa37a /drivers/usb/typec/ucsi/ucsi.h
parent47eb8de3bbde346b880bb65ef0abe907d7fd6438 (diff)
usb: typec: ucsi: Add polling mechanism for partner tasks like alt mode checking
The "poll worker" that is introduced here is first used for checking partner alternate modes, but it can later be used for any partner task that requires a separate job to be scheduled to the connector specific workqueues. The mechanism allows the partner device specific tasks to be polling tasks and also delayed tasks if necessary. By polling the partner alternate modes with this mechanism the long command completion timeout value can be reduced back to normal. The long command completion timeout was only used to work around a problem on some platforms where the EC firmware (PPM) didn't return BUSY even when it should with the alt mode commands. Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> Link: https://lore.kernel.org/r/20210920142419.54493-4-heikki.krogerus@linux.intel.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/typec/ucsi/ucsi.h')
-rw-r--r--drivers/usb/typec/ucsi/ucsi.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/usb/typec/ucsi/ucsi.h b/drivers/usb/typec/ucsi/ucsi.h
index cee666790907..d10b8c24435a 100644
--- a/drivers/usb/typec/ucsi/ucsi.h
+++ b/drivers/usb/typec/ucsi/ucsi.h
@@ -317,6 +317,7 @@ struct ucsi_connector {
struct mutex lock; /* port lock */
struct work_struct work;
struct completion complete;
+ struct workqueue_struct *wq;
struct typec_port *port;
struct typec_partner *partner;