summaryrefslogtreecommitdiff
path: root/zephyr/program/corsola/include/variant_db_detection.h
diff options
context:
space:
mode:
authorEric Yilun Lin <yllin@chromium.org>2023-04-07 16:26:53 +0800
committerChromeos LUCI <chromeos-scoped@luci-project-accounts.iam.gserviceaccount.com>2023-05-12 09:46:42 +0000
commit58008e49b6ef5b75965fe4abc507597066860e64 (patch)
treecb6223458ba6c0b30b3dbe2b85d9148f32c8715c /zephyr/program/corsola/include/variant_db_detection.h
parent71411640b887ca37c80783bef8ab4ec1d5a15c28 (diff)
downloadchrome-ec-58008e49b6ef5b75965fe4abc507597066860e64.tar.gz
kingler: add usbc test
This CL adds the initial USB-C tests on kingler BUG=b:272664811 TEST=twister -ci zephyr/test Change-Id: I14395ce84442f40e6fd05f7c14a2814fb24ebb9a Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/4483240 Reviewed-by: Ting Shen <phoenixshen@chromium.org> Tested-by: Eric Yilun Lin <yllin@google.com> Auto-Submit: Eric Yilun Lin <yllin@google.com> Commit-Queue: Ting Shen <phoenixshen@chromium.org>
Diffstat (limited to 'zephyr/program/corsola/include/variant_db_detection.h')
-rw-r--r--zephyr/program/corsola/include/variant_db_detection.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/zephyr/program/corsola/include/variant_db_detection.h b/zephyr/program/corsola/include/variant_db_detection.h
index e98ba3067d..cf86e1ae1c 100644
--- a/zephyr/program/corsola/include/variant_db_detection.h
+++ b/zephyr/program/corsola/include/variant_db_detection.h
@@ -8,6 +8,8 @@
#ifndef __CROS_EC_CORSOLA_DB_DETECTION_H
#define __CROS_EC_CORSOLA_DB_DETECTION_H
+#include <stdint.h>
+
enum corsola_db_type {
CORSOLA_DB_UNINIT = -1,
CORSOLA_DB_NONE,
@@ -16,19 +18,19 @@ enum corsola_db_type {
CORSOLA_DB_COUNT,
};
-#ifdef CONFIG_VARIANT_CORSOLA_DB_DETECTION
/*
* Get the connected daughterboard type.
*
* @return The daughterboard type.
*/
+#ifdef CONFIG_VARIANT_CORSOLA_DB_DETECTION
enum corsola_db_type corsola_get_db_type(void);
-#else
+#elif !defined(CONFIG_TEST)
inline enum corsola_db_type corsola_get_db_type(void)
{
return CORSOLA_DB_NONE;
-};
-#endif /* CONFIG_VARIANT_CORSOLA_DB_DETECTION */
+}
+#endif
/* return the adjusted port count for board overridden usbc/charger functions.
*/