summaryrefslogtreecommitdiff
path: root/common/lightbar.c
diff options
context:
space:
mode:
authorEric Caruso <ejcaruso@chromium.org>2014-10-08 16:39:51 -0700
committerchrome-internal-fetch <chrome-internal-fetch@google.com>2014-10-09 23:29:42 +0000
commit6713fa2d38a3b455be18ca1d8e1b530809f43352 (patch)
treebc69469f0f0188d23015c8b842013371deb40525 /common/lightbar.c
parente3e799916460fc2faf3c661534de014d692e7f19 (diff)
downloadchrome-ec-6713fa2d38a3b455be18ca1d8e1b530809f43352.tar.gz
lightbar: Rename structs and macros for kernel cros_ec_commands
This prepends EC_ a macro exposed in ec_commands.h, moves a macro into lbcc that is not used elsewhere, and changes lb_program structs to lightbar_program. BUG=None BRANCH=ToT TEST=make buildall -j Change-Id: I481562da72d91f846c64cf9af40338027641462c Signed-off-by: Eric Caruso <ejcaruso@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/222406 Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Diffstat (limited to 'common/lightbar.c')
-rw-r--r--common/lightbar.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/common/lightbar.c b/common/lightbar.c
index 5f05d6799e..cd6595bb21 100644
--- a/common/lightbar.c
+++ b/common/lightbar.c
@@ -908,8 +908,8 @@ static uint32_t sequence_TAP(void)
/* Lightbar bytecode interpreter: Lightbyte. */
/****************************************************************************/
-static struct lb_program cur_prog;
-static struct lb_program next_prog;
+static struct lightbar_program cur_prog;
+static struct lightbar_program next_prog;
static uint8_t pc;
static uint8_t led_desc[NUM_LEDS][LB_CONT_MAX][3];
@@ -1189,7 +1189,7 @@ static uint32_t sequence_PROGRAM(void)
uint8_t old_pc;
/* load next program */
- memcpy(&cur_prog, &next_prog, sizeof(struct lb_program));
+ memcpy(&cur_prog, &next_prog, sizeof(struct lightbar_program));
/* reset program state */
saved_brightness = lb_get_brightness();
@@ -1419,7 +1419,9 @@ static int lpc_cmd_lightbar(struct host_cmd_handler_args *args)
break;
case LIGHTBAR_CMD_SET_PROGRAM:
CPRINTS("LB_set_program");
- memcpy(&next_prog, &in->set_program, sizeof(struct lb_program));
+ memcpy(&next_prog,
+ &in->set_program,
+ sizeof(struct lightbar_program));
break;
case LIGHTBAR_CMD_VERSION:
CPRINTS("LB_version");