Commit Graph

243 Commits

Author SHA1 Message Date
Hung-Te Lin
2607e39f0e newbitmaps: Add more locales & fix locale 'ms' (Malay).
Adding 'update' and language description for locale 'ms'.
Also fixed 'model' height in 'th' locale.

BRANCH=none
BUG=chrome-os-partner:11969
TEST=make # success.

Change-Id: I3eb12d43284bab8c3c243cf86e3dc90c7c0e5497
Reviewed-on: https://gerrit.chromium.org/gerrit/32440
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Dave Parker <dparker@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-09-06 18:13:20 -07:00
Gaurav Shah
7b3e34a236 Key increment script: Preserve extension and take the target keyset directory
First, preserve extensions for the backed up keys (and keyblocks). Useful since
our wrapping scripts look at the extension in deciding what needs wrapping.

Second, instead of having to run the script from within a keyset directory,
take the keyset path as an argument and increment the versions for
the keys in there.

BUG=chrome-os-partner:13748
TEST=ran on devkeys
BRANCH=none

Change-Id: I9e8c3e58149e5cb4cd5557521e047e25c06b0cd6
Reviewed-on: https://gerrit.chromium.org/gerrit/32417
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Tested-by: Gaurav Shah <gauravsh@chromium.org>
2012-09-06 16:29:24 -07:00
Che-Liang Chiou
3ae4dd7052 signing script: Resign just firmware body, not the entire section
The signing script extracted firmware body sections FW_MAIN_{A,B} and
resigned the whole section instead of just firmware body.

As a result, read-only firmware spends more time loading read-write
firmware from SPI flash.

Since vblock has firmware body size information, signing script should
retrieve it and use it to sign just firmware body.

This may reduce boot time for ~560ms, depending on firmware image size,
section size and SPI flash/bus throughput.

Signed-off-by: Che-Liang Chiou <clchiou@chromium.org>

BRANCH=snow,link
BUG=chrome-os-partner:13094
TEST=For Snow (or boards that use cros_bundle_firmware), check that
       after resigning, VBLOCK_{A,B} and FW_MAIN_{A,B} are unchanged
     For Alex and ZGB, check that old and new resign_firmwarefd.sh
       generates identical output

(Test for Snow; repeat for A and B)

dump_fmap -x image.bin VBLOCK_A FW_MAIN_A
mv VBLOCK_A VBLOCK_A.orig
mv FW_MAIN_A FW_MAIN_A.orig

resign_firmwarefd.sh image.bin image-resigned.bin \
  firmware_data_key.vbprivk \
  firmware.keyblock \
  dev_firmware_data_key.vbprivk \
  dev_firmware.keyblock \
  kernel_subkey.vbpubk

dump_fmap -x image-resigned.bin VBLOCK_A FW_MAIN_A
cmp VBLOCK_A.orig VBLOCK_A
cmp FW_MAIN_A.orig FW_MAIN_A

(Test for Alex and ZGB; repeat for old and new resign_firmwarefd.sh)

resign_firmwarefd.sh image.bin image-resigned-{old or new}.bin \
  firmware_data_key.vbprivk \
  firmware.keyblock \
  dev_firmware_data_key.vbprivk \
  dev_firmware.keyblock \
  kernel_subkey.vbpubk

cmp image-resigned-old.bin image-resigned-new.bin

Change-Id: Ie70b6c91614343ad9f991ae369a0f8e74ec213fe
Reviewed-on: https://gerrit.chromium.org/gerrit/31572
Commit-Ready: Che-Liang Chiou <clchiou@chromium.org>
Tested-by: Che-Liang Chiou <clchiou@chromium.org>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
2012-09-04 17:11:23 -07:00
Mike Frysinger
16de2c7bae signer scripts: break kernel parameters on spaces rather than word boundaries
The current kernel parameter parsing logic uses word boundaries (\b) to
keep from replacing parameters inside of other parameters (like "level=1"
mangling "loglevel=1" into "log"), but this fails when the last character
isn't a "word" character.  e.g. "\bconsole=\b" doesn't match "console=".

Change the \b to a space.  Since we're already using spaces as our split
marker, this shouldn't be a problem.

