cros_write_firmware: Extract FDT from image automatically
It is a pain to have to specify the board and FDT when writing an image.
Extract the FDT from the image instead, while still allowing an override
if required.
BUG=chromium:245311
BRANCH=none
TEST=manual
Using any image build from ToT, this command should flash it over USB:
$ cros_write_firmware /path/to/image.bin -F spi
For x86, this command should write it to em100:
$ cros_write_firmware /path/to/image.bin
Tested on pit and link.
Change-Id: I6fedec0ee6a6f877f72abe963b4b92bff82345eb
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/66922
Reviewed-by: Julius Werner <jwerner@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
3 files changed