diff options
author | Badhri Jagan Sridharan <badhri@google.com> | 2021-02-01 19:38:59 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2021-02-02 16:14:41 +0100 |
commit | 2b8ff93fd7443d7bd4c085ac0249d87238c755ba (patch) | |
tree | 15cab8702e18b51984a8b2e39f1b9924c144a764 /lib/kunit/kunit-test.c | |
parent | 7771bcc7f5a727d6e3f7a80b0b075a75cb664fb2 (diff) |
usb: typec: tcpm: Set in_ams flag when Source caps have been received
Receiving the first packet in an AMS sequence signals the
beginning of AMS. Set in_ams flag to true when SRC_CAPS are
received during POWER_NEGOTIATION AMS.
This fixes the failure flagged while running TD.PD.SNK.E9
compliance test.
>From Deterministic PD compliance MOI spec:
TD.PD.SNK.E9. GetSinkCap in Place of Accept
Description:
As Provider, the Tester intentionally sends a GetSinkCap message in place
of Accept message and verifies the UUT will send a SoftReset and recover
from the error.
Steps:
a) Run PROC.PD.E1 Bring-up according to the UUT role.
b) The Tester cycles VBus.
c) The Tester sends a Source Capabilities message to the UUT.
d) Upon receipt of a Request message from the UUT, the Tester replies with
a GoodCRC message.
e) The Tester sends a GetSinkCap message to the UUT.
f) If a SoftReset is not received within 15 ms after the GetSinkCap EOP was
sent, the test fails.
g) If a SoftReset is received timely, the Tester replies with an Accept
message.
h) The Tester sends Source Capabilities message to the UUT repeatedly until
nCapsCount reached or a GoodCRC is received. If nCapsCount reached, the
test fails.
i) If a Request is not received timely within 30 ms after the GoodCRC EOP
corresponding to Source Capabilities message was received, the test
fails.
Reviewed-by: Guenter Roeck <linux@roeck-us.net>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Badhri Jagan Sridharan <badhri@google.com>
Link: https://lore.kernel.org/r/20210202033859.258491-1-badhri@google.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'lib/kunit/kunit-test.c')
0 files changed, 0 insertions, 0 deletions