BRANCH=None
BUG=chrome-os-partner:12780
BUG=chromium-os:33868
TEST=ran `ensure_secure_kernelparams.sh` on an image with 'console=' and saw it work

Change-Id: Id69250179ea76aabfed9cd21c1c59483d78a215d
Reviewed-on: https://gerrit.chromium.org/gerrit/31356
Reviewed-by: David McMahon <djmm@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
2012-08-24 13:26:03 -07:00
Mike Frysinger
513be212d9 signer scripts: include debug output when we fail
When checking kernel params fail, it's useful to know all the variables
as to what it's doing.  So dump some state when an error occurs.

BRANCH=None
BUG=None
TEST=ran `ensure_secure_kernelparams.sh` on a bad image and saw useful output
TEST=ran `ensure_secure_kernelparams.sh` on a good image and saw no output

Change-Id: I0e499f87a6d8feed80da72aba75e1e6c1b4076c9
Reviewed-on: https://gerrit.chromium.org/gerrit/31355
Reviewed-by: David McMahon <djmm@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
2012-08-24 12:50:56 -07:00
Hung-Te Lin
ea1b7dd9d9 newbitmaps: Add "native 1366x768 USB" profile.
BRANCH=none # we always build images in ToT.
BUG=chrome-os-partner:13048
TEST=make # got n1366usb bmpblk.bin

Change-Id: I5af3c4f599c6789c208013095db86f0836241ced
Reviewed-on: https://gerrit.chromium.org/gerrit/31324
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-24 11:40:11 -07:00
Hung-Te Lin
2ac65ecccf newbitmaps: Reduce spacing between for_help and URL text.
Both for_help_* and Url bitmaps have margin, so it looks too large as a
"margin*2 + 5(x_pad)" gap on screen.

BRANCH=none
BUG=chrome-os-partner:12893
TEST=make # All bitmaps generated.

Change-Id: Ic8d3e9180e52b7476b07367a027793cea0ed3109
Reviewed-on: https://gerrit.chromium.org/gerrit/30988
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Dave Parker <dparker@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-22 18:34:44 -07:00
Hung-Te Lin
1d9c217085 newbitmaps: Improve insert_sd_usb2 message.
"insert_sd_usb2" message didn't include the "ChromeOS is missing or damaged"
text, also is too long for certain locales.

We should revise message and check if the locale fits screen width.

BRANCH=none
BUG=none
TEST=cd strings; make  # all pass

Change-Id: Ie9cb5e4ecd6d143772ffa8e7de29c202e9bde130
Reviewed-on: https://gerrit.chromium.org/gerrit/30824
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Dave Parker <dparker@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-20 10:13:01 -07:00
Hung-Te Lin
1550b14604 newbitmaps: Support more profiles.
Added "n1366usb2" profile and remove SD icon in *usb profile.

BRANCH=none
BUG=chrome-os-partner:11078
TEST=make # all profiles generated.

Change-Id: If280cebb847cdc7a599f510f279df03e1cc9b4d5
Reviewed-on: https://gerrit.chromium.org/gerrit/30810
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Dave Parker <dparker@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-20 10:13:00 -07:00
Hung-Te Lin
7ce91cd2f9 newbitmaps: Change build targets from x86/arm to "profiles".
The difference of firmware bitmaps won't rely on platform (x86/arm) in future;
instead, things will differ by rescaling & message contents.

To support that, we need to change build target from "platform" to "profiles".

To build all platforms, run "make" in top leve (or "make all" in images).
To debug (en locale without rescaling), run "make" in images folder.
To debug a specific profile, run "make $PROFILE" in images folder.

BRANCH=none
BUG=chrome-os-partner:11078, chrome-os-partner:12790
TEST=make # all profiles generated in images/out_*/*.bin

Change-Id: Iaabf160b1b2bc844d230188eb593daa8a597d378
Reviewed-on: https://gerrit.chromium.org/gerrit/30683
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-17 20:02:15 -07:00
Hung-Te Lin
5f5f086e38 newbitmaps: Replace image source BMP files by PNG format.
PNG files are better for editing and checking than BMP files.
Also smaller file size.

BRANCH=none
BUG=none
TEST=make # x86 & arm bitmap blocks generated.

