diff options
author | Mary Ruthven <mruthven@chromium.org> | 2016-08-18 12:26:53 -0700 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2016-08-25 01:46:39 -0700 |
commit | 613be38789b8d54aaf43c452ea348782fe53e9c0 (patch) | |
tree | 148f76e80ed211c0041b7e52c26fc18718b7a182 /include/case_closed_debug.h | |
parent | 9c693370505a83b76014f7f2b357a3a93afd57c2 (diff) | |
download | chrome-ec-613be38789b8d54aaf43c452ea348782fe53e9c0.tar.gz |
cr50: connect to AP phy on reef when not in ccd
Cr50 needs to connect to the AP phy when not in ccd so cr50 can be
updated and used as a gnubby. This change uses the strapping options
to detect when it is on reef and modifies the ccd behavior to
initialize usb on the AP phy when ccd is disabled. On gru the cr50
behavior is unchanged.
In RDD this change removes the checks that the current_map is the
correct one based on the detected debug state. rdd_init calls
rdd_interrupt to set up the usb and ccd state correctly. Having that
check prevents that initial rdd_interrupt from calling rdd_detached.
Before rdd_detached just disabled usb and we knew during init it
would already be disabled. Now we want to make sure it is called if a
debug accessory is not attached to initialize usb on the AP PHY.
BUG=chrome-os-partner:56098
BRANCH=none
TEST=manual
verify ccd still works on gru
disconnect suzyq and reset reef.
run lsusb on the AP and verify it shows cr50 as a device.
connect suzyq and check that the AP no longer sees cr50.
disconnect suzyq and verify the AP sees it again
Change-Id: I3c1ccc54895835bce12302f3ea43fc2e751b4c97
Signed-off-by: Mary Ruthven <mruthven@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/372920
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
Diffstat (limited to 'include/case_closed_debug.h')
-rw-r--r-- | include/case_closed_debug.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/case_closed_debug.h b/include/case_closed_debug.h index 82c9c9548f..ed2f13d099 100644 --- a/include/case_closed_debug.h +++ b/include/case_closed_debug.h @@ -26,6 +26,8 @@ enum ccd_mode { * device over CCD. */ CCD_MODE_ENABLED, + + CCD_MODE_COUNT, }; /* @@ -33,4 +35,6 @@ enum ccd_mode { */ void ccd_set_mode(enum ccd_mode new_mode); +/* Initialize the PHY based on CCD state */ +void ccd_phy_init(int enable_ccd); #endif /* __CROS_EC_CASE_CLOSED_DEBUG_H */ |