cros_bundle_firmware: Ensure the flasher avoids silent/bootsecure

These options need to be disabled for the flasher. We don't want a silent
console since then it is impossible to see when the flasher finishes. We
don't want bootsecure since then the flasher script cannot run.

A previous interim change corrected the 'silent' flag - the change completes
the fix and will allow us to make an image self-flashing in a later change
(i.e. we pull out U-Boot and the FDT from the image to be flashed, and use
those to flash it).

BUG=chrome-os-partner:21115
TEST=FEATURES=test sudo -E  emerge cros-devutils
Flash U-Boot with 'crosfw -b peach_pit -SCF'

 -C means silent console
 -S means bootsecure

See that we still get messages from the flasher, and it succeeds in its task.

Change-Id: I7a96a041ffbab6dfae4adcf6827fa39e925c9fb7
Signed-off-by: Simon Glass <sjg@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/64742
diff --git a/host/lib/write_firmware.py b/host/lib/write_firmware.py
index 4f2af1d..8624a6a 100644
--- a/host/lib/write_firmware.py
+++ b/host/lib/write_firmware.py
@@ -292,6 +292,8 @@
       Filename of the flasher binary created.
     """
     fdt = self._fdt.Copy(os.path.join(self._tools.outdir, 'flasher.dtb'))
+    fdt.PutInteger('/config', 'bootsecure', 0)
+    fdt.PutInteger('/config', 'silent-console', 0)
     payload_data = self._tools.ReadFile(payload)
 
     # Make sure that the checksum is not negative
@@ -968,7 +970,6 @@
            port number of servo to use.
   """
   write = WriteFirmware(tools, fdt, output, bundle, update, verify)
-  fdt.PutInteger('/config', 'bootsecure', 0)
   write.SelectServo(servo)
   flash_dest = None
   if flasher_dest: