summaryrefslogtreecommitdiff
path: root/board/corori2
diff options
context:
space:
mode:
Diffstat (limited to 'board/corori2')
-rw-r--r--board/corori2/battery.c2
-rw-r--r--board/corori2/board.c125
-rw-r--r--board/corori2/board.h61
-rw-r--r--board/corori2/build.mk2
-rw-r--r--board/corori2/cbi_ssfc.c6
-rw-r--r--board/corori2/cbi_ssfc.h3
-rw-r--r--board/corori2/ec.tasklist2
-rw-r--r--board/corori2/gpio.inc2
-rw-r--r--board/corori2/led.c13
-rw-r--r--board/corori2/usb_pd_policy.c6
10 files changed, 105 insertions, 117 deletions
diff --git a/board/corori2/battery.c b/board/corori2/battery.c
index 1263e4cef0..a59663c751 100644
--- a/board/corori2/battery.c
+++ b/board/corori2/battery.c
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*
diff --git a/board/corori2/board.c b/board/corori2/board.c
index 0ccd3c3ebc..efebc3af2e 100644
--- a/board/corori2/board.c
+++ b/board/corori2/board.c
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
@@ -44,8 +44,8 @@
#include "usb_pd.h"
#include "usb_pd_tcpm.h"
-#define CPRINTS(format, args...) cprints(CC_USBCHARGE, format, ## args)
-#define CPRINTF(format, args...) cprintf(CC_USBCHARGE, format, ## args)
+#define CPRINTS(format, args...) cprints(CC_USBCHARGE, format, ##args)
+#define CPRINTF(format, args...) cprintf(CC_USBCHARGE, format, ##args)
#define INT_RECHECK_US 5000
@@ -85,7 +85,6 @@ static void usb_c0_interrupt(enum gpio_signal s)
/* Check the line again in 5ms */
hook_call_deferred(&check_c0_line_data, INT_RECHECK_US);
-
}
/* C1 interrupt line shared by BC 1.2, TCPC, and charger */
@@ -120,7 +119,6 @@ static void sub_usb_c1_interrupt(enum gpio_signal s)
/* Check the line again in 5ms */
hook_call_deferred(&check_c1_line_data, INT_RECHECK_US);
-
}
static void sub_hdmi_hpd_interrupt(enum gpio_signal s)
@@ -167,22 +165,22 @@ BUILD_ASSERT(ARRAY_SIZE(adc_channels) == ADC_CH_COUNT);
/* Thermistors */
const struct temp_sensor_t temp_sensors[] = {
- [ADC_TEMP_SENSOR_1] = {.name = "Memory",
- .type = TEMP_SENSOR_TYPE_BOARD,
- .read = get_temp_3v3_51k1_47k_4050b,
- .idx = ADC_TEMP_SENSOR_1},
- [ADC_TEMP_SENSOR_2] = {.name = "Charger",
- .type = TEMP_SENSOR_TYPE_BOARD,
- .read = get_temp_3v3_51k1_47k_4050b,
- .idx = ADC_TEMP_SENSOR_2},
+ [ADC_TEMP_SENSOR_1] = { .name = "Memory",
+ .type = TEMP_SENSOR_TYPE_BOARD,
+ .read = get_temp_3v3_51k1_47k_4050b,
+ .idx = ADC_TEMP_SENSOR_1 },
+ [ADC_TEMP_SENSOR_2] = { .name = "Charger",
+ .type = TEMP_SENSOR_TYPE_BOARD,
+ .read = get_temp_3v3_51k1_47k_4050b,
+ .idx = ADC_TEMP_SENSOR_2 },
};
BUILD_ASSERT(ARRAY_SIZE(temp_sensors) == TEMP_SENSOR_COUNT);
/*
* TODO(b/202062363): Remove when clang is fixed.
*/
-#define THERMAL_MEMORY \
- { \
+#define THERMAL_MEMORY \
+ { \
.temp_host = { \
[EC_TEMP_THRESH_WARN] = 0, \
[EC_TEMP_THRESH_HIGH] = C_TO_K(85), \
@@ -200,8 +198,8 @@ __maybe_unused static const struct ec_thermal_config thermal_memory =
/*
* TODO(b/202062363): Remove when clang is fixed.
*/
-#define THERMAL_CHARGER \
- { \
+#define THERMAL_CHARGER \
+ { \
.temp_host = { \
[EC_TEMP_THRESH_WARN] = 0, \
[EC_TEMP_THRESH_HIGH] = C_TO_K(80), \
@@ -234,16 +232,17 @@ void board_init(void)
if (get_cbi_fw_config_db() == DB_1A_HDMI) {
/* Disable i2c on HDMI pins */
- gpio_config_pin(MODULE_I2C,
- GPIO_EC_I2C_SUB_C1_SDA_HDMI_HPD_ODL, 0);
- gpio_config_pin(MODULE_I2C,
- GPIO_EC_I2C_SUB_C1_SCL_HDMI_EN_ODL, 0);
+ gpio_config_pin(MODULE_I2C, GPIO_EC_I2C_SUB_C1_SDA_HDMI_HPD_ODL,
+ 0);
+ gpio_config_pin(MODULE_I2C, GPIO_EC_I2C_SUB_C1_SCL_HDMI_EN_ODL,
+ 0);
/* Set HDMI and sub-rail enables to output */
gpio_set_flags(GPIO_EC_I2C_SUB_C1_SCL_HDMI_EN_ODL,
chipset_in_state(CHIPSET_STATE_ON) ?
- GPIO_ODR_LOW : GPIO_ODR_HIGH);
- gpio_set_flags(GPIO_SUB_C1_INT_EN_RAILS_ODL, GPIO_ODR_HIGH);
+ GPIO_ODR_LOW :
+ GPIO_ODR_HIGH);
+ gpio_set_flags(GPIO_SUB_C1_INT_EN_RAILS_ODL, GPIO_ODR_HIGH);
/* Select HDMI option */
gpio_set_level(GPIO_HDMI_SEL_L, 0);
@@ -252,8 +251,7 @@ void board_init(void)
gpio_enable_interrupt(GPIO_EC_I2C_SUB_C1_SDA_HDMI_HPD_ODL);
} else {
/* Set SDA as an input */
- gpio_set_flags(GPIO_EC_I2C_SUB_C1_SDA_HDMI_HPD_ODL,
- GPIO_INPUT);
+ gpio_set_flags(GPIO_EC_I2C_SUB_C1_SDA_HDMI_HPD_ODL, GPIO_INPUT);
/* Enable C1 interrupt and check if it needs processing */
gpio_enable_interrupt(GPIO_SUB_C1_INT_EN_RAILS_ODL);
@@ -320,7 +318,7 @@ static void reconfigure_5v_gpio(void)
gpio_set_flags(GPIO_VOLUP_BTN_ODL, GPIO_OUT_LOW);
}
}
-DECLARE_HOOK(HOOK_INIT, reconfigure_5v_gpio, HOOK_PRIO_INIT_I2C+1);
+DECLARE_HOOK(HOOK_INIT, reconfigure_5v_gpio, HOOK_PRIO_INIT_I2C + 1);
#endif /* BOARD_WADDLEDOO */
static void set_5v_gpio(int level)
@@ -361,10 +359,9 @@ __override void board_power_5v_enable(int enable)
gpio_set_level(GPIO_SUB_C1_INT_EN_RAILS_ODL, !enable);
} else {
if (isl923x_set_comparator_inversion(1, !!enable))
- CPRINTS("Failed to %sable sub rails!", enable ?
- "en" : "dis");
+ CPRINTS("Failed to %sable sub rails!",
+ enable ? "en" : "dis");
}
-
}
__override uint8_t board_get_usb_pd_port_count(void)
@@ -389,13 +386,11 @@ int board_is_sourcing_vbus(int port)
tcpc_read(port, TCPC_REG_POWER_STATUS, &regval);
return !!(regval & TCPC_REG_POWER_STATUS_SOURCING_VBUS);
-
}
int board_set_active_charge_port(int port)
{
- int is_real_port = (port >= 0 &&
- port < board_get_usb_pd_port_count());
+ int is_real_port = (port >= 0 && port < board_get_usb_pd_port_count());
int i;
int old_port;
@@ -459,8 +454,8 @@ int board_set_active_charge_port(int port)
return EC_SUCCESS;
}
-void board_set_charge_limit(int port, int supplier, int charge_ma,
- int max_ma, int charge_mv)
+void board_set_charge_limit(int port, int supplier, int charge_ma, int max_ma,
+ int charge_mv)
{
int icl = MAX(charge_ma, CONFIG_CHARGER_INPUT_CURRENT);
@@ -485,17 +480,13 @@ static struct mutex g_lid_mutex;
static struct mutex g_base_mutex;
/* Matrices to rotate accelerometers into the standard reference. */
-static const mat33_fp_t lid_standard_ref = {
- { 0, FLOAT_TO_FP(1), 0},
- { FLOAT_TO_FP(-1), 0, 0},
- { 0, 0, FLOAT_TO_FP(1)}
-};
+static const mat33_fp_t lid_standard_ref = { { 0, FLOAT_TO_FP(1), 0 },
+ { FLOAT_TO_FP(-1), 0, 0 },
+ { 0, 0, FLOAT_TO_FP(1) } };
-static const mat33_fp_t base_standard_ref = {
- { 0, FLOAT_TO_FP(1), 0},
- { FLOAT_TO_FP(-1), 0, 0},
- { 0, 0, FLOAT_TO_FP(1)}
-};
+static const mat33_fp_t base_standard_ref = { { 0, FLOAT_TO_FP(1), 0 },
+ { FLOAT_TO_FP(-1), 0, 0 },
+ { 0, 0, FLOAT_TO_FP(1) } };
static struct accelgyro_saved_data_t g_bma253_data;
static struct bmi_drv_data_t g_bmi160_data;
@@ -571,9 +562,8 @@ struct motion_sensor_t motion_sensors[] = {
const unsigned int motion_sensor_count = ARRAY_SIZE(motion_sensors);
-__override void ocpc_get_pid_constants(int *kp, int *kp_div,
- int *ki, int *ki_div,
- int *kd, int *kd_div)
+__override void ocpc_get_pid_constants(int *kp, int *kp_div, int *ki,
+ int *ki_div, int *kd, int *kd_div)
{
*kp = 1;
*kp_div = 20;
@@ -660,25 +650,34 @@ const struct tcpc_config_t tcpc_config[CONFIG_USB_PD_PORT_MAX_COUNT] = {
},
};
-const struct usb_mux usbc1_retimer = {
- .usb_port = 1,
- .i2c_port = I2C_PORT_SUB_USB_C1,
- .i2c_addr_flags = NB7V904M_I2C_ADDR0,
- .driver = &nb7v904m_usb_redriver_drv,
+const struct usb_mux_chain usbc1_retimer = {
+ .mux =
+ &(const struct usb_mux){
+ .usb_port = 1,
+ .i2c_port = I2C_PORT_SUB_USB_C1,
+ .i2c_addr_flags = NB7V904M_I2C_ADDR0,
+ .driver = &nb7v904m_usb_redriver_drv,
+ },
};
-const struct usb_mux usb_muxes[CONFIG_USB_PD_PORT_MAX_COUNT] = {
+const struct usb_mux_chain usb_muxes[CONFIG_USB_PD_PORT_MAX_COUNT] = {
{
- .usb_port = 0,
- .i2c_port = I2C_PORT_USB_C0,
- .i2c_addr_flags = PI3USB3X532_I2C_ADDR0,
- .driver = &pi3usb3x532_usb_mux_driver,
+ .mux =
+ &(const struct usb_mux){
+ .usb_port = 0,
+ .i2c_port = I2C_PORT_USB_C0,
+ .i2c_addr_flags = PI3USB3X532_I2C_ADDR0,
+ .driver = &pi3usb3x532_usb_mux_driver,
+ },
},
{
- .usb_port = 1,
- .i2c_port = I2C_PORT_SUB_USB_C1,
- .i2c_addr_flags = PI3USB3X532_I2C_ADDR0,
- .driver = &pi3usb3x532_usb_mux_driver,
- .next_mux = &usbc1_retimer,
+ .mux =
+ &(const struct usb_mux){
+ .usb_port = 1,
+ .i2c_port = I2C_PORT_SUB_USB_C1,
+ .i2c_addr_flags = PI3USB3X532_I2C_ADDR0,
+ .driver = &pi3usb3x532_usb_mux_driver,
+ },
+ .next = &usbc1_retimer,
}
};
@@ -704,7 +703,7 @@ uint16_t tcpc_get_alert_status(void)
}
if (board_get_usb_pd_port_count() > 1 &&
- !gpio_get_level(GPIO_SUB_C1_INT_EN_RAILS_ODL)) {
+ !gpio_get_level(GPIO_SUB_C1_INT_EN_RAILS_ODL)) {
if (!tcpc_read16(1, TCPC_REG_ALERT, &regval)) {
/* TCPCI spec Rev 1.0 says to ignore bits 14:12. */
if (!(tcpc_config[1].flags & TCPC_FLAGS_TCPCI_REV2_0))
diff --git a/board/corori2/board.h b/board/corori2/board.h
index 1e24d5eb71..0fc4423020 100644
--- a/board/corori2/board.h
+++ b/board/corori2/board.h
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
@@ -19,7 +19,7 @@
/* Save some flash space */
#define CONFIG_CHIP_INIT_ROM_REGION
-#undef CONFIG_CONSOLE_CMDHELP
+#undef CONFIG_CONSOLE_CMDHELP
#define CONFIG_DEBUG_ASSERT_BRIEF
#define CONFIG_USB_PD_DEBUG_LEVEL 2
@@ -35,11 +35,14 @@
/* Charger */
#define CONFIG_CHARGER_RAA489000
+#define PD_MAX_VOLTAGE_MV 20000
#define CONFIG_CHARGER_SENSE_RESISTOR_AC 10
#define CONFIG_CHARGER_SENSE_RESISTOR 10
-#define CONFIG_OCPC_DEF_RBATT_MOHMS 22 /* R_DS(on) 11.6mOhm + 10mOhm sns rstr */
+#define CONFIG_OCPC_DEF_RBATT_MOHMS \
+ 22 /* R_DS(on) 11.6mOhm + 10mOhm sns rstr \
+ */
#define CONFIG_OCPC
-#undef CONFIG_CHARGER_SINGLE_CHIP
+#undef CONFIG_CHARGER_SINGLE_CHIP
#undef CONFIG_USB_PD_TCPC_LPM_EXIT_DEBOUNCE
#define CONFIG_USB_PD_TCPC_LPM_EXIT_DEBOUNCE (100 * MSEC)
@@ -68,7 +71,7 @@
/* PWM */
#define CONFIG_PWM
-#define NPCX7_PWM1_SEL 1 /* GPIO C2 is used as PWM1. */
+#define NPCX7_PWM1_SEL 1 /* GPIO C2 is used as PWM1. */
/* Temp sensor */
#define CONFIG_TEMP_SENSOR
@@ -98,23 +101,22 @@
#undef PD_POWER_SUPPLY_TURN_OFF_DELAY
#undef CONFIG_USBC_VCONN_SWAP_DELAY_US
/* 20% margin added for these timings */
-#define PD_POWER_SUPPLY_TURN_ON_DELAY 13080 /* us */
-#define PD_POWER_SUPPLY_TURN_OFF_DELAY 16080 /* us */
+#define PD_POWER_SUPPLY_TURN_ON_DELAY 13080 /* us */
+#define PD_POWER_SUPPLY_TURN_OFF_DELAY 16080 /* us */
#undef CONFIG_USBC_VCONN_SWAP_DELAY_US
-#define CONFIG_USBC_VCONN_SWAP_DELAY_US 787 /* us */
-
+#define CONFIG_USBC_VCONN_SWAP_DELAY_US 787 /* us */
/* I2C configuration */
-#define I2C_PORT_EEPROM NPCX_I2C_PORT7_0
-#define I2C_PORT_BATTERY NPCX_I2C_PORT5_0
-#define I2C_PORT_SENSOR NPCX_I2C_PORT0_0
-#define I2C_PORT_USB_C0 NPCX_I2C_PORT1_0
+#define I2C_PORT_EEPROM NPCX_I2C_PORT7_0
+#define I2C_PORT_BATTERY NPCX_I2C_PORT5_0
+#define I2C_PORT_SENSOR NPCX_I2C_PORT0_0
+#define I2C_PORT_USB_C0 NPCX_I2C_PORT1_0
#define I2C_PORT_SUB_USB_C1 NPCX_I2C_PORT2_0
-#define I2C_PORT_USB_MUX I2C_PORT_USB_C0
+#define I2C_PORT_USB_MUX I2C_PORT_USB_C0
/* TODO(b:147440290): Need to handle multiple charger ICs */
-#define I2C_PORT_CHARGER I2C_PORT_USB_C0
+#define I2C_PORT_CHARGER I2C_PORT_USB_C0
-#define I2C_PORT_ACCEL I2C_PORT_SENSOR
+#define I2C_PORT_ACCEL I2C_PORT_SENSOR
#define I2C_ADDR_EEPROM_FLAGS 0x50 /* 7b address */
@@ -128,13 +130,13 @@
#define GPIO_EC_I2C_SUB_USB_C1_SDA GPIO_EC_I2C_SUB_C1_SDA_HDMI_HPD_ODL
/* Sensors */
-#define CONFIG_ACCEL_BMA255 /* Lid accel */
-#define CONFIG_ACCELGYRO_BMI160 /* Base accel */
+#define CONFIG_ACCEL_BMA255 /* Lid accel */
+#define CONFIG_ACCELGYRO_BMI160 /* Base accel */
/* Lid operates in forced mode, base in FIFO */
#define CONFIG_ACCEL_FORCE_MODE_MASK BIT(LID_ACCEL)
#define CONFIG_ACCEL_FIFO
-#define CONFIG_ACCEL_FIFO_SIZE 256 /* Must be a power of 2 */
+#define CONFIG_ACCEL_FIFO_SIZE 256 /* Must be a power of 2 */
#define CONFIG_ACCEL_FIFO_THRES (CONFIG_ACCEL_FIFO_SIZE / 3)
#define CONFIG_ACCELGYRO_BMI160_INT_EVENT \
@@ -161,25 +163,16 @@ enum chg_id {
};
enum adc_channel {
- ADC_TEMP_SENSOR_1, /* ADC0 */
- ADC_TEMP_SENSOR_2, /* ADC1 */
- ADC_SUB_ANALOG, /* ADC2 */
- ADC_VSNS_PP3300_A, /* ADC9 */
+ ADC_TEMP_SENSOR_1, /* ADC0 */
+ ADC_TEMP_SENSOR_2, /* ADC1 */
+ ADC_SUB_ANALOG, /* ADC2 */
+ ADC_VSNS_PP3300_A, /* ADC9 */
ADC_CH_COUNT
};
-enum temp_sensor_id {
- TEMP_SENSOR_1,
- TEMP_SENSOR_2,
- TEMP_SENSOR_COUNT
-};
+enum temp_sensor_id { TEMP_SENSOR_1, TEMP_SENSOR_2, TEMP_SENSOR_COUNT };
-enum sensor_id {
- LID_ACCEL,
- BASE_ACCEL,
- BASE_GYRO,
- SENSOR_COUNT
-};
+enum sensor_id { LID_ACCEL, BASE_ACCEL, BASE_GYRO, SENSOR_COUNT };
enum pwm_channel {
PWM_CH_KBLIGHT,
diff --git a/board/corori2/build.mk b/board/corori2/build.mk
index af526189dd..1512a49379 100644
--- a/board/corori2/build.mk
+++ b/board/corori2/build.mk
@@ -1,5 +1,5 @@
# -*- makefile -*-
-# Copyright 2021 The Chromium OS Authors. All rights reserved.
+# Copyright 2021 The ChromiumOS Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
#
diff --git a/board/corori2/cbi_ssfc.c b/board/corori2/cbi_ssfc.c
index c4b859f133..81f3ee0dad 100644
--- a/board/corori2/cbi_ssfc.c
+++ b/board/corori2/cbi_ssfc.c
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
@@ -27,10 +27,10 @@ DECLARE_HOOK(HOOK_INIT, cbi_ssfc_init, HOOK_PRIO_FIRST);
enum ec_ssfc_base_sensor get_cbi_ssfc_base_sensor(void)
{
- return (enum ec_ssfc_base_sensor) cached_ssfc.base_sensor;
+ return (enum ec_ssfc_base_sensor)cached_ssfc.base_sensor;
}
enum ec_ssfc_lid_sensor get_cbi_ssfc_lid_sensor(void)
{
- return (enum ec_ssfc_lid_sensor) cached_ssfc.lid_sensor;
+ return (enum ec_ssfc_lid_sensor)cached_ssfc.lid_sensor;
}
diff --git a/board/corori2/cbi_ssfc.h b/board/corori2/cbi_ssfc.h
index 935049b6ae..bf8853a43a 100644
--- a/board/corori2/cbi_ssfc.h
+++ b/board/corori2/cbi_ssfc.h
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
@@ -56,5 +56,4 @@ enum ec_ssfc_base_sensor get_cbi_ssfc_base_sensor(void);
*/
enum ec_ssfc_lid_sensor get_cbi_ssfc_lid_sensor(void);
-
#endif /* _DEDEDE_CBI_SSFC__H_ */
diff --git a/board/corori2/ec.tasklist b/board/corori2/ec.tasklist
index d4fb416bce..29666dd959 100644
--- a/board/corori2/ec.tasklist
+++ b/board/corori2/ec.tasklist
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
diff --git a/board/corori2/gpio.inc b/board/corori2/gpio.inc
index 78d41aab16..63b16a1bc3 100644
--- a/board/corori2/gpio.inc
+++ b/board/corori2/gpio.inc
@@ -1,6 +1,6 @@
/* -*- mode:c -*-
*
- * Copyright 2021 The Chromium OS Authors. All rights reserved.
+ * Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
diff --git a/board/corori2/led.c b/board/corori2/led.c
index 3c27bf0f8e..71a8159a07 100644
--- a/board/corori2/led.c
+++ b/board/corori2/led.c
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
@@ -20,13 +20,10 @@ const int supported_led_ids_count = ARRAY_SIZE(supported_led_ids);
* both LEDs being off.
*/
struct pwm_led_color_map led_color_map[EC_LED_COLOR_COUNT] = {
- /* Amber, White */
- [EC_LED_COLOR_RED] = { 0, 0 },
- [EC_LED_COLOR_GREEN] = { 0, 0 },
- [EC_LED_COLOR_BLUE] = { 0, 0 },
- [EC_LED_COLOR_YELLOW] = { 0, 0 },
- [EC_LED_COLOR_WHITE] = { 0, 100 },
- [EC_LED_COLOR_AMBER] = { 100, 0 },
+ /* Amber, White */
+ [EC_LED_COLOR_RED] = { 0, 0 }, [EC_LED_COLOR_GREEN] = { 0, 0 },
+ [EC_LED_COLOR_BLUE] = { 0, 0 }, [EC_LED_COLOR_YELLOW] = { 0, 0 },
+ [EC_LED_COLOR_WHITE] = { 0, 100 }, [EC_LED_COLOR_AMBER] = { 100, 0 },
};
/* One logical LED with amber and white channels. */
diff --git a/board/corori2/usb_pd_policy.c b/board/corori2/usb_pd_policy.c
index 15faf41ffc..83c09bb99e 100644
--- a/board/corori2/usb_pd_policy.c
+++ b/board/corori2/usb_pd_policy.c
@@ -1,4 +1,4 @@
-/* Copyright 2021 The Chromium OS Authors. All rights reserved.
+/* Copyright 2021 The ChromiumOS Authors
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
@@ -11,8 +11,8 @@
#include "driver/tcpm/tcpci.h"
#include "usb_pd.h"
-#define CPRINTF(format, args...) cprintf(CC_USBPD, format, ## args)
-#define CPRINTS(format, args...) cprints(CC_USBPD, format, ## args)
+#define CPRINTF(format, args...) cprintf(CC_USBPD, format, ##args)
+#define CPRINTS(format, args...) cprints(CC_USBPD, format, ##args)
int pd_check_vconn_swap(int port)
{