From c50046ad633f1958107eead2b778422a2f33d7af Mon Sep 17 00:00:00 2001 From: Jeremy Bettis Date: Mon, 28 Nov 2022 10:00:45 -0700 Subject: board: Sort header files Sort all includes in board with the clang-format rules used by the zephyr project. BRANCH=None BUG=b:247100970 TEST=zmake build -a TEST=./twister --clobber -v -i TEST=make -j72 buildall_only runtests TEST=zmake compare-builds -a Signed-off-by: Jeremy Bettis Change-Id: I6ad72b167cbb768a64c338fa633eb4bf5a401897 Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/4060360 Reviewed-by: Tom Hughes Reviewed-by: Paul Fagerburg Tested-by: Jeremy Bettis Commit-Queue: Jeremy Bettis --- board/kuldax/board.c | 13 +++++++------ board/kuldax/fans.c | 2 +- board/kuldax/i2c.c | 1 - board/kuldax/pwm.c | 1 - board/kuldax/sensors.c | 4 ++-- board/kuldax/usbc_config.c | 10 +++++----- 6 files changed, 15 insertions(+), 16 deletions(-) (limited to 'board/kuldax') diff --git a/board/kuldax/board.c b/board/kuldax/board.c index b5aeaf96b7..922a7a3a75 100644 --- a/board/kuldax/board.c +++ b/board/kuldax/board.c @@ -2,8 +2,6 @@ * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ -#include - #include "adc.h" #include "builtin/assert.h" #include "button.h" @@ -13,18 +11,20 @@ #include "compile_time_macros.h" #include "console.h" #include "cros_board_info.h" +#include "driver/tcpm/tcpci.h" +#include "fw_config.h" #include "gpio.h" #include "gpio_signal.h" -#include "power_button.h" #include "hooks.h" #include "peripheral_charger.h" #include "power.h" +#include "power_button.h" #include "switch.h" #include "throttle_ap.h" #include "usbc_config.h" #include "usbc_ppc.h" -#include "driver/tcpm/tcpci.h" -#include "fw_config.h" + +#include /* Console output macros */ #define CPRINTF(format, args...) cprintf(CC_CHARGER, format, ##args) @@ -217,7 +217,8 @@ static void port_ocp_interrupt(enum gpio_signal signal) { hook_call_deferred(&update_5v_usage_data, 0); } -#include "gpio_list.h" /* Must come after other header files. */ +/* Must come after other header files and interrupt handler declarations */ +#include "gpio_list.h" /******************************************************************************/ /* diff --git a/board/kuldax/fans.c b/board/kuldax/fans.c index a2acd805f8..6e3740a894 100644 --- a/board/kuldax/fans.c +++ b/board/kuldax/fans.c @@ -8,8 +8,8 @@ #include "common.h" #include "compile_time_macros.h" #include "console.h" -#include "fan_chip.h" #include "fan.h" +#include "fan_chip.h" #include "hooks.h" #include "pwm.h" diff --git a/board/kuldax/i2c.c b/board/kuldax/i2c.c index b38080f6a5..e7868b4b08 100644 --- a/board/kuldax/i2c.c +++ b/board/kuldax/i2c.c @@ -5,7 +5,6 @@ #include "common.h" #include "compile_time_macros.h" - #include "i2c.h" /* I2C port map configuration */ diff --git a/board/kuldax/pwm.c b/board/kuldax/pwm.c index 9ad0a686cc..21f0fa3c98 100644 --- a/board/kuldax/pwm.c +++ b/board/kuldax/pwm.c @@ -4,7 +4,6 @@ */ #include "common.h" - #include "compile_time_macros.h" #include "hooks.h" #include "pwm.h" diff --git a/board/kuldax/sensors.c b/board/kuldax/sensors.c index a41d5be713..687bfe3851 100644 --- a/board/kuldax/sensors.c +++ b/board/kuldax/sensors.c @@ -3,12 +3,12 @@ * found in the LICENSE file. */ -#include "common.h" #include "adc_chip.h" +#include "common.h" #include "hooks.h" #include "temp_sensor.h" -#include "thermal.h" #include "temp_sensor/thermistor.h" +#include "thermal.h" /* ADC configuration */ const struct adc_t adc_channels[] = { diff --git a/board/kuldax/usbc_config.c b/board/kuldax/usbc_config.c index c0d34fc581..a485dfb326 100644 --- a/board/kuldax/usbc_config.c +++ b/board/kuldax/usbc_config.c @@ -3,9 +3,6 @@ * found in the LICENSE file. */ -#include -#include - #include "common.h" #include "compile_time_macros.h" #include "console.h" @@ -23,12 +20,15 @@ #include "task.h" #include "task_id.h" #include "timer.h" -#include "usbc_config.h" -#include "usbc_ppc.h" #include "usb_charge.h" #include "usb_mux.h" #include "usb_pd.h" #include "usb_pd_tcpm.h" +#include "usbc_config.h" +#include "usbc_ppc.h" + +#include +#include #define CPRINTF(format, args...) cprintf(CC_USBPD, format, ##args) #define CPRINTS(format, args...) cprints(CC_USBPD, format, ##args) -- cgit v1.2.1