summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorxiong.huang <xiong.huang@bitland.corp-partner.google.com>2020-06-16 11:36:00 +0800
committerCommit Bot <commit-bot@chromium.org>2020-06-19 12:27:01 +0000
commite68e6dba5d98342dbad0d0c226b1981aa8d612a7 (patch)
treecf4aac26e79255cfc2304538beab6a0937996da6
parent4df277da323b87bebb27209971670e6862d6f435 (diff)
downloadchrome-ec-e68e6dba5d98342dbad0d0c226b1981aa8d612a7.tar.gz
boten: reconfigure GPIOs
Remove GPF4, GPF5, GPC7, GPF1, GPL2. Configure GPL6 and GPE6, which control MB and DB USB-A power supply. GPE0 and GPE7 are used for DB HDMI. BUG=b:157626290, b:158658777 BRANCH=none TEST=make buildall -j Signed-off-by: xiong.huang <xiong.huang@bitland.corp-partner.google.com> Change-Id: Idb04e9d93d30c4ff8792dc92e92888a771bd02ba Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/2245588 Reviewed-by: Diana Z <dzigterman@chromium.org>
-rw-r--r--board/boten/board.c12
-rw-r--r--board/boten/board.h5
-rw-r--r--board/boten/gpio.inc16
3 files changed, 9 insertions, 24 deletions
diff --git a/board/boten/board.c b/board/boten/board.c
index f1ff1ca721..c33270a048 100644
--- a/board/boten/board.c
+++ b/board/boten/board.c
@@ -13,7 +13,6 @@
#include "driver/accelgyro_lsm6dsm.h"
#include "driver/bc12/pi3usb9201.h"
#include "driver/charger/isl923x.h"
-#include "driver/sync.h"
#include "driver/temp_sensor/thermistor.h"
#include "driver/tcpm/raa489000.h"
#include "driver/tcpm/tcpci.h"
@@ -312,17 +311,6 @@ struct motion_sensor_t motion_sensors[] = {
.min_frequency = LSM6DSM_ODR_MIN_VAL,
.max_frequency = LSM6DSM_ODR_MAX_VAL,
},
- [VSYNC] = {
- .name = "Camera VSYNC",
- .active_mask = SENSOR_ACTIVE_S0,
- .chip = MOTIONSENSE_CHIP_GPIO,
- .type = MOTIONSENSE_TYPE_SYNC,
- .location = MOTIONSENSE_LOC_CAMERA,
- .drv = &sync_drv,
- .default_range = 0,
- .min_frequency = 0,
- .max_frequency = 1,
- },
};
const unsigned int motion_sensor_count = ARRAY_SIZE(motion_sensors);
diff --git a/board/boten/board.h b/board/boten/board.h
index 40de5495b9..edc802cbbc 100644
--- a/board/boten/board.h
+++ b/board/boten/board.h
@@ -34,7 +34,6 @@
/* Sensors */
#define CONFIG_ACCEL_LIS2DE /* Lid accel */
#define CONFIG_ACCELGYRO_LSM6DSM /* Base accel */
-#define CONFIG_SYNC /* Camera VSYNC */
/* Sensors without hardware FIFO are in forced mode */
#define CONFIG_ACCEL_FORCE_MODE_MASK BIT(LID_ACCEL)
@@ -50,9 +49,6 @@
#define CONFIG_LID_ANGLE_SENSOR_BASE BASE_ACCEL
#define CONFIG_LID_ANGLE_SENSOR_LID LID_ACCEL
-#define CONFIG_SYNC_INT_EVENT \
- TASK_EVENT_MOTION_SENSOR_INTERRUPT(VSYNC)
-
#define CONFIG_TABLET_MODE
#define CONFIG_TABLET_MODE_SWITCH
#define CONFIG_GMR_TABLET_MODE
@@ -97,7 +93,6 @@ enum sensor_id {
LID_ACCEL,
BASE_ACCEL,
BASE_GYRO,
- VSYNC,
SENSOR_COUNT
};
diff --git a/board/boten/gpio.inc b/board/boten/gpio.inc
index 03c65c5dd2..72369d9c70 100644
--- a/board/boten/gpio.inc
+++ b/board/boten/gpio.inc
@@ -38,7 +38,6 @@ GPIO_INT(LID_360_L, PIN(A, 7), GPIO_INT_BOTH, gmr_tablet_switch_isr)
GPIO_INT(VOLDN_BTN_ODL, PIN(I, 6), GPIO_INT_BOTH, button_interrupt)
GPIO_INT(VOLUP_BTN_ODL, PIN(I, 7), GPIO_INT_BOTH, button_interrupt)
GPIO_INT(BASE_SIXAXIS_INT_L, PIN(J, 0), GPIO_INT_FALLING | GPIO_SEL_1P8V, lsm6dsm_interrupt)
-GPIO_INT(CAM_EC_VSYNC, PIN(C, 7), GPIO_INT_RISING, sync_interrupt)
GPIO_INT(EC_WP_OD, PIN(A, 6), GPIO_INT_BOTH, switch_interrupt)
/* Power sequence GPIOs */
@@ -76,9 +75,13 @@ GPIO(EC_I2C_USB_C0_SCL, PIN(A, 4), GPIO_INPUT)
GPIO(EC_I2C_USB_C0_SDA, PIN(A, 5), GPIO_INPUT)
/* USB pins */
+GPIO(EN_USB_A0_VBUS, PIN(L, 6), GPIO_OUT_HIGH)
+GPIO(EN_USB_A1_VBUS, PIN(E, 6), GPIO_OUT_LOW)
GPIO(EC_AP_USB_C0_HPD, PIN(L, 4), GPIO_OUT_LOW)
GPIO(EC_AP_USB_C1_HDMI_HPD, PIN(K, 7), GPIO_OUT_LOW)
GPIO(HDMI_SEL_L, PIN(C, 6), GPIO_OUT_HIGH)
+GPIO(HDMI_EN_SUB_ODL, PIN(E, 0), GPIO_OUT_LOW)
+GPIO(HDMI_HPD_SUB_ODL, PIN(E, 7), GPIO_INPUT)
/* MKBP event synchronization */
GPIO(EC_AP_MKBP_INT_L, PIN(L, 5), GPIO_ODR_HIGH)
@@ -86,8 +89,6 @@ GPIO(EC_AP_MKBP_INT_L, PIN(L, 5), GPIO_ODR_HIGH)
/* Misc pins which will run to the I/O board */
GPIO(EC_SUB_IO_1_1, PIN(L, 3), GPIO_INPUT)
GPIO(EC_SUB_IO_1_2, PIN(F, 0), GPIO_INPUT)
-GPIO(EC_SUB_IO_2_1, PIN(F, 1), GPIO_INPUT)
-GPIO(EC_SUB_IO_2_2, PIN(L, 2), GPIO_INPUT)
/* Misc */
GPIO(EN_BL_OD, PIN(K, 4), GPIO_OUT_LOW)
@@ -103,9 +104,10 @@ GPIO(ECH1_PACKET_MODE, PIN(H, 1), GPIO_OUT_LOW)
GPIO(GPIOC0_NC, PIN(C, 0), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOC3_NC, PIN(C, 3), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOC4_NC, PIN(C, 4), GPIO_INPUT | GPIO_PULL_DOWN)
-GPIO(GPIOE0_NC, PIN(E, 0), GPIO_INPUT | GPIO_PULL_DOWN)
-GPIO(GPIOE6_NC, PIN(E, 6), GPIO_INPUT | GPIO_PULL_DOWN)
-GPIO(GPIOE7_NC, PIN(E, 7), GPIO_INPUT | GPIO_PULL_DOWN)
+GPIO(GPIOC7_NC, PIN(C, 7), GPIO_INPUT | GPIO_PULL_DOWN)
+GPIO(GPIOF1_NC, PIN(F, 1), GPIO_INPUT | GPIO_PULL_DOWN)
+GPIO(GPIOF4_NC, PIN(F, 4), GPIO_INPUT | GPIO_PULL_DOWN)
+GPIO(GPIOF5_NC, PIN(F, 5), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOG3_NC, PIN(G, 3), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOG4_NC, PIN(G, 4), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOG5_NC, PIN(G, 5), GPIO_INPUT | GPIO_PULL_DOWN)
@@ -116,7 +118,7 @@ GPIO(GPIOH6_NC, PIN(H, 6), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOJ4_NC, PIN(J, 4), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOJ5_NC, PIN(J, 5), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOJ6_NC, PIN(J, 6), GPIO_INPUT | GPIO_PULL_DOWN)
-GPIO(GPIOL6_NC, PIN(L, 6), GPIO_INPUT | GPIO_PULL_DOWN)
+GPIO(GPIOL2_NC, PIN(L, 2), GPIO_INPUT | GPIO_PULL_DOWN)
GPIO(GPIOM6_NC, PIN(M, 6), GPIO_INPUT | GPIO_PULL_DOWN)
/* Alternate functions GPIO definitions */