summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--chip/lm4/config.h6
-rw-r--r--common/firmware_image.S2
-rw-r--r--common/firmware_image.lds.S7
3 files changed, 14 insertions, 1 deletions
diff --git a/chip/lm4/config.h b/chip/lm4/config.h
index 6c3bbddc6d..b70837d21a 100644
--- a/chip/lm4/config.h
+++ b/chip/lm4/config.h
@@ -10,8 +10,12 @@
#define CONFIG_RAM_BASE 0x20000000
#define CONFIG_RAM_SIZE 0x00008000
+/* Disable RW.B firmware due to code size.
+ * TODO: Add it back when we can. */
+#define CONFIG_NO_RW_B
+
/* Size of one firmware image in flash */
-#define CONFIG_FW_IMAGE_SIZE (40 * 1024)
+#define CONFIG_FW_IMAGE_SIZE (60 * 1024)
#define CONFIG_FW_RO_OFF 0
#define CONFIG_FW_A_OFF CONFIG_FW_IMAGE_SIZE
#define CONFIG_FW_B_OFF (2 * CONFIG_FW_IMAGE_SIZE)
diff --git a/common/firmware_image.S b/common/firmware_image.S
index 78207f96cf..8ffe1eb76b 100644
--- a/common/firmware_image.S
+++ b/common/firmware_image.S
@@ -20,6 +20,8 @@
.section .image.A, "ax"
.incbin FW_IMAGE(A)
+#ifndef CONFIG_NO_RW_B
/* Read Write firmware copy B */
.section .image.B, "ax"
.incbin FW_IMAGE(B)
+#endif
diff --git a/common/firmware_image.lds.S b/common/firmware_image.lds.S
index c1c7d59682..c282e7ac28 100644
--- a/common/firmware_image.lds.S
+++ b/common/firmware_image.lds.S
@@ -1,3 +1,8 @@
+/* Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
#include "config.h"
OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
@@ -16,8 +21,10 @@ SECTIONS
.image.A : AT(CONFIG_FW_A_OFF) {
*(.image.A)
} > FLASH
+#ifndef CONFIG_NO_RW_B
. = ALIGN(CONFIG_FLASH_BANK_SIZE);
.image.B : AT(CONFIG_FW_B_OFF) {
*(.image.B)
} > FLASH
+#endif
}