summaryrefslogtreecommitdiff
path: root/board
diff options
context:
space:
mode:
authorRandall Spangler <rspangler@chromium.org>2013-07-11 13:43:13 -0700
committerChromeBot <chrome-bot@google.com>2013-07-11 16:51:39 -0700
commit6696843708b7e5cb83a6c061a76cf70cbfd2523f (patch)
treefd1f1b8948054b74a1da01be9210131c3e03451c /board
parenta26b0dbd747386c841a31144c7fdf07b68ccb811 (diff)
downloadchrome-ec-6696843708b7e5cb83a6c061a76cf70cbfd2523f.tar.gz
Move x86 backlight-enable passthru code to its own module
This code is not LM4-specific, it's x86-specific. So it doesn't belong in chip/lm4. Put it in its own module rather than leaving it in switch.c, since some x86 systems may need the power button state machine but not the backlight-enable passthru. BUG=chrome-os-partner:18343 BRANCH=none TEST=Quickly run a magnet over the lid switch; the backlight goes off and then back on. Change-Id: I72f7139b73f91539dcfbe6b5cb6d56587ab66fde Signed-off-by: Randall Spangler <rspangler@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/61595 Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Diffstat (limited to 'board')
-rw-r--r--board/falco/board.c4
-rw-r--r--board/falco/board.h1
-rw-r--r--board/link/board.c4
-rw-r--r--board/link/board.h1
-rw-r--r--board/peppy/board.c4
-rw-r--r--board/peppy/board.h1
-rw-r--r--board/slippy/board.c4
-rw-r--r--board/slippy/board.h1
-rw-r--r--board/wolf/board.c4
-rw-r--r--board/wolf/board.h1
10 files changed, 15 insertions, 10 deletions
diff --git a/board/falco/board.c b/board/falco/board.c
index f394244d63..b98d03f7b2 100644
--- a/board/falco/board.c
+++ b/board/falco/board.c
@@ -5,7 +5,7 @@
/* EC for Falco board configuration */
#include "adc.h"
-#include "board.h"
+#include "backlight.h"
#include "chip_temp_sensor.h"
#include "chipset_haswell.h"
#include "chipset_x86_common.h"
@@ -37,7 +37,7 @@ const struct gpio_info gpio_list[GPIO_COUNT] = {
{"AC_PRESENT", LM4_GPIO_H, (1<<3), GPIO_INT_BOTH,
extpower_interrupt},
{"PCH_BKLTEN", LM4_GPIO_M, (1<<3), GPIO_INT_BOTH,
- switch_interrupt},
+ backlight_interrupt},
{"PCH_SLP_S0_L", LM4_GPIO_G, (1<<6), GPIO_INT_BOTH,
x86_interrupt},
{"PCH_SLP_S3_L", LM4_GPIO_G, (1<<7), GPIO_INT_BOTH,
diff --git a/board/falco/board.h b/board/falco/board.h
index a2fbc8a47d..5a20099288 100644
--- a/board/falco/board.h
+++ b/board/falco/board.h
@@ -16,6 +16,7 @@
/* Optional features */
#define CONFIG_SMART_BATTERY
+#define CONFIG_BACKLIGHT_X86
#define CONFIG_BATTERY_FALCO
#define CONFIG_EXTPOWER_FALCO
#define CONFIG_BOARD_VERSION
diff --git a/board/link/board.c b/board/link/board.c
index 301140d9b9..62c7332d78 100644
--- a/board/link/board.c
+++ b/board/link/board.c
@@ -5,7 +5,7 @@
/* EC for Link board configuration */
#include "adc.h"
-#include "board.h"
+#include "backlight.h"
#include "chip_temp_sensor.h"
#include "chipset_ivybridge.h"
#include "chipset_x86_common.h"
@@ -41,7 +41,7 @@ const struct gpio_info gpio_list[GPIO_COUNT] = {
{"BOARD_VERSION2", LM4_GPIO_L, (1<<6), 0, NULL},
{"BOARD_VERSION3", LM4_GPIO_L, (1<<7), 0, NULL},
{"PCH_BKLTEN", LM4_GPIO_J, (1<<3), GPIO_INT_BOTH,
- switch_interrupt},
+ backlight_interrupt},
{"PCH_SLP_A_L", LM4_GPIO_G, (1<<5), GPIO_INT_BOTH,
x86_interrupt},
{"PCH_SLP_ME_CSW_DEV_L", LM4_GPIO_G, (1<<4), GPIO_INT_BOTH,
diff --git a/board/link/board.h b/board/link/board.h
index 711c36c2c3..38e7130ba7 100644
--- a/board/link/board.h
+++ b/board/link/board.h
@@ -16,6 +16,7 @@
/* Optional features */
#define CONFIG_SMART_BATTERY
+#define CONFIG_BACKLIGHT_X86
#define CONFIG_BATTERY_LINK
#define CONFIG_BOARD_VERSION
#define CONFIG_CHARGER
diff --git a/board/peppy/board.c b/board/peppy/board.c
index 5f1422e98c..293747c43b 100644
--- a/board/peppy/board.c
+++ b/board/peppy/board.c
@@ -5,7 +5,7 @@
/* EC for Peppy board configuration */
#include "adc.h"
-#include "board.h"
+#include "backlight.h"
#include "chip_temp_sensor.h"
#include "chipset_haswell.h"
#include "chipset_x86_common.h"
@@ -37,7 +37,7 @@ const struct gpio_info gpio_list[GPIO_COUNT] = {
{"AC_PRESENT", LM4_GPIO_H, (1<<3), GPIO_INT_BOTH,
extpower_interrupt},
{"PCH_BKLTEN", LM4_GPIO_M, (1<<3), GPIO_INT_BOTH,
- switch_interrupt},
+ backlight_interrupt},
{"PCH_SLP_S0_L", LM4_GPIO_G, (1<<6), GPIO_INT_BOTH,
x86_interrupt},
{"PCH_SLP_S3_L", LM4_GPIO_G, (1<<7), GPIO_INT_BOTH,
diff --git a/board/peppy/board.h b/board/peppy/board.h
index 102c2fffa9..70ad78c48d 100644
--- a/board/peppy/board.h
+++ b/board/peppy/board.h
@@ -16,6 +16,7 @@
/* Optional features */
#define CONFIG_SMART_BATTERY
+#define CONFIG_BACKLIGHT_X86
#define CONFIG_BATTERY_PEPPY
#define CONFIG_BOARD_VERSION
#define CONFIG_CHARGER
diff --git a/board/slippy/board.c b/board/slippy/board.c
index bf06a80b54..da361174c2 100644
--- a/board/slippy/board.c
+++ b/board/slippy/board.c
@@ -5,7 +5,7 @@
/* EC for Slippy board configuration */
#include "adc.h"
-#include "board.h"
+#include "backlight.h"
#include "chip_temp_sensor.h"
#include "chipset_haswell.h"
#include "chipset_x86_common.h"
@@ -37,7 +37,7 @@ const struct gpio_info gpio_list[GPIO_COUNT] = {
{"AC_PRESENT", LM4_GPIO_H, (1<<3), GPIO_INT_BOTH,
extpower_interrupt},
{"PCH_BKLTEN", LM4_GPIO_M, (1<<3), GPIO_INT_BOTH,
- switch_interrupt},
+ backlight_interrupt},
{"PCH_SLP_S0_L", LM4_GPIO_G, (1<<6), GPIO_INT_BOTH,
x86_interrupt},
{"PCH_SLP_S3_L", LM4_GPIO_G, (1<<7), GPIO_INT_BOTH,
diff --git a/board/slippy/board.h b/board/slippy/board.h
index e322d1abd5..d41db4781b 100644
--- a/board/slippy/board.h
+++ b/board/slippy/board.h
@@ -16,6 +16,7 @@
/* Optional features */
#define CONFIG_SMART_BATTERY
+#define CONFIG_BACKLIGHT_X86
#define CONFIG_BATTERY_SLIPPY
#define CONFIG_BOARD_VERSION
#define CONFIG_CHARGER
diff --git a/board/wolf/board.c b/board/wolf/board.c
index 8c05c72ae8..c1afbb1cbd 100644
--- a/board/wolf/board.c
+++ b/board/wolf/board.c
@@ -5,7 +5,7 @@
/* EC for Wolf board configuration */
#include "adc.h"
-#include "board.h"
+#include "backlight.h"
#include "chip_temp_sensor.h"
#include "chipset_haswell.h"
#include "chipset_x86_common.h"
@@ -36,7 +36,7 @@ const struct gpio_info gpio_list[GPIO_COUNT] = {
{"AC_PRESENT", LM4_GPIO_H, (1<<3), GPIO_INT_BOTH,
extpower_interrupt},
{"PCH_BKLTEN", LM4_GPIO_M, (1<<3), GPIO_INT_BOTH,
- switch_interrupt},
+ backlight_interrupt},
{"PCH_SLP_S0_L", LM4_GPIO_G, (1<<6), GPIO_INT_BOTH,
x86_interrupt},
{"PCH_SLP_S3_L", LM4_GPIO_G, (1<<7), GPIO_INT_BOTH,
diff --git a/board/wolf/board.h b/board/wolf/board.h
index 06598cfe66..2e8a41b884 100644
--- a/board/wolf/board.h
+++ b/board/wolf/board.h
@@ -15,6 +15,7 @@
#define CONFIG_TASK_PROFILING
/* Optional features */
+#define CONFIG_BACKLIGHT_X86
#ifdef HAS_TASK_CHIPSET
#define CONFIG_CHIPSET_HASWELL
#endif