summaryrefslogtreecommitdiffstats
path: root/resources/libreboot/patch
diff options
context:
space:
mode:
authorPaul Kocialkowski <contact@paulk.fr>2015-10-11 11:48:46 (EDT)
committer Francis Rowe <info@gluglug.org.uk>2015-10-11 15:16:26 (EDT)
commitd8b597f33e75d04b84be7c9d7081a3b97821617d (patch)
tree8ad2d64ba4dff4cb6cfc1d9f7ecdc2c9cda8d19c /resources/libreboot/patch
parentd6b6b1ea62f555f38152ab475d98c57f739f8b8d (diff)
downloadlibreboot-d8b597f33e75d04b84be7c9d7081a3b97821617d.zip
libreboot-d8b597f33e75d04b84be7c9d7081a3b97821617d.tar.gz
libreboot-d8b597f33e75d04b84be7c9d7081a3b97821617d.tar.bz2
Chromebook C201 (codename veyron_speedy) support
This introduces Libreboot support for the Asus Chromebook C201 (codename veyron_speedy). At this point, this produces a standalone Libreboot image that can be flashed to the RO Coreboot partition of the SPI flash, as well as the Libreboot version that can be flash to the RO Firmware ID partition. Libreboot on the Chromebook C201 uses the depthcharge bootloader, modified to display text messages instead of ChromeOS bitmaps (that encourage the use of ChromeOS). For convenience, an installation script, chromebook-flash-replace, is provided along with a description of the flash layout, to ease the replacement of the Coreboot and RO Firmware ID partitions on the full SPI flash image. Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
Diffstat (limited to 'resources/libreboot/patch')
-rw-r--r--resources/libreboot/patch/chromebook/0001-armv7-Word-sized-half-word-sized-memory-operations-f.patch89
-rw-r--r--resources/libreboot/patch/chromebook/0002-chromeos-Allow-disabling-vboot-firmware-verification.patch84
-rw-r--r--resources/libreboot/patch/vboot/0001-firmware-Developer-mode-timeout-delay-shortening-dow.patch33
-rw-r--r--resources/libreboot/patch/vboot/0002-firmware-Text-based-screen-display-in-priority.patch39
-rw-r--r--resources/libreboot/patch/vboot/0003-firmware-NV-context-pointer-handoff-to-VbExDisplaySc.patch79
-rw-r--r--resources/libreboot/patch/vboot/0004-firmware-Hold-key-combination-in-developer-mode.patch50
-rw-r--r--resources/libreboot/patch/vboot/0005-firmware-Screen-blank-and-wait-at-disabled-USB-boot-.patch55
-rw-r--r--resources/libreboot/patch/vboot/0006-firmware-Separate-screen-and-wait-at-device-informat.patch79
-rw-r--r--resources/libreboot/patch/vboot/0007-firmware-Localization-keys-removal.patch54
9 files changed, 562 insertions, 0 deletions
diff --git a/resources/libreboot/patch/chromebook/0001-armv7-Word-sized-half-word-sized-memory-operations-f.patch b/resources/libreboot/patch/chromebook/0001-armv7-Word-sized-half-word-sized-memory-operations-f.patch
new file mode 100644
index 0000000..f89b160
--- /dev/null
+++ b/resources/libreboot/patch/chromebook/0001-armv7-Word-sized-half-word-sized-memory-operations-f.patch
@@ -0,0 +1,89 @@
+From 9746b7bf27d4a3c7c0de78b26ec9f217887f4e7d Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Tue, 22 Sep 2015 22:16:33 +0200
+Subject: [PATCH 1/2] armv7: Word-sized/half-word-sized memory operations for
+ 32/16 bit read/write
+
+Some registers only allow word-sized or half-word-sized operations and will
+cause a data fault when accessed with byte-sized operations.
+However, the compiler may or may not break such an operation into smaller
+(byte-sized) chunks. Thus, we need to reliably perform word-sized operations for
+32 bit read/write and half-word-sized operations for 16 bit read/write.
+
+This is particularly the case on the rk3288 SRAM registers, where the watchdog
+tombstone is stored. Moving to GCC 5.2.0 introduced a change of strategy in the
+compiler, where a 32 bit read would be broken into byte-sized chunks, which
+caused a data fault when accessing the watchdog tombstone register.
+
+The definitions for byte-sized memory operations are also adapted to stay
+consistent with the rest.
+
+Change-Id: I1fb3fc139e0a813acf9d70f14386a9603c9f9ede
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ src/arch/arm/include/armv7/arch/io.h | 21 +++++++++++++++------
+ 1 file changed, 15 insertions(+), 6 deletions(-)
+
+diff --git a/src/arch/arm/include/armv7/arch/io.h b/src/arch/arm/include/armv7/arch/io.h
+index 9d06003..94cb131 100644
+--- a/src/arch/arm/include/armv7/arch/io.h
++++ b/src/arch/arm/include/armv7/arch/io.h
+@@ -29,40 +29,49 @@
+
+ static inline uint8_t read8(const void *addr)
+ {
++ uint8_t val;
++
+ dmb();
+- return *(volatile uint8_t *)addr;
++ asm volatile ("ldrb %0, [%1]" : "=r" (val) : "r" (addr) : "memory");
++ return val;
+ }
+
+ static inline uint16_t read16(const void *addr)
+ {
++ uint16_t val;
++
+ dmb();
+- return *(volatile uint16_t *)addr;
++ asm volatile ("ldrh %0, [%1]" : "=r" (val) : "r" (addr) : "memory");
++ return val;
+ }
+
+ static inline uint32_t read32(const void *addr)
+ {
++ uint32_t val;
++
+ dmb();
+- return *(volatile uint32_t *)addr;
++ asm volatile ("ldr %0, [%1]" : "=r" (val) : "r" (addr) : "memory");
++ return val;
+ }
+
+ static inline void write8(void *addr, uint8_t val)
+ {
+ dmb();
+- *(volatile uint8_t *)addr = val;
++ asm volatile ("strb %0, [%1]" : : "r" (val), "r" (addr) : "memory");
+ dmb();
+ }
+
+ static inline void write16(void *addr, uint16_t val)
+ {
+ dmb();
+- *(volatile uint16_t *)addr = val;
++ asm volatile ("strh %0, [%1]" : : "r" (val), "r" (addr) : "memory");
+ dmb();
+ }
+
+ static inline void write32(void *addr, uint32_t val)
+ {
+ dmb();
+- *(volatile uint32_t *)addr = val;
++ asm volatile ("str %0, [%1]" : : "r" (val), "r" (addr) : "memory");
+ dmb();
+ }
+
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/chromebook/0002-chromeos-Allow-disabling-vboot-firmware-verification.patch b/resources/libreboot/patch/chromebook/0002-chromeos-Allow-disabling-vboot-firmware-verification.patch
new file mode 100644
index 0000000..bed24b1
--- /dev/null
+++ b/resources/libreboot/patch/chromebook/0002-chromeos-Allow-disabling-vboot-firmware-verification.patch
@@ -0,0 +1,84 @@
+From d0e6324693214c51e707928e26571ecc9ab8ee03 Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Sun, 9 Aug 2015 10:23:38 +0200
+Subject: [PATCH 2/2] chromeos: Allow disabling vboot firmware verification
+ when ChromeOS is enabled
+
+Some ChromeOS bindings might be wanted without using vboot verification, for
+instance to boot up depthcharge from the version of Coreboot installed in the
+write-protected part of the SPI flash (without jumping to a RW firmware).
+
+Vboot firmware verification is still selected by default when ChromeOS is
+enabled, but this allows more flexibility since vboot firmware verification is
+no longer a hard requirement for ChromeOS (that this particular use case still
+allows booting ChromeOS).
+
+In the future, it would make sense to have all the separate components that
+CONFIG_CHROMEOS enables have their own config options, so that they can be
+enabled separately.
+
+Change-Id: Ia4057a56838aa05dcf3cb250ae1a27fd91402ddb
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ src/lib/bootmode.c | 2 ++
+ src/vendorcode/google/chromeos/Kconfig | 2 +-
+ src/vendorcode/google/chromeos/vboot2/Kconfig | 4 ++++
+ 3 files changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/src/lib/bootmode.c b/src/lib/bootmode.c
+index f2ff72a..13c0130 100644
+--- a/src/lib/bootmode.c
++++ b/src/lib/bootmode.c
+@@ -80,8 +80,10 @@ void gfx_set_init_done(int done)
+ int display_init_required(void)
+ {
+ /* For Chrome OS always honor vboot_skip_display_init(). */
++#if CONFIG_VBOOT_VERIFY_FIRMWARE
+ if (IS_ENABLED(CONFIG_CHROMEOS))
+ return !vboot_skip_display_init();
++#endif
+
+ /* By default always initialize display. */
+ return 1;
+diff --git a/src/vendorcode/google/chromeos/Kconfig b/src/vendorcode/google/chromeos/Kconfig
+index 8309d19..694e0d7 100644
+--- a/src/vendorcode/google/chromeos/Kconfig
++++ b/src/vendorcode/google/chromeos/Kconfig
+@@ -31,7 +31,6 @@ config CHROMEOS
+ select BOOTMODE_STRAPS
+ select ELOG
+ select COLLECT_TIMESTAMPS
+- select VBOOT_VERIFY_FIRMWARE
+ help
+ Enable ChromeOS specific features like the GPIO sub table in
+ the coreboot table. NOTE: Enabling this option on an unsupported
+@@ -129,6 +128,7 @@ config VIRTUAL_DEV_SWITCH
+
+ config VBOOT_VERIFY_FIRMWARE
+ bool "Verify firmware with vboot."
++ default y if CHROMEOS
+ default n
+ depends on HAVE_HARD_RESET
+ help
+diff --git a/src/vendorcode/google/chromeos/vboot2/Kconfig b/src/vendorcode/google/chromeos/vboot2/Kconfig
+index 33c33a5..5bd8b54 100644
+--- a/src/vendorcode/google/chromeos/vboot2/Kconfig
++++ b/src/vendorcode/google/chromeos/vboot2/Kconfig
+@@ -16,6 +16,8 @@
+ ## Foundation, Inc.
+ ##
+
++if VBOOT_VERIFY_FIRMWARE
++
+ config VBOOT_STARTS_IN_BOOTBLOCK
+ bool "Vboot starts verifying in bootblock"
+ default n
+@@ -133,3 +135,5 @@ config VBOOT_DYNAMIC_WORK_BUFFER
+ ram to allocate the vboot work buffer. That means vboot verification
+ is after memory init and requires main memory to back the work
+ buffer.
++
++endif # VBOOT_VERIFY_FIRMWARE
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/vboot/0001-firmware-Developer-mode-timeout-delay-shortening-dow.patch b/resources/libreboot/patch/vboot/0001-firmware-Developer-mode-timeout-delay-shortening-dow.patch
new file mode 100644
index 0000000..f843e50
--- /dev/null
+++ b/resources/libreboot/patch/vboot/0001-firmware-Developer-mode-timeout-delay-shortening-dow.patch
@@ -0,0 +1,33 @@
+From eaf081085930dd7614e2f77bbc1f80d6b1e003eb Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Mon, 10 Aug 2015 20:33:23 +0200
+Subject: [PATCH 1/7] firmware: Developer mode timeout delay shortening (down
+ to 3 seconds)
+
+A timeout delay of 3 seconds, with no bip, is much more appreciable for users.
+
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ firmware/lib/vboot_audio.c | 6 +-----
+ 1 file changed, 1 insertion(+), 5 deletions(-)
+
+diff --git a/firmware/lib/vboot_audio.c b/firmware/lib/vboot_audio.c
+index e24a039..f96d5f4 100644
+--- a/firmware/lib/vboot_audio.c
++++ b/firmware/lib/vboot_audio.c
+@@ -30,11 +30,7 @@
+ #define MAX_CUSTOM_DELAY 60000
+
+ /* These are visible externally only to make testing easier */
+-VbDevMusicNote default_notes_[] = { {20000, 0}, /* 20 seconds */
+- {250, 400}, /* two beeps */
+- {250, 0},
+- {250, 400},
+- {9250, 0} }; /* total 30 seconds */
++VbDevMusicNote default_notes_[] = { {3000, 0} }; /* three seconds */
+ uint32_t default_count_ = sizeof(default_notes_) / sizeof(VbDevMusicNote);
+
+ VbDevMusicNote short_notes_[] = { {2000, 0} }; /* two seconds */
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/vboot/0002-firmware-Text-based-screen-display-in-priority.patch b/resources/libreboot/patch/vboot/0002-firmware-Text-based-screen-display-in-priority.patch
new file mode 100644
index 0000000..3e2a997
--- /dev/null
+++ b/resources/libreboot/patch/vboot/0002-firmware-Text-based-screen-display-in-priority.patch
@@ -0,0 +1,39 @@
+From ceb9ba56a8ef48e18712c38d97b8541a324c7edd Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Mon, 10 Aug 2015 22:44:50 +0200
+Subject: [PATCH 2/7] firmware: Text-based screen display in priority
+
+This allows showing text-based screen displays before looking at the GBB bitmaps
+since those encourage the use of non-free software (Chrome OS) and don't display
+enough information to the user.
+
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ firmware/lib/vboot_display.c | 9 ++++-----
+ 1 file changed, 4 insertions(+), 5 deletions(-)
+
+diff --git a/firmware/lib/vboot_display.c b/firmware/lib/vboot_display.c
+index c3cc636..542aaed 100644
+--- a/firmware/lib/vboot_display.c
++++ b/firmware/lib/vboot_display.c
+@@ -324,13 +324,12 @@ VbError_t VbDisplayScreen(VbCommonParams *cparams, uint32_t screen,
+ /* Request the screen */
+ disp_current_screen = screen;
+
+- /* Look in the GBB first */
+- if (VBERROR_SUCCESS == VbDisplayScreenFromGBB(cparams, screen,
+- vncptr))
++ /* Display default first */
++ if (VBERROR_SUCCESS == VbExDisplayScreen(screen))
+ return VBERROR_SUCCESS;
+
+- /* If screen wasn't in the GBB bitmaps, fall back to a default */
+- return VbExDisplayScreen(screen);
++ /* If default doesn't have anything to show, fall back to GBB bitmaps */
++ return VbDisplayScreenFromGBB(cparams, screen, vncptr);
+ }
+
+ static void Uint8ToString(char *buf, uint8_t val)
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/vboot/0003-firmware-NV-context-pointer-handoff-to-VbExDisplaySc.patch b/resources/libreboot/patch/vboot/0003-firmware-NV-context-pointer-handoff-to-VbExDisplaySc.patch
new file mode 100644
index 0000000..a9d85a0
--- /dev/null
+++ b/resources/libreboot/patch/vboot/0003-firmware-NV-context-pointer-handoff-to-VbExDisplaySc.patch
@@ -0,0 +1,79 @@
+From 5bd1373a9313bc31bacb2d765ede2c19242a7e9b Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Mon, 10 Aug 2015 22:46:43 +0200
+Subject: [PATCH 3/7] firmware: NV context pointer handoff to VbExDisplayScreen
+
+VbExDisplayScreen might need to display some information based on the NV context
+so it makes sense to pass that pointer along.
+
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ firmware/include/vboot_api.h | 3 ++-
+ firmware/lib/vboot_display.c | 2 +-
+ firmware/stub/vboot_api_stub.c | 2 +-
+ tests/vboot_api_devmode_tests.c | 2 +-
+ 4 files changed, 5 insertions(+), 4 deletions(-)
+
+diff --git a/firmware/include/vboot_api.h b/firmware/include/vboot_api.h
+index 7e94773..66d1ee4 100644
+--- a/firmware/include/vboot_api.h
++++ b/firmware/include/vboot_api.h
+@@ -24,6 +24,7 @@
+ #include <stdint.h>
+ #include <stdlib.h>
+
++#include "vboot_nvstorage.h"
+ #include "gpt.h"
+
+ /*****************************************************************************/
+@@ -765,7 +766,7 @@ VbError_t VbExDisplaySetDimension(uint32_t width, uint32_t height);
+ * to be simple ASCII text such as "NO GOOD" or "INSERT"; these screens should
+ * only be seen during development.
+ */
+-VbError_t VbExDisplayScreen(uint32_t screen_type);
++VbError_t VbExDisplayScreen(uint32_t screen_type, VbNvContext *vnc);
+
+ /**
+ * Write an image to the display, with the upper left corner at the specified
+diff --git a/firmware/lib/vboot_display.c b/firmware/lib/vboot_display.c
+index 542aaed..0158cc2 100644
+--- a/firmware/lib/vboot_display.c
++++ b/firmware/lib/vboot_display.c
+@@ -325,7 +325,7 @@ VbError_t VbDisplayScreen(VbCommonParams *cparams, uint32_t screen,
+ disp_current_screen = screen;
+
+ /* Display default first */
+- if (VBERROR_SUCCESS == VbExDisplayScreen(screen))
++ if (VBERROR_SUCCESS == VbExDisplayScreen(screen, vncptr))
+ return VBERROR_SUCCESS;
+
+ /* If default doesn't have anything to show, fall back to GBB bitmaps */
+diff --git a/firmware/stub/vboot_api_stub.c b/firmware/stub/vboot_api_stub.c
+index 7320b6c..f773b6e 100644
+--- a/firmware/stub/vboot_api_stub.c
++++ b/firmware/stub/vboot_api_stub.c
+@@ -43,7 +43,7 @@ VbError_t VbExDisplaySetDimension(uint32_t width, uint32_t height)
+ return VBERROR_SUCCESS;
+ }
+
+-VbError_t VbExDisplayScreen(uint32_t screen_type)
++VbError_t VbExDisplayScreen(uint32_t screen_type, VbNvContext *vnc)
+ {
+ return VBERROR_SUCCESS;
+ }
+diff --git a/tests/vboot_api_devmode_tests.c b/tests/vboot_api_devmode_tests.c
+index 925a146..af90f7f 100644
+--- a/tests/vboot_api_devmode_tests.c
++++ b/tests/vboot_api_devmode_tests.c
+@@ -265,7 +265,7 @@ VbError_t VbExBeep(uint32_t msec, uint32_t frequency) {
+ return beep_return;
+ }
+
+-VbError_t VbExDisplayScreen(uint32_t screen_type) {
++VbError_t VbExDisplayScreen(uint32_t screen_type, VbNvContext *vnc) {
+ switch(screen_type) {
+ case VB_SCREEN_BLANK:
+ VBDEBUG(("VbExDisplayScreen(BLANK)\n"));
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/vboot/0004-firmware-Hold-key-combination-in-developer-mode.patch b/resources/libreboot/patch/vboot/0004-firmware-Hold-key-combination-in-developer-mode.patch
new file mode 100644
index 0000000..1980d77
--- /dev/null
+++ b/resources/libreboot/patch/vboot/0004-firmware-Hold-key-combination-in-developer-mode.patch
@@ -0,0 +1,50 @@
+From 741adbf4fdb4ef72245f9373a2980ecade41f3f5 Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Mon, 10 Aug 2015 22:59:50 +0200
+Subject: [PATCH 4/7] firmware: Hold key combination in developer mode
+
+This binds the Ctrl + H key combination to hold the developer mode screen.
+
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ firmware/lib/vboot_api_kernel.c | 10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
+diff --git a/firmware/lib/vboot_api_kernel.c b/firmware/lib/vboot_api_kernel.c
+index 312014b..e191137 100644
+--- a/firmware/lib/vboot_api_kernel.c
++++ b/firmware/lib/vboot_api_kernel.c
+@@ -251,7 +251,7 @@ VbError_t VbBootDeveloper(VbCommonParams *cparams, LoadKernelParams *p)
+ GoogleBinaryBlockHeader *gbb = cparams->gbb;
+ VbSharedDataHeader *shared =
+ (VbSharedDataHeader *)cparams->shared_data_blob;
+- uint32_t allow_usb = 0, allow_legacy = 0, ctrl_d_pressed = 0;
++ uint32_t allow_usb = 0, allow_legacy = 0, ctrl_d_pressed = 0, hold = 0;
+ VbAudioContext *audio = 0;
+
+ VBDEBUG(("Entering %s()\n", __func__));
+@@ -364,6 +364,12 @@ VbError_t VbBootDeveloper(VbCommonParams *cparams, LoadKernelParams *p)
+ ctrl_d_pressed = 1;
+ goto fallout;
+ break;
++ case 0x08:
++ /* Ctrl+H = hold */
++ VBDEBUG(("VbBootDeveloper() - "
++ "hold developer mode screen\n"));
++ hold = 1;
++ break;
+ case 0x0c:
+ VBDEBUG(("VbBootDeveloper() - "
+ "user pressed Ctrl+L; Try legacy boot\n"));
+@@ -430,7 +436,7 @@ VbError_t VbBootDeveloper(VbCommonParams *cparams, LoadKernelParams *p)
+ VbCheckDisplayKey(cparams, key, &vnc);
+ break;
+ }
+- } while(VbAudioLooping(audio));
++ } while(hold || VbAudioLooping(audio));
+
+ fallout:
+
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/vboot/0005-firmware-Screen-blank-and-wait-at-disabled-USB-boot-.patch b/resources/libreboot/patch/vboot/0005-firmware-Screen-blank-and-wait-at-disabled-USB-boot-.patch
new file mode 100644
index 0000000..82d0d95
--- /dev/null
+++ b/resources/libreboot/patch/vboot/0005-firmware-Screen-blank-and-wait-at-disabled-USB-boot-.patch
@@ -0,0 +1,55 @@
+From 05a34ae55a702d0e415811fedb959f71bbd782d5 Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Mon, 10 Aug 2015 23:13:49 +0200
+Subject: [PATCH 5/7] firmware: Screen blank and wait at disabled USB boot
+ warning
+
+This blanks the screen before showing the disabled USB boot warning.
+It also waits for the user to press any key to come back to the developer mode
+screen.
+
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ firmware/lib/vboot_api_kernel.c | 12 +++++++++++-
+ 1 file changed, 11 insertions(+), 1 deletion(-)
+
+diff --git a/firmware/lib/vboot_api_kernel.c b/firmware/lib/vboot_api_kernel.c
+index e191137..6463571 100644
+--- a/firmware/lib/vboot_api_kernel.c
++++ b/firmware/lib/vboot_api_kernel.c
+@@ -266,6 +266,7 @@ VbError_t VbBootDeveloper(VbCommonParams *cparams, LoadKernelParams *p)
+ if (gbb->flags & GBB_FLAG_FORCE_DEV_BOOT_LEGACY)
+ allow_legacy = 1;
+
++developer_mode_screen:
+ /* Show the dev mode warning screen */
+ VbDisplayScreen(cparams, VB_SCREEN_DEVELOPER_WARNING, 0, &vnc);
+
+@@ -388,14 +389,23 @@ VbError_t VbBootDeveloper(VbCommonParams *cparams, LoadKernelParams *p)
+ if (!allow_usb) {
+ VBDEBUG(("VbBootDeveloper() - "
+ "USB booting is disabled\n"));
++
++ VbDisplayScreen(cparams, VB_SCREEN_BLANK, 1,
++ &vnc);
++
+ VbExDisplayDebugInfo(
+ "WARNING: Booting from external media "
+ "(USB/SD) has not been enabled. Refer "
+ "to the developer-mode documentation "
+- "for details.\n");
++ "for details.\n\n"
++ "Press any key to continue.\n\n");
+ VbExBeep(120, 400);
+ VbExSleepMs(120);
+ VbExBeep(120, 400);
++
++ while (!VbExKeyboardRead()) ;
++
++ goto developer_mode_screen;
+ } else {
+ /*
+ * Clear the screen to show we get the Ctrl+U
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/vboot/0006-firmware-Separate-screen-and-wait-at-device-informat.patch b/resources/libreboot/patch/vboot/0006-firmware-Separate-screen-and-wait-at-device-informat.patch
new file mode 100644
index 0000000..e2d4ef7
--- /dev/null
+++ b/resources/libreboot/patch/vboot/0006-firmware-Separate-screen-and-wait-at-device-informat.patch
@@ -0,0 +1,79 @@
+From b724719ae34c3fd7c25502339f9029ee9e0bbb1e Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Mon, 10 Aug 2015 23:53:48 +0200
+Subject: [PATCH 6/7] firmware: Separate screen and wait at device information
+ screen
+
+This blanks the screen (instead of redrawing it) at device information and
+waits for the user to press any key to come back to the developer mode screen.
+
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ firmware/lib/vboot_api_kernel.c | 12 ++++++++++++
+ firmware/lib/vboot_display.c | 13 ++++++++-----
+ 2 files changed, 20 insertions(+), 5 deletions(-)
+
+diff --git a/firmware/lib/vboot_api_kernel.c b/firmware/lib/vboot_api_kernel.c
+index 6463571..2f33258 100644
+--- a/firmware/lib/vboot_api_kernel.c
++++ b/firmware/lib/vboot_api_kernel.c
+@@ -371,6 +371,18 @@ developer_mode_screen:
+ "hold developer mode screen\n"));
+ hold = 1;
+ break;
++ case 0x09:
++ /* Ctrl+I = device information */
++ VBDEBUG(("VbBootDeveloper() - "
++ "device info\n"));
++
++ hold = 1;
++ VbDisplayDebugInfo(cparams, &vnc);
++
++ while (!VbExKeyboardRead()) ;
++
++ goto developer_mode_screen;
++ break;
+ case 0x0c:
+ VBDEBUG(("VbBootDeveloper() - "
+ "user pressed Ctrl+L; Try legacy boot\n"));
+diff --git a/firmware/lib/vboot_display.c b/firmware/lib/vboot_display.c
+index 0158cc2..c3d504d 100644
+--- a/firmware/lib/vboot_display.c
++++ b/firmware/lib/vboot_display.c
+@@ -503,7 +503,7 @@ const char *RecoveryReasonString(uint8_t code)
+ return "We have no idea what this means";
+ }
+
+-#define DEBUG_INFO_SIZE 512
++#define DEBUG_INFO_SIZE 768
+
+ VbError_t VbDisplayDebugInfo(VbCommonParams *cparams, VbNvContext *vncptr)
+ {
+@@ -518,8 +518,8 @@ VbError_t VbDisplayDebugInfo(VbCommonParams *cparams, VbNvContext *vncptr)
+ VbError_t ret;
+ uint32_t i;
+
+- /* Redisplay current screen to overwrite any previous debug output */
+- VbDisplayScreen(cparams, disp_current_screen, 1, vncptr);
++ /* Blank screen */
++ VbDisplayScreen(cparams, VB_SCREEN_BLANK, 1, vncptr);
+
+ /* Add hardware ID */
+ VbRegionReadHWID(cparams, hwid, sizeof(hwid));
+@@ -622,8 +622,11 @@ VbError_t VbDisplayDebugInfo(VbCommonParams *cparams, VbNvContext *vncptr)
+ used += StrnAppend(buf + used, sha1sum, DEBUG_INFO_SIZE - used);
+ }
+
+- /* Make sure we finish with a newline */
+- used += StrnAppend(buf + used, "\n", DEBUG_INFO_SIZE - used);
++ /* Make sure we finish with newlines */
++ used += StrnAppend(buf + used, "\n\n", DEBUG_INFO_SIZE - used);
++
++ used += StrnAppend(buf + used, "Press any key to continue\n\n",
++ DEBUG_INFO_SIZE - used);
+
+ /* TODO: add more interesting data:
+ * - Information on current disks */
+--
+1.9.1
+
diff --git a/resources/libreboot/patch/vboot/0007-firmware-Localization-keys-removal.patch b/resources/libreboot/patch/vboot/0007-firmware-Localization-keys-removal.patch
new file mode 100644
index 0000000..ca0e684
--- /dev/null
+++ b/resources/libreboot/patch/vboot/0007-firmware-Localization-keys-removal.patch
@@ -0,0 +1,54 @@
+From 982044d150604b74e2bb619ca00042430dd0b73d Mon Sep 17 00:00:00 2001
+From: Paul Kocialkowski <contact@paulk.fr>
+Date: Tue, 11 Aug 2015 00:07:18 +0200
+Subject: [PATCH 7/7] firmware: Localization keys removal
+
+Since we're using a text-based interface, binding the arrow keys to localization
+changes has no effect and only makes the screen flicker.
+
+Signed-off-by: Paul Kocialkowski <contact@paulk.fr>
+---
+ firmware/lib/vboot_api_kernel.c | 6 ------
+ 1 file changed, 6 deletions(-)
+
+diff --git a/firmware/lib/vboot_api_kernel.c b/firmware/lib/vboot_api_kernel.c
+index 2f33258..a5d2f03 100644
+--- a/firmware/lib/vboot_api_kernel.c
++++ b/firmware/lib/vboot_api_kernel.c
+@@ -229,7 +229,6 @@ int VbUserConfirms(VbCommonParams *cparams, uint32_t confirm_flags)
+ return 1;
+ }
+ }
+- VbCheckDisplayKey(cparams, key, &vnc);
+ }
+ VbExSleepMs(CONFIRM_KEY_DELAY);
+ }
+@@ -455,7 +454,6 @@ developer_mode_screen:
+ break;
+ default:
+ VBDEBUG(("VbBootDeveloper() - pressed key %d\n", key));
+- VbCheckDisplayKey(cparams, key, &vnc);
+ break;
+ }
+ } while(hold || VbAudioLooping(audio));
+@@ -539,8 +537,6 @@ VbError_t VbBootRecovery(VbCommonParams *cparams, LoadKernelParams *p)
+ * platforms don't like to scan USB too rapidly.
+ */
+ for (i = 0; i < REC_DISK_DELAY; i += REC_KEY_DELAY) {
+- VbCheckDisplayKey(cparams, VbExKeyboardRead(),
+- &vnc);
+ if (VbWantShutdown(cparams->gbb->flags))
+ return VBERROR_SHUTDOWN_REQUESTED;
+ VbExSleepMs(REC_KEY_DELAY);
+@@ -638,8 +634,6 @@ VbError_t VbBootRecovery(VbCommonParams *cparams, LoadKernelParams *p)
+ i = 4;
+ break;
+ }
+- } else {
+- VbCheckDisplayKey(cparams, key, &vnc);
+ }
+ if (VbWantShutdown(cparams->gbb->flags))
+ return VBERROR_SHUTDOWN_REQUESTED;
+--
+1.9.1
+