Andrzej Puzdrowski | 64ad092 | 2017-09-22 11:33:41 +0200 | [diff] [blame] | 1 | # Copyright (c) 2017 Linaro Limited |
| 2 | # |
| 3 | # SPDX-License-Identifier: Apache-2.0 |
| 4 | # |
| 5 | |
Marti Bolivar | 0e091c9 | 2018-04-12 11:23:16 -0400 | [diff] [blame^] | 6 | mainmenu "MCUboot configuration" |
Andrzej Puzdrowski | 64ad092 | 2017-09-22 11:33:41 +0200 | [diff] [blame] | 7 | |
Marti Bolivar | 0e091c9 | 2018-04-12 11:23:16 -0400 | [diff] [blame^] | 8 | comment "MCUboot-specific configuration options" |
Andrzej Puzdrowski | 64ad092 | 2017-09-22 11:33:41 +0200 | [diff] [blame] | 9 | |
Marti Bolivar | 0e091c9 | 2018-04-12 11:23:16 -0400 | [diff] [blame^] | 10 | config BOOT_MAX_IMG_SECTORS |
| 11 | int "Maximum number of sectors per image slot" |
| 12 | default 128 |
| 13 | help |
| 14 | This option controls the maximum number of sectors that each of |
| 15 | the two image areas can contain. Smaller values reduce MCUboot's |
| 16 | memory usage; larger values allow it to support larger images. |
| 17 | If unsure, leave at the default value. |
| 18 | |
| 19 | menuconfig MCUBOOT_SERIAL |
| 20 | bool "MCUboot serial recovery" |
| 21 | default n |
| 22 | select REBOOT |
| 23 | select UART_INTERRUPT_DRIVEN |
| 24 | select SERIAL |
| 25 | select BASE64 |
| 26 | select TINYCBOR |
| 27 | help |
| 28 | If y, enables a serial-port based update mode. This allows |
| 29 | MCUboot itself to load update images into flash over a UART. |
| 30 | If unsure, leave at the default value. |
| 31 | |
| 32 | if MCUBOOT_SERIAL |
| 33 | |
| 34 | config BOOT_MAX_LINE_INPUT_LEN |
| 35 | int "Maximum command line length" |
| 36 | default 512 |
| 37 | help |
| 38 | Maximum length of commands transported over the serial port. |
| 39 | |
| 40 | config BOOT_SERIAL_DETECT_PORT |
| 41 | string "GPIO device to trigger serial recovery mode" |
| 42 | default GPIO_0 if SOC_FAMILY_NRF |
| 43 | help |
| 44 | Zephyr GPIO device which contains the pin used to trigger |
| 45 | serial recovery mode. |
| 46 | |
| 47 | config BOOT_SERIAL_DETECT_PIN |
| 48 | int "Pin to trigger serial recovery mode" |
| 49 | default 11 if BOARD_NRF52840_PCA10056 |
| 50 | default 13 if BOARD_NRF52_PCA10040 |
| 51 | help |
| 52 | Pin on the serial detect port which triggers serial recovery mode. |
| 53 | |
| 54 | config BOOT_SERIAL_DETECT_PIN_VAL |
| 55 | int "Serial detect pin trigger value" |
| 56 | default 0 |
| 57 | range 0 1 |
| 58 | help |
| 59 | Logic value of the detect pin which triggers serial recovery |
| 60 | mode. |
| 61 | |
| 62 | endif # MCUBOOT_SERIAL |
Andrzej Puzdrowski | 64ad092 | 2017-09-22 11:33:41 +0200 | [diff] [blame] | 63 | |
Carles Cufi | 84ede58 | 2018-01-29 15:12:00 +0100 | [diff] [blame] | 64 | config MCUBOOT_DEVICE_SETTINGS |
| 65 | # Hidden selector for device-specific settings |
| 66 | bool |
| 67 | default y |
| 68 | # CPU options |
| 69 | select MCUBOOT_DEVICE_CPU_CORTEX_M0 if CPU_CORTEX_M0 |
Carles Cufi | 67c792e | 2018-01-29 15:14:31 +0100 | [diff] [blame] | 70 | # Enable flash page layout if available |
| 71 | select FLASH_PAGE_LAYOUT if FLASH_HAS_PAGE_LAYOUT |
Carles Cufi | 84ede58 | 2018-01-29 15:12:00 +0100 | [diff] [blame] | 72 | |
| 73 | config MCUBOOT_DEVICE_CPU_CORTEX_M0 |
| 74 | # Hidden selector for Cortex-M0 settings |
| 75 | bool |
| 76 | default n |
| 77 | select SW_VECTOR_RELAY if !CPU_CORTEX_M0_HAS_VECTOR_TABLE_REMAP |
| 78 | |
Marti Bolivar | 0e091c9 | 2018-04-12 11:23:16 -0400 | [diff] [blame^] | 79 | comment "Zephyr configuration options" |
Andrzej Puzdrowski | 64ad092 | 2017-09-22 11:33:41 +0200 | [diff] [blame] | 80 | |
Marti Bolivar | 0e091c9 | 2018-04-12 11:23:16 -0400 | [diff] [blame^] | 81 | config ZEPHYR_BASE |
Andrzej Puzdrowski | 64ad092 | 2017-09-22 11:33:41 +0200 | [diff] [blame] | 82 | string |
Marti Bolivar | 0e091c9 | 2018-04-12 11:23:16 -0400 | [diff] [blame^] | 83 | option env="ZEPHYR_BASE" |
Andrzej Puzdrowski | 64ad092 | 2017-09-22 11:33:41 +0200 | [diff] [blame] | 84 | |
Marti Bolivar | 0e091c9 | 2018-04-12 11:23:16 -0400 | [diff] [blame^] | 85 | source "$ZEPHYR_BASE/Kconfig.zephyr" |