summaryrefslogtreecommitdiff
path: root/board/guybrush/thermal.c
diff options
context:
space:
mode:
Diffstat (limited to 'board/guybrush/thermal.c')
-rw-r--r--board/guybrush/thermal.c34
1 files changed, 34 insertions, 0 deletions
diff --git a/board/guybrush/thermal.c b/board/guybrush/thermal.c
new file mode 100644
index 0000000000..606d21cfdf
--- /dev/null
+++ b/board/guybrush/thermal.c
@@ -0,0 +1,34 @@
+/* Copyright 2022 The Chromium OS Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+/* Guybrush board-specific configuration */
+
+#include "console.h"
+#include "fan.h"
+#include "thermal.h"
+#include "util.h"
+
+/* Console output macros */
+#define CPUTS(outstr) cputs(CC_THERMAL, outstr)
+#define CPRINTS(format, args...) cprints(CC_THERMAL, format, ## args)
+
+const struct fan_conf fan_conf_0 = {
+ .flags = FAN_USE_RPM_MODE,
+ .ch = MFT_CH_0, /* Use MFT id to control fan */
+ .pgood_gpio = GPIO_S0_PGOOD,
+ .enable_gpio = -1,
+};
+const struct fan_rpm fan_rpm_0 = {
+ .rpm_min = 1000,
+ .rpm_start = 1000,
+ .rpm_max = 6500,
+};
+const struct fan_t fans[] = {
+ [FAN_CH_0] = {
+ .conf = &fan_conf_0,
+ .rpm = &fan_rpm_0,
+ },
+};
+BUILD_ASSERT(ARRAY_SIZE(fans) == FAN_CH_COUNT);