summaryrefslogtreecommitdiff
path: root/include/usb_sm.h
diff options
context:
space:
mode:
authorSam Hurst <shurst@google.com>2020-04-22 15:12:15 -0700
committerCommit Bot <commit-bot@chromium.org>2020-04-29 21:50:30 +0000
commit9abfcc7ced52511ce1c6d501a4b54014fa21f19e (patch)
tree8b6c22b99468456c812253bb95eb7a7777975fd6 /include/usb_sm.h
parent459021082eb95870af2ad49ac58b5c479895c8dd (diff)
downloadchrome-ec-9abfcc7ced52511ce1c6d501a4b54014fa21f19e.tar.gz
TCPMv2: Add dump pd command needed by PD_FAFT
Add dump pd command that sets the debug level of the Policy Engine Layer and Protocol layer. BUG=b:151481791 BRANCH=none TEST=make -j buildall manual: pd dump 0 - verified PRL layer didn't print packet info and PE layer didn't print state names pd dump 1 - verified PRL layer printed packet info and PE layer printed state names Change-Id: I49430573278a4c51f52698c1528ace2c639cc30f Signed-off-by: Sam Hurst <shurst@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2162190 Reviewed-by: Wai-Hong Tam <waihong@google.com>
Diffstat (limited to 'include/usb_sm.h')
-rw-r--r--include/usb_sm.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/usb_sm.h b/include/usb_sm.h
index af5c600d46..ea17d55ab9 100644
--- a/include/usb_sm.h
+++ b/include/usb_sm.h
@@ -46,6 +46,18 @@ enum sm_local_state {
SM_PAUSED,
};
+/*
+ * A state machine can use these debug levels to regulate the amount of debug
+ * information printed on the EC console
+ */
+enum debug_level {
+ DEBUG_DISABLE,
+ DEBUG_LEVEL_1,
+ DEBUG_LEVEL_2,
+ DEBUG_LEVEL_3,
+ DEBUG_LEVEL_MAX = DEBUG_LEVEL_3
+};
+
/**
* Changes a state machines state. This handles exiting the previous state and
* entering the target state. A common parent state will not exited nor be