summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosh Tsai <josh_tsai@compal.corp-partner.google.com>2019-12-05 11:05:18 +0800
committerCommit Bot <commit-bot@chromium.org>2019-12-06 19:58:09 +0000
commit89197aceaf26ccf33b143c7a5e95eb07ba4c7464 (patch)
tree73fd35ae26a6fe4aea7b406502a2e19bc4e1e921
parent9d206be4be6b723a84089ae9ddd4aff9291f17ed (diff)
downloadchrome-ec-89197aceaf26ccf33b143c7a5e95eb07ba4c7464.tar.gz
hatch: refactor PD_MAX_VOLTAGE/PD_MAX_CURRENT/PD_MAX_POWER/PD_OPERATING_POWER/
1) The four config is determined by board, move it into board.h. 2) Update the config variables above for stryke. BUG=b:145257655 BRANCH=hatch TEST=make buildall Change-Id: I1dd6a4f2a78b5196006821bc5d2686f68206c2e1 Signed-off-by: Josh Tsai <josh_tsai@compal.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1950270 Reviewed-by: Paul Fagerburg <pfagerburg@chromium.org>
-rw-r--r--baseboard/hatch/baseboard.h6
-rw-r--r--board/akemi/board.h5
-rw-r--r--board/dratini/board.h6
-rw-r--r--board/hatch/board.h6
-rw-r--r--board/helios/board.h6
-rw-r--r--board/jinlon/board.h6
-rw-r--r--board/kindred/board.h6
-rw-r--r--board/kohaku/board.h5
-rw-r--r--board/stryke/board.h5
9 files changed, 45 insertions, 6 deletions
diff --git a/baseboard/hatch/baseboard.h b/baseboard/hatch/baseboard.h
index ffe104c7bf..3c3096a86d 100644
--- a/baseboard/hatch/baseboard.h
+++ b/baseboard/hatch/baseboard.h
@@ -156,12 +156,6 @@
#define PD_POWER_SUPPLY_TURN_OFF_DELAY 250000 /* us */
#define PD_VCONN_SWAP_DELAY 5000 /* us */
-/* TODO(b/122273953): Use correct PD power values */
-#define PD_OPERATING_POWER_MW 15000
-#define PD_MAX_POWER_MW 60000
-#define PD_MAX_CURRENT_MA 3000
-#define PD_MAX_VOLTAGE_MV 20000
-
/* I2C Bus Configuration */
#define CONFIG_I2C
#define CONFIG_I2C_MASTER
diff --git a/board/akemi/board.h b/board/akemi/board.h
index 4dbcb1aaa7..389112da51 100644
--- a/board/akemi/board.h
+++ b/board/akemi/board.h
@@ -157,6 +157,11 @@ enum battery_type {
BATTERY_TYPE_COUNT,
};
+#define PD_OPERATING_POWER_MW 15000
+#define PD_MAX_POWER_MW 60000
+#define PD_MAX_CURRENT_MA 3000
+#define PD_MAX_VOLTAGE_MV 20000
+
#endif /* !__ASSEMBLER__ */
#endif /* __CROS_EC_BOARD_H */
diff --git a/board/dratini/board.h b/board/dratini/board.h
index e8d0a9affa..bdf50e7a2c 100644
--- a/board/dratini/board.h
+++ b/board/dratini/board.h
@@ -173,6 +173,12 @@ extern const int keyboard_factory_scan_pins[][2];
extern const int keyboard_factory_scan_pins_used;
#endif
+
+#define PD_OPERATING_POWER_MW 15000
+#define PD_MAX_POWER_MW 60000
+#define PD_MAX_CURRENT_MA 3000
+#define PD_MAX_VOLTAGE_MV 20000
+
#endif /* !__ASSEMBLER__ */
#endif /* __CROS_EC_BOARD_H */
diff --git a/board/hatch/board.h b/board/hatch/board.h
index a2d0533a38..dca25f6cf9 100644
--- a/board/hatch/board.h
+++ b/board/hatch/board.h
@@ -173,6 +173,12 @@ enum battery_type {
BATTERY_TYPE_COUNT,
};
+
+#define PD_OPERATING_POWER_MW 15000
+#define PD_MAX_POWER_MW 60000
+#define PD_MAX_CURRENT_MA 3000
+#define PD_MAX_VOLTAGE_MV 20000
+
#endif /* !__ASSEMBLER__ */
#endif /* __CROS_EC_BOARD_H */
diff --git a/board/helios/board.h b/board/helios/board.h
index e1445394c3..b039bdb43a 100644
--- a/board/helios/board.h
+++ b/board/helios/board.h
@@ -150,6 +150,12 @@ enum battery_type {
BATTERY_TYPE_COUNT,
};
+
+#define PD_OPERATING_POWER_MW 15000
+#define PD_MAX_POWER_MW 60000
+#define PD_MAX_CURRENT_MA 3000
+#define PD_MAX_VOLTAGE_MV 20000
+
#endif /* !__ASSEMBLER__ */
#endif /* __CROS_EC_BOARD_H */
diff --git a/board/jinlon/board.h b/board/jinlon/board.h
index 34200c41be..9f831006ad 100644
--- a/board/jinlon/board.h
+++ b/board/jinlon/board.h
@@ -172,6 +172,12 @@ enum battery_type {
BATTERY_TYPE_COUNT,
};
+
+#define PD_OPERATING_POWER_MW 15000
+#define PD_MAX_POWER_MW 60000
+#define PD_MAX_CURRENT_MA 3000
+#define PD_MAX_VOLTAGE_MV 20000
+
#ifdef CONFIG_KEYBOARD_FACTORY_TEST
extern const int keyboard_factory_scan_pins[][2];
extern const int keyboard_factory_scan_pins_used;
diff --git a/board/kindred/board.h b/board/kindred/board.h
index e6cd7aa535..2c4875a8de 100644
--- a/board/kindred/board.h
+++ b/board/kindred/board.h
@@ -176,6 +176,12 @@ enum battery_type {
extern const int keyboard_factory_scan_pins[][2];
extern const int keyboard_factory_scan_pins_used;
+
+#define PD_OPERATING_POWER_MW 15000
+#define PD_MAX_POWER_MW 60000
+#define PD_MAX_CURRENT_MA 3000
+#define PD_MAX_VOLTAGE_MV 20000
+
#endif /* !__ASSEMBLER__ */
#endif /* __CROS_EC_BOARD_H */
diff --git a/board/kohaku/board.h b/board/kohaku/board.h
index 135ad10dbe..62e32d95d4 100644
--- a/board/kohaku/board.h
+++ b/board/kohaku/board.h
@@ -189,6 +189,11 @@ enum battery_type {
BATTERY_TYPE_COUNT,
};
+#define PD_OPERATING_POWER_MW 15000
+#define PD_MAX_POWER_MW 60000
+#define PD_MAX_CURRENT_MA 3000
+#define PD_MAX_VOLTAGE_MV 20000
+
#endif /* !__ASSEMBLER__ */
#endif /* __CROS_EC_BOARD_H */
diff --git a/board/stryke/board.h b/board/stryke/board.h
index e1b7ce7414..876e19f466 100644
--- a/board/stryke/board.h
+++ b/board/stryke/board.h
@@ -173,6 +173,11 @@ enum battery_type {
BATTERY_TYPE_COUNT,
};
+#define PD_OPERATING_POWER_MW 27000
+#define PD_MAX_POWER_MW 65000
+#define PD_MAX_CURRENT_MA 3250
+#define PD_MAX_VOLTAGE_MV 20000
+
#endif /* !__ASSEMBLER__ */
#endif /* __CROS_EC_BOARD_H */