Change-Id: I828779aafa4938cb21356a8c42dee27b1b3ad8ae
Reviewed-on: https://gerrit.chromium.org/gerrit/30682
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-17 20:02:14 -07:00
Hung-Te Lin
4d31d0b045 newbitmaps: Revise fonts, color, layout & messages.
Inspired by https://gerrit.chromium.org/gerrit/#/c/30631/

 - Increase gray colored text contrast
 - Enlarge font size to 17pt
 - Change standard font to Verdata (which is wider than usually fonts,
   to provide better quality when stretched in horizontal)
 - Decomposed tonorm_confirmation & devmode so we can have better control
   to verif_* prompt, and look more similar to original mock.

BUG=chrome-os-partner:11078
TEST=make # All platforms generated
BRANCH=none

Change-Id: If019b5767f13556df0e4da77f6457e092fa06016
Reviewed-on: https://gerrit.chromium.org/gerrit/30679
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-17 20:02:14 -07:00
Hung-Te Lin
194d7d8867 newbitmaps: Add "insert SD / USB2" text resource.
We need the text for "SD or USB2" (i.e., not USB3).

BRANCH=none
BUG=chrome-os-partner:12790
TEST=none, only adding text translation resource.

Change-Id: Id70a2565bb1fb0b6a4ed92d3fceddbc72e60d77a
Reviewed-on: https://gerrit.chromium.org/gerrit/30663
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-17 20:02:14 -07:00
Dave Parker
0868f8f3b7 Fix vertical placement of bmp images on firmware screens.
BUG=chromium-os:33608
TEST=Run 'make' in newbitmaps directory to generate new bmpblock.
Run on DUT. Observe spacing in the footer section is closer
together.

Change-Id: I96987e827fd395f13244dbc58db600de5dc30958
Reviewed-on: https://gerrit.chromium.org/gerrit/30610
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Commit-Ready: Dave Parker <dparker@chromium.org>
Tested-by: Dave Parker <dparker@chromium.org>
2012-08-16 18:45:21 -07:00
Dave Parker
12ef75d84d Fix alignment of HWID on firmware screens and bitmap viewer.
BUG=chrome-os-partner:12701
TEST=Disable the 'clean' step in the Makefile and
run 'make' in newbitmaps directory. Use the bitmap_viewer to
verify the HWID is correctly aligned when compared with the "Model"
text.

Change-Id: Icd3977f50461492a0999059ccd4982d16a373dce
Reviewed-on: https://gerrit.chromium.org/gerrit/30453
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Commit-Ready: Dave Parker <dparker@chromium.org>
Tested-by: Dave Parker <dparker@chromium.org>
2012-08-15 22:49:09 -07:00
Dave Parker
06e8e90018 Prevent color dithering of firmware bitmaps
BUG=None
TEST=Run 'make' in newbitmaps dir with "clean" removed from the default
step in the Makefile. Use bitmap_viewer to check that the images do not
show grainy color dithering.

Change-Id: I6dff41338a7e54d090bb2f6dedb982fdaa31e657
Reviewed-on: https://gerrit.chromium.org/gerrit/30308
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Commit-Ready: Dave Parker <dparker@chromium.org>
Tested-by: Dave Parker <dparker@chromium.org>
2012-08-15 19:28:15 -07:00
Hung-Te Lin
6cda3966ec newbitmaps: Refine text layout & font settings.
BRANCH=none
BUG=chrome-os-partner:11078
TEST=make  # x86 and arm bitmaps both works.

Change-Id: I21382c4f4a829703d9249929579f5007a7db1a9e
Reviewed-on: https://gerrit.chromium.org/gerrit/30369
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-15 18:36:35 -07:00
Dave Parker
9a6e6e7785 Scale bmp files correctly for x86 when generating bmpblocks.
BUG=None
TEST=Run 'make' in newbitmaps directory but remove the "clean"
step in the Makefile. Use the bmp_viewer utility to verify
all graphic elements are scaled.

