summaryrefslogtreecommitdiff
path: root/include/usb_pd_tcpm.h
diff options
context:
space:
mode:
authorTom Hughes <tomhughes@chromium.org>2021-03-04 14:20:37 -0800
committerCommit Bot <commit-bot@chromium.org>2021-05-06 20:11:53 +0000
commit13b2bbc4f99c7e21a913c439a99cd1bdb402e45b (patch)
tree4c970e6d68024031f99b9641a6e6be5505e7ef76 /include/usb_pd_tcpm.h
parente0a4e5ab99a45faa196b3894ade8c375061a7ab6 (diff)
downloadchrome-ec-13b2bbc4f99c7e21a913c439a99cd1bdb402e45b.tar.gz
Specify type for forward-declared enums
C++ does not allow enums to be forward declared unless they have a type. BRANCH=none BUG=b:144959033 TEST=make buildall Signed-off-by: Tom Hughes <tomhughes@chromium.org> Change-Id: I6fcdedc81f2b60a44b750554939e60552a4c6a77 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2740567 Reviewed-by: Daisuke Nojiri <dnojiri@chromium.org>
Diffstat (limited to 'include/usb_pd_tcpm.h')
-rw-r--r--include/usb_pd_tcpm.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/usb_pd_tcpm.h b/include/usb_pd_tcpm.h
index 700b1d0fcd..584f3ac321 100644
--- a/include/usb_pd_tcpm.h
+++ b/include/usb_pd_tcpm.h
@@ -10,6 +10,7 @@
#include <stdbool.h>
#include "common.h"
+#include "compiler.h"
#include "ec_commands.h"
#include "i2c.h"
@@ -41,7 +42,7 @@ enum tcpc_cc_pull {
};
/* Pull-up values we apply as a SRC to advertise different current limits */
-enum tcpc_rp_value {
+FORWARD_DECLARE_ENUM(tcpc_rp_value) {
TYPEC_RP_USB = 0,
TYPEC_RP_1A5 = 1,
TYPEC_RP_3A0 = 2,