OSDN Git Service

usb: typec: tcpm: set correct data role for non-DRD
authorLi Jun <jun.li@nxp.com>
Fri, 14 Feb 2020 07:53:48 +0000 (15:53 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 14 Feb 2020 16:38:15 +0000 (08:38 -0800)
commit6ecc632d4b35d24c443d3c3b797aa204cc5c4ab1
tree9dffa253f2bbc36c0dccaefa905957737d0b2dae
parent21d78d860cd604330dfc373f001a48e548d2c49e
usb: typec: tcpm: set correct data role for non-DRD

Since the typec port data role is separated from power role,
so check the port data capability when setting data role.

Signed-off-by: Li Jun <jun.li@nxp.com>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Link: https://lore.kernel.org/r/1581666828-2063-1-git-send-email-jun.li@nxp.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/typec/tcpm/tcpm.c