Change-Id: Ifd62c2ba3a6c354c4de7d9fd052d76de36842fb6
Reviewed-on: https://gerrit.chromium.org/gerrit/30126
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Commit-Ready: Dave Parker <dparker@chromium.org>
Tested-by: Dave Parker <dparker@chromium.org>
2012-08-13 20:37:27 -07:00
Hung-Te Lin
b57b8c3dea newbitmaps: Add ToNorm confirm screen resource.
According to new flow, we need "confirm" screens for TONORM.
Also simplified default_source folder, with better hints and using PNG image
source.  image/assets/* are files from issue page.

BUG=chrome-os-partner:11078
TEST=make  # x86 and arm bitmaps both works.

Change-Id: I3701d6ed5a944305e12a01c1841a197d3e18a8cd
Reviewed-on: https://gerrit.chromium.org/gerrit/29983
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-13 17:25:13 -07:00
Hung-Te Lin
c951eb8257 newbitmaps: Refine font and text generation.
The bmpblk build scripts used to rely on lots of pre-generated resources, and
the HWID font data was fixed to x86 special size & scaling parameters.

Since the screens now rely on more platform dependent parameters, this CL
refined whole flow so fonts are now generated and processed (ex, re-scale) in
the same way as other text messages.

BUG=chrome-os-partner:11078
TEST=make # x86 and arm bitmaps both works.

Change-Id: I59a4fb31718ef052c6b54cd4642f4fc487893f2b
Reviewed-on: https://gerrit.chromium.org/gerrit/29873
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-10 11:18:52 -07:00
Hung-Te Lin
6974266829 newbitmaps: Always generate bitmaps in 8bpp mode.
ImageMagick may produce 1bpp mode for background if the image is modified (ex,
x86 output). We need to ensure the output to be 8bpp mode for firmware to
render images correctly.

BUG=chrome-os-partner:11078
TEST=make x86 # all images are in 8bpp mode.

Change-Id: Ia6e4fbc5e7580ebbb51e1067bcf554ee06f1fbc5
Reviewed-on: https://gerrit.chromium.org/gerrit/29868
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-10 11:18:52 -07:00
Dave Parker
1eb883dce6 Translated text for "v2" firmware recovery screens.
BUG=chrome-os-partner:11078
TEST=run make in newbitmaps directory to build a new bmpblock.

Change-Id: I97683c95c7c0881ce17617ccab4eb674a06704de
Reviewed-on: https://gerrit.chromium.org/gerrit/29866
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Commit-Ready: Dave Parker <dparker@chromium.org>
Tested-by: Dave Parker <dparker@chromium.org>
2012-08-09 23:59:29 -07:00
Hung-Te Lin
1dc00165e5 newbitmaps: Add TODEV, TONORM, and UPDATE(WAIT) screens.
An initial draft of missing screens, with only English messages (*.txt in
localized folders are now all English - will update them once translation is
ready).

BUG=chrome-os-partner:11078
TEST=make; bitmap_viewer DEFAULT.yaml # see basic screen.

Change-Id: I3209e18bf604030cf8e92d264781add33aab84fe
Reviewed-on: https://gerrit.chromium.org/gerrit/29765
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-09 19:44:49 -07:00
Hung-Te Lin
b7adca3f4c newbitmaps: Remove Alex files and refer to specific branch.
Alex bitmaps cannot be generated by latest tools anymore, so let's remove the
resource files and refer to the correct place that contains everything you need
to generate a new Alex bitmap.

(Also see https://gerrit-int.chromium.org/#/c/23243/ for more information)

BUG=none
TEST=none, simply delete files.

Change-Id: I170071892df04ad1cf8304da506f2639a8f39b8b
Reviewed-on: https://gerrit.chromium.org/gerrit/29743
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-09 19:18:20 -07:00
Hung-Te Lin
4e4ed8bc96 Generates x86 and arm firmware bitmap blocks.
X86 (coreboot) uses 800x600 resolution while ARM systems (uboot) initialze LCD
as its maximum size, so we must refine the bmpblk build scripts to generate
output with different scaling parameters.

BUG=chrome-os-partner:11078
TEST=make # got ARM bmpblock and verified to work on daisy.

Change-Id: Ib9e9a0dc3b6695cef451772391f207a5b57977df
Reviewed-on: https://gerrit.chromium.org/gerrit/29606
Reviewed-by: Dave Parker <dparker@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Tom Wai-Hong Tam <waihong@chromium.org>
2012-08-09 01:56:45 -07:00
Hung-Te Lin
7f06cfd68d Generate localized messages in PNG format.
To support rendering messages in multiple resolution profiles, we need to keep
the images in its original format.

BUG=chrome-os-partner:11078
TEST=./text_to_png # images were converted correctly.

Change-Id: I6e13331eddfa4c40b17b67b5cf56b5a0284e3b34
Reviewed-on: https://gerrit.chromium.org/gerrit/29605
Reviewed-by: Dave Parker <dparker@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-09 01:56:45 -07:00
Hung-Te Lin
c11d83513f Add firmware update message for WAIT screen.
Simply copied from assets (boot-messages).

BUG=chrome-os-partner:11078
TEST=none, simply adding text resource files.

Change-Id: Idd81a1471b440e2ef2b7be652e4eb6896e93a2fc
Reviewed-on: https://gerrit.chromium.org/gerrit/29604
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-09 01:56:44 -07:00
Dave Parker
5da1061b46 Update bmpblock with new-style minimalist screens.
NOTE: Only the "launch countries" have a full set of updated
text strings...and those strings were translated via
translate.google.com and need fixing-up prior to use in a
real product.

BUG=chrome-os-partner:11078
TEST=install bmpblock_x86.bin into a firmware image with
gbb_utility -s -b bmpblock_x86.bin image.bin
Verify the four firmware screens are displayed correctly.

Original-Change-Id: Ib8ff142e9a938a6a3bf949153594cc013c8bb311
Reviewed-on: https://gerrit.chromium.org/gerrit/28574
Reviewed-by: Dave Parker <dparker@chromium.org>
Tested-by: Dave Parker <dparker@chromium.org>
(cherry picked from commit 7c41920b754cb0d18da9a125f76d3f1ef90e04f4)

Change-Id: I534beaea5be95b549a6305d4b2911abeb983e034
Reviewed-on: https://gerrit.chromium.org/gerrit/29603
Reviewed-by: Dave Parker <dparker@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-08-09 01:56:44 -07:00
Dave Parker
3985f94fae Increase max number of bitmaps to composite to 16 per screen.
This is needed to render new-style screens that use 13 bitmaps.
bmpblk version is changed from 1.2 to 2.0, due to incompatibility.

BUG=chrome-os-partner:11078
TEST=emerge-<board> vboot-reference. Run firmware with new bmpblock.

Original-Change-Id: I750da66b020fe195896df58f31fcbb2a9e33e404
Reviewed-on: https://gerrit.chromium.org/gerrit/28945
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Tested-by: Dave Parker <dparker@chromium.org>
(cherry picked from commit 0b7ee46c2eeba858ff59d534e265b445895623a2)

Change-Id: I80543c46a7c0e09169e29e32077d84c57192e431
Reviewed-on: https://gerrit.chromium.org/gerrit/29602
Reviewed-by: Dave Parker <dparker@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Tom Wai-Hong Tam <waihong@chromium.org>
2012-08-09 01:56:44 -07:00
Jim Hebert
61ed188e95 Extend "non-release" check to session manager use-flags.
Since we've moved away from flag-files in session manager to
enable certain dev/test-mode features, our strategy of checking
for those flag files on the signer fell behind. This test adopts
a scheme that any use flag starting with "test_" or "dangerous_"
is blacklisted from release signing.

BUG=chromium-os:32430
TEST=ran the script against both a 'base' and 'test' image
from the builder/ToT. Passes/fails as expected.

Change-Id: I54d6ef17d52371c7543d5705e0939e000db85e51
Reviewed-on: https://gerrit.chromium.org/gerrit/29034
Reviewed-by: Chris Masone <cmasone@chromium.org>
Tested-by: Jim Hebert <jimhebert@chromium.org>
Commit-Ready: Jim Hebert <jimhebert@chromium.org>
2012-08-07 14:28:01 -07:00
Bill Richardson
b48cd672a7 Add WAIT screen to default bitmap
Some systems take a long time to program the EC firmware (because it's
behind a really slow I2C bus or something). This could happen at any boot as
part of software sync. If it's necessary to reprogram the EC on a slow
system, we need to display a BIOS screen to the user so he/she doesn't think
it's bricked.

This CL is just to add a new default bitmap so we'll have something to
display when we need it. Nothing actually uses it yet.

BUG=chrome-os-partner:12254
TEST=none

There should be no user-visible changes. We don't invoke this screen yet.

Change-Id: Icb922f933e2e921472dbdff7a26a3ca4d58fbba3
Signed-off-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/29241
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
2012-08-05 22:08:33 -07:00
Randall Spangler
8dde1491e5 Fix make_dev_ssd.sh --remove_rootfs_verification
It was checking for /dev/dm-0, which isn't the case anymore.  It now
always attempts to remove rootfs verification from the command line;
this is harmless (no-op) if it's already removed.

BUG=chromium-os:31558
TEST=manual

/usr/share/vboot/bin/make_dev_ssd.sh --remove_rootfs_verification
reboot
touch /opt/google/chrome/chrome

Change-Id: I62dc138e8d1d09bdcb16be3faab74d32c5f7675a
Signed-off-by: Randall Spangler <rspangler@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/28506
Reviewed-by: David James <davidjames@chromium.org>
2012-08-03 12:22:32 -07:00
Hung-Te Lin
af44dce1e8 vboot_reference: Improve make_dev_firmware script.
Developers testing firmware preamble flags (usually for turn on/off RO-NORMAL
bits) need a easy way to change existing firmware, without hacking FDT source /
looking for complex script.

Also included some minor improvements:
 * Always enable FORCE_DEV_BOOT_USB and DISABLE_FW_ROLLBACK_CHECK. These are
   flags most developers need when leaving official signed normal firmware.
 * --bmpfv is deprecated because our latest firmware now always include
   official bitmaps in updater, no more DEV bitmaps.

BUG=none
TEST=./make_dev_firmware.sh -f bios.bin -t new_bios.bin --preamble_flags 0
     ./make_dev_firmware.sh -f bios.bin -t new_bios.bin --preamble_flags 1

Change-Id: I7ee72d32b4b7fa28f2be635fd8c7bb678852e132
Reviewed-on: https://gerrit.chromium.org/gerrit/28792
Tested-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
2012-08-01 09:07:06 -07:00
Nirnimesh
c6051ff378 [vboot_reference] Prepare for the removal of /root/.forget_usernames from test images
/root/.forget_usernames is going away from test images. It was a hack.

BUG=chromium-os:31807
TEST=suite:bvt

Change-Id: I27b606fa0232514f3ec45a4ed765b89efcf8f07e
Reviewed-on: https://gerrit.chromium.org/gerrit/27588
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Nirnimesh <nirnimesh@chromium.org>
Commit-Ready: Nirnimesh <nirnimesh@chromium.org>
2012-07-17 16:03:44 -07:00
Hung-Te Lin
61603e2d61 vboot_reference: add "set_gbb_flags" script.
A simple script to help setting GBB flags on-the-fly, with help information for
flag value meanings.

BUG=chrome-os-partner:10389
TEST=./set_gbb_flags.sh 0x20
     ./set_gbb_flags.sh 0x0

Change-Id: Ic624f76c0897a1cbda876f3073b36f7c6425b5d4
Reviewed-on: https://gerrit.chromium.org/gerrit/26224
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Commit-Ready: Hung-Te Lin <hungte@chromium.org>
Tested-by: Hung-Te Lin <hungte@chromium.org>
2012-06-27 18:44:28 -07:00
Gaurav Shah
79461cbc03 security test: Add test that verifies that update verification is enabled
BUG=chromium-os:31893
TEST=verified on images with/without payload verification enabled.

Change-Id: Ic1883aafcc2c48d9e7c5323d6dc7e21fb8f47585
Reviewed-on: https://gerrit.chromium.org/gerrit/25407
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Commit-Ready: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Gaurav Shah <gauravsh@chromium.org>
2012-06-18 15:21:42 -07:00
Bill Richardson
1d75e69f3d Check in sources for the default, unofficial BIOS screens
The original sources have been lost. These were obtained by unpacking the
binary.

BUG=none
TEST=none

Change-Id: I8042a3abf586551bc2a855d3fd9d7d6ae1aae2d9
Reviewed-on: https://gerrit.chromium.org/gerrit/24710
Tested-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Hung-Te Lin <hungte@chromium.org>
Commit-Ready: Randall Spangler <rspangler@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
2012-06-07 14:00:14 -07:00
Gaurav Shah
9c783ce3c1 Signing scripts: Add firmware signing to sign_official_build.sh
This makes it easy to integrate firmware signing into the signer
since we can reuse the base signing script.

BUG=chromium-os:10094
TEST=try signing both firmware and normal images.

Change-Id: I8beb598e267de33a2c3468dcf8d7c4b74d4de9fd
Reviewed-on: https://gerrit.chromium.org/gerrit/24654
Reviewed-by: Mike Frysinger <vapier@chromium.org>
Commit-Ready: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Gaurav Shah <gauravsh@chromium.org>
2012-06-07 12:39:38 -07:00
Don Garrett
bb5c49b343 Modify align_rootfs to use --src_image only.
Align_rootfs was written to auto-fetch the previous release of a given
image, but that logic has bit-rotted. This CL is a quick hack to use
--src_image instead.

BUG=chromium-os:31124
TEST=Hand ran.

Change-Id: I530c6f82c42993648cecb5d59172010d61dd1603
Reviewed-on: https://gerrit.chromium.org/gerrit/23168
Commit-Ready: Don Garrett <dgarrett@chromium.org>
Reviewed-by: Don Garrett <dgarrett@chromium.org>
Tested-by: Don Garrett <dgarrett@chromium.org>
2012-06-04 15:55:36 -07:00
Bill Richardson
2448d3b3bc Create vbutil_ec tool for signing EC firmware.
This just adds the vbutil_ec tool (and a simple test of the library
functions related to it).

BUG=chrome-os-partner:7459, chromium-os:27142
TEST=manual

  make
  make runtests

Change-Id: I2a2c4e7cfb8ac6ce2229c5de4252a5cc89321fa5
Reviewed-on: https://gerrit.chromium.org/gerrit/21868
Commit-Ready: Bill Richardson <wfrichar@chromium.org>
Tested-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Stefan Reinauer <reinauer@google.com>
Reviewed-by: Vadim Bendebury <vbendeb@chromium.org>
2012-05-04 12:16:45 -07:00
Mike Frysinger
81f704edad signer scripts: retry more than once when mounting
The retry logic has brought down the number of flakes significantly (from
multiple errors a day to ~one every other day).  But let's up the retry
count, and have it sleep longer after each failure, so hopefully we can
bring down the flake count even further.

BUG=chrome-os-partner:8156
TEST=`./signing_poller.py -s` signs local images fine

Change-Id: I98bc947836514d8b931568f87f7f9a373f771b79
Reviewed-on: https://gerrit.chromium.org/gerrit/21468
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
2012-05-01 12:37:57 -07:00
Mike Frysinger
aca0a135ac signer scripts: workaround flaky kernels and loop mount failures
The kernels we are running the signers on flake out from time to time
when mounting the loop back images.  Have the mount code detect this
edge case and automatically retry when the flake hits.

BUG=chrome-os-partner:8156
TEST=`./signing_poller.py -s` signs local images fine

Change-Id: Iaa08445904aa26f0aa7240504f6c7a96e6ef3bbb
Reviewed-on: https://gerrit.chromium.org/gerrit/21055
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
2012-04-25 12:50:12 -07:00
Gaurav Shah
cd10a96926 Create default key.versions file if none exist
Also remove the default checked in key.versions.

BUG=none
TEST='rm key.versions && ./create_new_keys.sh; ./create_new_keys.sh'

Change-Id: Ia46d411904cb67bcefdbf73524f506e5b2336875
Reviewed-on: https://gerrit.chromium.org/gerrit/20253
Commit-Ready: Gaurav Shah <gauravsh@chromium.org>
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Gaurav Shah <gauravsh@chromium.org>
2012-04-16 14:57:56 -07:00
Mike Frysinger
caddf52936 signer scripts: use make_temp_dir helper
The common code takes care of cleaning up temporary files for us if we
use the right helpers.  These scripts don't though, so the temp files
end up not getting cleaned and over time, /tmp/ files up with crap.

The common helper takes care of unmounting and removing, so converting
these files over should be safe.

BUG=None
TEST=`./signer/signer_poller.py -s` signs local images and leaves no /tmp/tmp.* junk

Change-Id: I87aa122895997a5ec0017665203fdc8d14e0ab2a
Reviewed-on: https://gerrit.chromium.org/gerrit/20329
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
2012-04-16 14:00:21 -07:00
Mike Frysinger
db1d5b20f8 signer scripts: use sudo if need be when modifying /etc/lsb-release
If we try to run the signing_poller daemon as non-root, it fails to set
the channel.  Detect if the lsb file is writable, and if not, switch to
using sudo on the fly.

BUG=None
TEST=`./signer/signing_poller.py` as non-root and setting the channel works

Change-Id: Iadb10ae68582edfb332f33d3b101c83949ee9502
Reviewed-on: https://gerrit.chromium.org/gerrit/20089
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
2012-04-12 16:06:58 -07:00
Mike Frysinger
7437af134e signer scripts: add OWNERS
BUG=chromium-os:22007
TEST=`cat scripts/OWNERS` show signing people

Change-Id: I0e7e50d4ee6bd97ab651c851057d7ed1ee069155
Reviewed-on: https://gerrit.chromium.org/gerrit/20018
Reviewed-by: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Commit-Ready: Mike Frysinger <vapier@chromium.org>
2012-04-11 15:44:10 -07:00
Gaurav Shah
d170a9d542 signer scripts: unmount loop devices without -d arg to umount
Investigations in crosbug.com/26483 revealed a bug in loop device handling
if 'umount -d' was called on loop devices mounted using 'mount -o loop'.

This CL changes all invocations of umount to remove the -d option since they
are always in the context of a loop device creating using -o loop.

BUG=chrome-os-partner:8156
TEST=none

Change-Id: I96f30664c3f9148d3b57d430002512d8e94b66bc
Reviewed-on: https://gerrit.chromium.org/gerrit/19858
Reviewed-by: David James <davidjames@chromium.org>
Commit-Ready: Gaurav Shah <gauravsh@chromium.org>
Tested-by: Gaurav Shah <gauravsh@chromium.org>
2012-04-09 17:28:23 -07:00
Gaurav Shah
075fd17655 signer security test: special case dogfood channel for app id check
Similar to the canary channel, the dogfood channel images can have their
own app id that is distinct from the board app id.

BUG=chromium-os:25702, chrome-os-partner:8441
TEST=on a dogfood-channel image

Change-Id: Ic993a40d905b224072d325a69e47fdb6633c2e22
Reviewed-on: https://gerrit.chromium.org/gerrit/18039
Tested-by: Gaurav Shah <gauravsh@chromium.org>
Reviewed-by: Scott Zawalski <scottz@chromium.org>
2012-03-13 15:43:57 -07:00
Gaurav Shah
f5b5b4ce5f signer tests: Allow different appids for canary channel images
If the channel is canary, allow appid to match the value of
expected_appid_canary in the ensure sane lsb release test
configuration.

BUG=chromium-os:25437
TEST=manually tested on an image with and without the channel being canary.

Change-Id: I6bf71adbe0fc090ef777c28d24c53eaa8be18404
Reviewed-on: https://gerrit.chromium.org/gerrit/15509
Tested-by: Gaurav Shah <gauravsh@chromium.org>
Reviewed-by: Scott Zawalski <scottz@chromium.org>
Commit-Ready: Gaurav Shah <gauravsh@chromium.org>
2012-02-08 12:09:18 -08:00
Bill Richardson
b5cf3f30cc remove.txt no longer mentions USB and SD cards explicitly
BUG=chrome-os-partner:6953
TEST=none

Just changing the source, so nothing to test here.

Change-Id: Ic09c45d49ea9e5acd4b57e281de73a4ca0a3af81
Reviewed-on: https://gerrit.chromium.org/gerrit/14915
Tested-by: Bill Richardson <wfrichar@chromium.org>
Reviewed-by: Randall Spangler <rspangler@chromium.org>
Commit-Ready: Bill Richardson <wfrichar@chromium.org>
2012-01-26 16:43:06 -08:00