mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-04 22:11:41 +00:00
wheatley: Add CONFIG_LTO definition to reduce FW size.
Add CONFIG_LTO definition to reduce the size of FW image. Modified drivers: 1. board.h: Add CONFIG_LTO definition. 2. header.c: Add __keep keyword to prevent linker ignore header during optimization. BUG=chrome-os-partner:34346 TEST=make buildall -j; test nuvoton IC specific drivers BRANCH=none Change-Id: I6205af37572a68f35f90dbd9b28d86230533ca8b Signed-off-by: Mulin Chao <mlchao@nuvoton.com> Reviewed-on: https://chromium-review.googlesource.com/319799 Reviewed-by: Vincent Palatin <vpalatin@chromium.org> Reviewed-by: Shawn N <shawnn@chromium.org>
This commit is contained in:
@@ -51,6 +51,7 @@
|
||||
#define CONFIG_LID_ANGLE_SENSOR_LID 2
|
||||
#define CONFIG_LID_SWITCH
|
||||
#define CONFIG_LOW_POWER_IDLE
|
||||
#define CONFIG_LTO
|
||||
#define CONFIG_POWER_BUTTON
|
||||
#define CONFIG_POWER_BUTTON_X86
|
||||
#define CONFIG_POWER_COMMON
|
||||
|
||||
@@ -57,7 +57,7 @@ struct __packed fw_header_t {
|
||||
uint32_t sig_fw_image; /* The CRC or Checksum of the firmware image */
|
||||
} __aligned(1);
|
||||
|
||||
__attribute__ ((section(".header")))
|
||||
__keep __attribute__ ((section(".header")))
|
||||
const struct fw_header_t fw_header = {
|
||||
/* 00 */ SIG_FW_EC,
|
||||
/* 04 */ 0x54E1, /* Header CRC check Enable/Disable -> AB1Eh/54E1h */
|
||||
|
||||
Reference in New Issue
Block a user