diff options
author | Vincent Palatin <vpalatin@chromium.org> | 2012-05-30 20:14:14 +0000 |
---|---|---|
committer | Gerrit <chrome-bot@google.com> | 2012-05-31 16:28:06 -0700 |
commit | fbfd828b9a28f4e91fc100ef9e474f590acc7989 (patch) | |
tree | 1716fca236e7e28ea5762380808385d6522d7ec4 /Makefile.rules | |
parent | 26b4a9e1a0b104a16154eb03f9d3ea4fab134252 (diff) | |
download | chrome-ec-fbfd828b9a28f4e91fc100ef9e474f590acc7989.tar.gz |
simple and self-contained EC flashing tool
This produces a host binary running on the application processor and
which is able to re-flash th EC firmware over the AP-to-EC link (either
LPC or I2C).
The payload (ie the EC firmware) to use is embedded inside the flasher
binary.
This is just aimed at testing and developer upgrade. The auto-update
flow is using flashrom.
Signed-off-by: Vincent Palatin <vpalatin@chromium.org>
BUG=None
TEST=build for link/daisy/snow/bds and tests
On Snow, run burn_my_ec from the serial console and see that the EC was
correctly re-flashed.
Change-Id: I7f90e773678a7ef3d8dc6dbacf54e80f3294607b
Reviewed-on: https://gerrit.chromium.org/gerrit/24236
Reviewed-by: David Hendricks <dhendrix@chromium.org>
Tested-by: Vincent Palatin <vpalatin@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Commit-Ready: Vincent Palatin <vpalatin@chromium.org>
Diffstat (limited to 'Makefile.rules')
-rw-r--r-- | Makefile.rules | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Makefile.rules b/Makefile.rules index 152a50e6e9..7b3274f914 100644 --- a/Makefile.rules +++ b/Makefile.rules @@ -30,14 +30,14 @@ cmd_lds = $(CPP) -P -C -MMD -MF $@.d -MT $@ $(CPPFLAGS) \ -DSECTION=$(call section,$*) $< -o $@ cmd_obj_to_bin = $(OBJCOPY) --gap-fill=0xff -O binary $^ $@ cmd_flat_to_obj = $(CC) -T $(out)/firmware_image.lds -nostdlib $(CPPFLAGS) \ - -DPROJECT=$* -Wl,--build-id=none -o $@ $< + -Wl,--build-id=none -o $@ $< cmd_elf_to_flat = $(OBJCOPY) -O binary $^ $@ cmd_elf_to_dis = $(OBJDUMP) -D $< > $@ cmd_elf = $(LD) $(LDFLAGS) $(objs) -o $@ -T $< -Map $(out)/$*.map cmd_c_to_o = $(CC) $(CFLAGS) -MMD -MF $@.d -c $< -o $@ cmd_c_to_build = $(BUILDCC) $(BUILD_CFLAGS) $(BUILD_LDFLAGS) \ -MMD -MF $@.d $< -o $@ -cmd_c_to_host = $(HOSTCC) $(HOST_CFLAGS) -MMD -MF $@.d $^ -o $@ +cmd_c_to_host = $(HOSTCC) $(HOST_CFLAGS) -MMD -MF $@.d $(filter %.c, $^) -o $@ cmd_qemu = ./util/run_qemu_test --image=build/$(BOARD)/$*/$*.bin test/$*.py \ $(silent) cmd_version = ./util/getversion.sh > $@ @@ -123,6 +123,8 @@ $(build-utils): $(out)/%:%.c $(host-utils): $(out)/%:%.c $(foreach u,$(host-util-common),util/$(u).c) $(call quiet,c_to_host,HOSTCC ) +$(out)/util/burn_my_ec: $(out)/$(PROJECT).bin + .PHONY: clean clean: -rm -rf $(out) |