summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlu.zhang <lu.zhang@bitland.corp-partner.google.com>2019-08-06 13:56:54 +0800
committerCommit Bot <commit-bot@chromium.org>2019-08-08 02:21:37 +0000
commit8ccef7f1cb049f0c7d137ebd23753e9f8b90fc5a (patch)
tree4d22bb80b3e8ddde1726c9f673bea6072a82691f
parent0fa5ade226eafe3e94b3249257b4f76444255314 (diff)
downloadchrome-ec-8ccef7f1cb049f0c7d137ebd23753e9f8b90fc5a.tar.gz
treeya: remove keyboard backlight
This CL removes keyboard backlight accordding to most recent treeya schematics. BRANCH=none BUG=b:138744661 TEST=builds Change-Id: I2a42b2dcb122ac1fd805f9f614d1b68c0b60d7ca Signed-off-by: lu.zhang <lu.zhang@bitland.corp-partner.google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1738526 Tested-by: Edward Hill <ecgh@chromium.org> Commit-Queue: Edward Hill <ecgh@chromium.org> Reviewed-by: Edward Hill <ecgh@chromium.org>
-rw-r--r--board/treeya/board.c21
-rw-r--r--board/treeya/board.h11
-rw-r--r--board/treeya/gpio.inc2
3 files changed, 3 insertions, 31 deletions
diff --git a/board/treeya/board.c b/board/treeya/board.c
index 12f985e727..421aa75970 100644
--- a/board/treeya/board.c
+++ b/board/treeya/board.c
@@ -15,7 +15,6 @@
#include "compile_time_macros.h"
#include "console.h"
#include "driver/accelgyro_bmi160.h"
-#include "driver/led/lm3630a.h"
#include "driver/ppc/sn5s330.h"
#include "driver/tcpm/anx74xx.h"
#include "driver/tcpm/ps8xxx.h"
@@ -97,20 +96,10 @@ const struct i2c_port_t i2c_ports[] = {
{"tcpc0", I2C_PORT_TCPC0, 400, GPIO_I2C1_SCL, GPIO_I2C1_SDA},
{"tcpc1", I2C_PORT_TCPC1, 400, GPIO_I2C2_SCL, GPIO_I2C2_SDA},
{"thermal", I2C_PORT_THERMAL, 400, GPIO_I2C3_SCL, GPIO_I2C3_SDA},
- {"kblight", I2C_PORT_KBLIGHT, 100, GPIO_I2C5_SCL, GPIO_I2C5_SDA},
{"sensor", I2C_PORT_SENSOR, 400, GPIO_I2C7_SCL, GPIO_I2C7_SDA},
};
const unsigned int i2c_ports_used = ARRAY_SIZE(i2c_ports);
-/* PWM channels. Must be in the exactly same order as in enum pwm_channel. */
-const struct pwm_t pwm_channels[] = {
- [PWM_CH_KBLIGHT] = {
- .channel = 5,
- .flags = PWM_CONFIG_DSLEEP,
- .freq = 100,
- },
-};
-BUILD_ASSERT(ARRAY_SIZE(pwm_channels) == PWM_CH_COUNT);
void board_update_sensor_config_from_sku(void)
{
@@ -240,13 +229,3 @@ void board_reset_pd_mcu(void)
board_set_tcpc_power_mode(USB_PD_PORT_ANX74XX, 1);
}
-static void board_kblight_init(void)
-{
- /*
- * Enable keyboard backlight. This needs to be done here because
- * the chip doesn't have power until PP3300_S0 comes up.
- */
- gpio_set_level(GPIO_KB_BL_EN, 1);
- lm3630a_poweron();
-}
-DECLARE_HOOK(HOOK_CHIPSET_RESUME, board_kblight_init, HOOK_PRIO_DEFAULT);
diff --git a/board/treeya/board.h b/board/treeya/board.h
index ee4fe59f6b..6962eaa3bb 100644
--- a/board/treeya/board.h
+++ b/board/treeya/board.h
@@ -25,10 +25,9 @@
#define CONFIG_LED_ONOFF_STATES
-#define I2C_PORT_KBLIGHT NPCX_I2C_PORT5_0
-
-/* KB backlight driver */
-#define CONFIG_LED_DRIVER_LM3630A
+/*Disable KBLIGTH*/
+#undef CONFIG_PWM
+#undef CONFIG_PWM_KBLIGHT
#define CONFIG_MKBP_USE_GPIO
@@ -53,10 +52,6 @@
#ifndef __ASSEMBLER__
-enum pwm_channel {
- PWM_CH_KBLIGHT = 0,
- PWM_CH_COUNT
-};
enum battery_type {
BATTERY_PANASONIC,
diff --git a/board/treeya/gpio.inc b/board/treeya/gpio.inc
index 47fe44dd2c..9571006b9b 100644
--- a/board/treeya/gpio.inc
+++ b/board/treeya/gpio.inc
@@ -42,7 +42,6 @@ GPIO(PCH_SYS_PWROK, PIN(D, 6), GPIO_OUT_LOW) /* Power OK to SOC */
GPIO(CPU_PROCHOT, PIN(3, 4), GPIO_INPUT | GPIO_SEL_1P8V) /* PROCHOT to SOC */
GPIO(APU_ALERT_L, PIN(A, 2), GPIO_INPUT) /* Alert to SOC */
GPIO(3AXIS_INT_L, PIN(5, 0), GPIO_INPUT | GPIO_SEL_1P8V) /* 3 Axis Accel */
-GPIO(KB_BL_EN, PIN(F, 2), GPIO_OUT_LOW) /* Enable KB Backlight */
GPIO(EC_INT_L, PIN(A, 4), GPIO_ODR_HIGH) /* Sensor MKBP event to SOC */
/* I2C pins - these will be reconfigured for alternate function below */
@@ -106,7 +105,6 @@ ALTERNATE(PIN_MASK(4, 0x30), 0, MODULE_ADC, 0) /* ADC0-1 */
ALTERNATE(PIN_MASK(4, 0x02), 0, MODULE_ADC, 0) /* ADC4 */
ALTERNATE(PIN_MASK(F, 0x02), 0, MODULE_ADC, 0) /* ADC8 */
ALTERNATE(PIN_MASK(F, 0x01), 0, MODULE_ADC, 0) /* ADC9 */
-ALTERNATE(PIN_MASK(B, 0x80), 0, MODULE_PWM, 0) /* KB Backlight */
/* Keyboard Pins */
ALTERNATE(PIN_MASK(3, 0x03), 0, MODULE_KEYBOARD_SCAN, GPIO_INPUT) /* KSI_00-01 */