]> git.baikalelectronics.ru Git - kernel.git/commit
usb: typec: ucsi: ccg: add runtime pm workaround
authorAjay Gupta <ajayg@nvidia.com>
Fri, 7 Jun 2019 16:34:23 +0000 (09:34 -0700)
committerWolfram Sang <wsa@the-dreams.de>
Fri, 7 Jun 2019 22:09:27 +0000 (00:09 +0200)
commit738521a687df6e017453f1e98488b63ac82b1c4a
treedc162c6889863893f59d870bee17501add149fd2
parent1a89f35eb3f885189d0b1e8f386eb82f43b797a1
usb: typec: ucsi: ccg: add runtime pm workaround

Cypress USB Type-C CCGx controller firmware version 3.1.10
(which is being used in many NVIDIA GPU cards) has known issue of
not triggering interrupt when a USB device is hot plugged to runtime
resume the controller. If any GPU card gets latest kernel with runtime
pm support but does not get latest fixed firmware then also it should
continue to work and therefore a workaround is required to check for
any connector change event.

The workaround is that i2c bus driver will call pm_request_resume()
to runtime resume ucsi_ccg driver. CCG driver will call the ISR
for any connector change event for NVIDIA GPU card and only if it has
old CCG firmware with the known issue.

Signed-off-by: Ajay Gupta <ajayg@nvidia.com>
Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/usb/typec/ucsi/ucsi_ccg.c