xref: /kernel/liteos_m/Kconfig (revision 3d8536b4)
13d8536b4Sopenharmony_ci# Copyright (c) 2013-2019 Huawei Technologies Co., Ltd. All rights reserved.
23d8536b4Sopenharmony_ci# Copyright (c) 2020-2022 Huawei Device Co., Ltd. All rights reserved.
33d8536b4Sopenharmony_ci#
43d8536b4Sopenharmony_ci# Redistribution and use in source and binary forms, with or without modification,
53d8536b4Sopenharmony_ci# are permitted provided that the following conditions are met:
63d8536b4Sopenharmony_ci#
73d8536b4Sopenharmony_ci# 1. Redistributions of source code must retain the above copyright notice, this list of
83d8536b4Sopenharmony_ci#    conditions and the following disclaimer.
93d8536b4Sopenharmony_ci#
103d8536b4Sopenharmony_ci# 2. Redistributions in binary form must reproduce the above copyright notice, this list
113d8536b4Sopenharmony_ci#    of conditions and the following disclaimer in the documentation and/or other materials
123d8536b4Sopenharmony_ci#    provided with the distribution.
133d8536b4Sopenharmony_ci#
143d8536b4Sopenharmony_ci# 3. Neither the name of the copyright holder nor the names of its contributors may be used
153d8536b4Sopenharmony_ci#    to endorse or promote products derived from this software without specific prior written
163d8536b4Sopenharmony_ci#    permission.
173d8536b4Sopenharmony_ci#
183d8536b4Sopenharmony_ci# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
193d8536b4Sopenharmony_ci# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
203d8536b4Sopenharmony_ci# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
213d8536b4Sopenharmony_ci# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
223d8536b4Sopenharmony_ci# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
233d8536b4Sopenharmony_ci# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
243d8536b4Sopenharmony_ci# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
253d8536b4Sopenharmony_ci# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
263d8536b4Sopenharmony_ci# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
273d8536b4Sopenharmony_ci# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
283d8536b4Sopenharmony_ci# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
293d8536b4Sopenharmony_ci
303d8536b4Sopenharmony_cimainmenu "Huawei LiteOS Configuration"
313d8536b4Sopenharmony_ci
323d8536b4Sopenharmony_cimenu "Compiler"
333d8536b4Sopenharmony_cichoice
343d8536b4Sopenharmony_ci    prompt "Compiler type"
353d8536b4Sopenharmony_ci    default COMPILER_GCC
363d8536b4Sopenharmony_ci    help
373d8536b4Sopenharmony_ci      Choose compiler type.
383d8536b4Sopenharmony_ci
393d8536b4Sopenharmony_ciconfig COMPILER_GCC
403d8536b4Sopenharmony_ci    bool "GCC"
413d8536b4Sopenharmony_ci
423d8536b4Sopenharmony_ciconfig COMPILER_CLANG_LLVM
433d8536b4Sopenharmony_ci    bool "Clang"
443d8536b4Sopenharmony_ci
453d8536b4Sopenharmony_ciconfig COMPILER_ICCARM
463d8536b4Sopenharmony_ci    bool "ICCARM"
473d8536b4Sopenharmony_ci
483d8536b4Sopenharmony_ciendchoice
493d8536b4Sopenharmony_ci
503d8536b4Sopenharmony_ciconfig COMPILE_DEBUG
513d8536b4Sopenharmony_ci    bool "Enable debug options"
523d8536b4Sopenharmony_ci    default n
533d8536b4Sopenharmony_ci    help
543d8536b4Sopenharmony_ci      Answer Y to add -g option in compile command.
553d8536b4Sopenharmony_ci
563d8536b4Sopenharmony_ciconfig COMPILE_OPTIMIZE
573d8536b4Sopenharmony_ci    bool "Enable code optimization options"
583d8536b4Sopenharmony_ci    default y
593d8536b4Sopenharmony_ci    help
603d8536b4Sopenharmony_ci      Answer Y to add optimization options for efficient code.
613d8536b4Sopenharmony_ci      The final binary size will be smaller and execute faster.
623d8536b4Sopenharmony_ci      But the debugging experience may be worst somehow.
633d8536b4Sopenharmony_ci
643d8536b4Sopenharmony_ciconfig COMPILE_OPTIMIZE_SIZE
653d8536b4Sopenharmony_ci    bool "Enable code size optimization options" if COMPILE_OPTIMIZE
663d8536b4Sopenharmony_ci    default y
673d8536b4Sopenharmony_ci    help
683d8536b4Sopenharmony_ci      Answer Y to add optimization options for small code size.
693d8536b4Sopenharmony_ci      The final binary size will be smaller.
703d8536b4Sopenharmony_ci      But the compile time may be a bit longer.
713d8536b4Sopenharmony_ci
723d8536b4Sopenharmony_ciconfig COMPILE_LTO
733d8536b4Sopenharmony_ci    bool "Enable link time optimization (LTO)" if COMPILE_OPTIMIZE_SIZE
743d8536b4Sopenharmony_ci    default y
753d8536b4Sopenharmony_ci    help
763d8536b4Sopenharmony_ci      Answer Y to add lto options for more smaller code size.
773d8536b4Sopenharmony_ci      The final binary size will be smaller.
783d8536b4Sopenharmony_ci      But the compile time may be much longer.
793d8536b4Sopenharmony_ci
803d8536b4Sopenharmony_ciendmenu
813d8536b4Sopenharmony_ci
823d8536b4Sopenharmony_cimenu "Platform"
833d8536b4Sopenharmony_ci
843d8536b4Sopenharmony_ci######################### config options of bsp #####################
853d8536b4Sopenharmony_ciconfig PLATFORM
863d8536b4Sopenharmony_ci    string
873d8536b4Sopenharmony_ci    default "virt"            if PLATFORM_QEMU_ARM_VIRT_CM7 || PLATFORM_QEMU_ARM_VIRT_CM4 || PLATFORM_QEMU_ARM_VIRT_CM55 || PRODUCT_QEMU_RISCV32_VIRT || PLATFORM_QEMU_CSKY_SMARTL || PLATFORM_QEMU_XTENSA_ESP32
883d8536b4Sopenharmony_ci
893d8536b4Sopenharmony_ciconfig DEVICE_COMPANY
903d8536b4Sopenharmony_ci    string
913d8536b4Sopenharmony_ci    default "qemu" if PLATFORM_QEMU_ARM_VIRT_CM7 || PLATFORM_QEMU_ARM_VIRT_CM4 || PLATFORM_QEMU_ARM_VIRT_CM55 || PRODUCT_QEMU_RISCV32_VIRT || PLATFORM_QEMU_CSKY_SMARTL || PLATFORM_QEMU_XTENSA_ESP32
923d8536b4Sopenharmony_ci
933d8536b4Sopenharmony_cichoice
943d8536b4Sopenharmony_ci    prompt "Chip"
953d8536b4Sopenharmony_ci    default PLATFORM_QEMU_ARM_VIRT_CM7
963d8536b4Sopenharmony_ci    help
973d8536b4Sopenharmony_ci      Qemu ARM Virt variants (based on different CPU types):
983d8536b4Sopenharmony_ci       - qemu_arm_virt_cm7
993d8536b4Sopenharmony_ci       - qemu_arm_virt_cm4
1003d8536b4Sopenharmony_ci       - qemu_riscv32_virt
1013d8536b4Sopenharmony_ci       - qemu_csky_smartl
1023d8536b4Sopenharmony_ci       - qemu_xtensa_esp32
1033d8536b4Sopenharmony_ci
1043d8536b4Sopenharmony_ciconfig PLATFORM_QEMU_ARM_VIRT_CM7
1053d8536b4Sopenharmony_ci    bool "qemu_arm_virt_cm7"
1063d8536b4Sopenharmony_ci    select ARCH_CORTEX_M7
1073d8536b4Sopenharmony_ci    help
1083d8536b4Sopenharmony_ci        QEMU ARM Virtual Platform using Cortex-M7 CPU.
1093d8536b4Sopenharmony_ci
1103d8536b4Sopenharmony_ciconfig PLATFORM_QEMU_ARM_VIRT_CM4
1113d8536b4Sopenharmony_ci    bool "qemu_arm_virt_cm4"
1123d8536b4Sopenharmony_ci    select ARCH_CORTEX_M4
1133d8536b4Sopenharmony_ci    help
1143d8536b4Sopenharmony_ci        QEMU ARM Virtual Platform using Cortex-M4 CPU.
1153d8536b4Sopenharmony_ci
1163d8536b4Sopenharmony_ciconfig PLATFORM_QEMU_ARM_VIRT_CM55
1173d8536b4Sopenharmony_ci    bool "qemu_arm_virt_cm55"
1183d8536b4Sopenharmony_ci    select ARCH_CORTEX_M55
1193d8536b4Sopenharmony_ci    help
1203d8536b4Sopenharmony_ci        QEMU ARM Virtual Platform using Cortex-M55 CPU.
1213d8536b4Sopenharmony_ci
1223d8536b4Sopenharmony_ciconfig PLATFORM_QEMU_RISCV32_VIRT
1233d8536b4Sopenharmony_ci    bool "qemu_riscv32_virt"
1243d8536b4Sopenharmony_ci    select ARCH_RISCV32
1253d8536b4Sopenharmony_ci    help
1263d8536b4Sopenharmony_ci        QEMU RISCV Virtual Platform using riscv32 CPU.
1273d8536b4Sopenharmony_ci
1283d8536b4Sopenharmony_ciconfig PLATFORM_QEMU_CSKY_SMARTL
1293d8536b4Sopenharmony_ci    bool "qemu_csky_smartl"
1303d8536b4Sopenharmony_ci    select ARCH_CSKY
1313d8536b4Sopenharmony_ci    help
1323d8536b4Sopenharmony_ci        QEMU SmartL Virtual Platform using csky CPU.
1333d8536b4Sopenharmony_ci
1343d8536b4Sopenharmony_ciconfig PLATFORM_QEMU_XTENSA_ESP32
1353d8536b4Sopenharmony_ci    bool "qemu_xtensa_esp32"
1363d8536b4Sopenharmony_ci    select ARCH_XTENSA
1373d8536b4Sopenharmony_ci    help
1383d8536b4Sopenharmony_ci        QEMU ESP32 Virtual Platform using xtensa CPU.
1393d8536b4Sopenharmony_ci
1403d8536b4Sopenharmony_ciendchoice
1413d8536b4Sopenharmony_ci
1423d8536b4Sopenharmony_cichoice
1433d8536b4Sopenharmony_ci    prompt "Product"
1443d8536b4Sopenharmony_ci    help
1453d8536b4Sopenharmony_ci      Select your target board.
1463d8536b4Sopenharmony_ci
1473d8536b4Sopenharmony_ciconfig PRODUCT_QEMU_RISCV32_VIRT
1483d8536b4Sopenharmony_ci    bool "riscv32_virt" if PLATFORM_QEMU_RISCV32_VIRT
1493d8536b4Sopenharmony_ci
1503d8536b4Sopenharmony_ciendchoice
1513d8536b4Sopenharmony_ci
1523d8536b4Sopenharmony_ci
1533d8536b4Sopenharmony_ci######################### config options of cpu arch ################
1543d8536b4Sopenharmony_cisource "arch/Kconfig"
1553d8536b4Sopenharmony_ci
1563d8536b4Sopenharmony_ci# Device Kconfig import
1573d8536b4Sopenharmony_ciosource "$(DEVICE_PATH)/Kconfig"
1583d8536b4Sopenharmony_ci
1593d8536b4Sopenharmony_ciconfig SOC_COMPANY
1603d8536b4Sopenharmony_ci    string "SoC company name to locate soc build path"
1613d8536b4Sopenharmony_ci    help
1623d8536b4Sopenharmony_ci      This option specifies the SoC company name, used to locate the build path for soc. This option is set by the
1633d8536b4Sopenharmony_ci      SoC's Kconfig file, and should be exactly the same with SoC company path, and the user should generally avoid
1643d8536b4Sopenharmony_ci       modifying it via the menu configuration.
1653d8536b4Sopenharmony_ci
1663d8536b4Sopenharmony_ciorsource "../../device/board/*/Kconfig.liteos_m.shields"
1673d8536b4Sopenharmony_ci
1683d8536b4Sopenharmony_ciorsource "../../device/board/$(BOARD_COMPANY)/Kconfig.liteos_m.defconfig.boards"
1693d8536b4Sopenharmony_ci
1703d8536b4Sopenharmony_cichoice
1713d8536b4Sopenharmony_ci    prompt "Board Selection"
1723d8536b4Sopenharmony_ci
1733d8536b4Sopenharmony_ciorsource "../../device/board/$(BOARD_COMPANY)/Kconfig.liteos_m.boards"
1743d8536b4Sopenharmony_ci
1753d8536b4Sopenharmony_ciendchoice
1763d8536b4Sopenharmony_ci
1773d8536b4Sopenharmony_ciorsource "../../device/soc/*/Kconfig.liteos_m.defconfig"
1783d8536b4Sopenharmony_ci
1793d8536b4Sopenharmony_cichoice
1803d8536b4Sopenharmony_ci    prompt "SoC Series Selection"
1813d8536b4Sopenharmony_ci
1823d8536b4Sopenharmony_ciorsource "../../device/soc/*/Kconfig.liteos_m.series"
1833d8536b4Sopenharmony_ci
1843d8536b4Sopenharmony_ciendchoice
1853d8536b4Sopenharmony_ci
1863d8536b4Sopenharmony_ciorsource "../../device/soc/*/Kconfig.liteos_m.soc"
1873d8536b4Sopenharmony_ci
1883d8536b4Sopenharmony_ciendmenu
1893d8536b4Sopenharmony_ci
1903d8536b4Sopenharmony_ci######################### config options of kernel #####################
1913d8536b4Sopenharmony_cimenu "Kernel"
1923d8536b4Sopenharmony_ci
1933d8536b4Sopenharmony_ci######################### config options of extended #####################
1943d8536b4Sopenharmony_ci
1953d8536b4Sopenharmony_ciconfig KERNEL_EXTKERNEL
1963d8536b4Sopenharmony_ci    bool "Enable Extend Kernel"
1973d8536b4Sopenharmony_ci    default y
1983d8536b4Sopenharmony_ci    help
1993d8536b4Sopenharmony_ci      This option will enable extend Kernel of LiteOS.  Extend kernel include
2003d8536b4Sopenharmony_ci      cppsupport, cpup, etc. You can select one or some
2013d8536b4Sopenharmony_ci      of them.
2023d8536b4Sopenharmony_ci
2033d8536b4Sopenharmony_ciconfig KERNEL_BACKTRACE
2043d8536b4Sopenharmony_ci    bool "Enable Backtrace"
2053d8536b4Sopenharmony_ci    default n
2063d8536b4Sopenharmony_ci    depends on KERNEL_EXTKERNEL
2073d8536b4Sopenharmony_ci    help
2083d8536b4Sopenharmony_ci      If you wish to build LiteOS with support for backtrace.
2093d8536b4Sopenharmony_ci
2103d8536b4Sopenharmony_cichoice
2113d8536b4Sopenharmony_ci    prompt "Select Backtrace Type"
2123d8536b4Sopenharmony_ci    depends on KERNEL_BACKTRACE
2133d8536b4Sopenharmony_ci
2143d8536b4Sopenharmony_ciconfig BACKTRACE_TYPE_1
2153d8536b4Sopenharmony_ci    bool "1: Call stack analysis for cortex-m series by scanning the stack"
2163d8536b4Sopenharmony_ci    depends on ARCH_ARM && !ARCH_ARM9
2173d8536b4Sopenharmony_ci
2183d8536b4Sopenharmony_ciconfig BACKTRACE_TYPE_2
2193d8536b4Sopenharmony_ci    bool "2: Call stack analysis for risc-v by using frame pointer"
2203d8536b4Sopenharmony_ci    depends on ARCH_RISCV
2213d8536b4Sopenharmony_ci
2223d8536b4Sopenharmony_ciconfig BACKTRACE_TYPE_3
2233d8536b4Sopenharmony_ci    bool "3: Call stack analysis for risc-v by scanning the stack"
2243d8536b4Sopenharmony_ci    depends on ARCH_RISCV
2253d8536b4Sopenharmony_ci
2263d8536b4Sopenharmony_ciconfig BACKTRACE_TYPE_4
2273d8536b4Sopenharmony_ci    bool "4: Call stack analysis for xtensa by scanning the stack"
2283d8536b4Sopenharmony_ci    depends on ARCH_XTENSA
2293d8536b4Sopenharmony_ci
2303d8536b4Sopenharmony_ciconfig BACKTRACE_TYPE_5
2313d8536b4Sopenharmony_ci    bool "5: Call stack analysis for c-sky by scanning the stack"
2323d8536b4Sopenharmony_ci    depends on ARCH_CSKY
2333d8536b4Sopenharmony_ci
2343d8536b4Sopenharmony_ciconfig BACKTRACE_TYPE_6
2353d8536b4Sopenharmony_ci    bool "6: Call stack analysis for arm9 by scanning the stack"
2363d8536b4Sopenharmony_ci    depends on ARCH_ARM9
2373d8536b4Sopenharmony_ci
2383d8536b4Sopenharmony_ciendchoice
2393d8536b4Sopenharmony_ci
2403d8536b4Sopenharmony_ciconfig BACKTRACE_TYPE
2413d8536b4Sopenharmony_ci    int
2423d8536b4Sopenharmony_ci    default 0 if ! KERNEL_BACKTRACE
2433d8536b4Sopenharmony_ci    default 1 if BACKTRACE_TYPE_1
2443d8536b4Sopenharmony_ci    default 2 if BACKTRACE_TYPE_2
2453d8536b4Sopenharmony_ci    default 3 if BACKTRACE_TYPE_3
2463d8536b4Sopenharmony_ci    default 4 if BACKTRACE_TYPE_4
2473d8536b4Sopenharmony_ci    default 5 if BACKTRACE_TYPE_5
2483d8536b4Sopenharmony_ci    default 6 if BACKTRACE_TYPE_6
2493d8536b4Sopenharmony_ci
2503d8536b4Sopenharmony_ciconfig BACKTRACE_DEPTH
2513d8536b4Sopenharmony_ci    int "Backtrace depth"
2523d8536b4Sopenharmony_ci    default 15
2533d8536b4Sopenharmony_ci    depends on KERNEL_BACKTRACE
2543d8536b4Sopenharmony_ci
2553d8536b4Sopenharmony_ciconfig KERNEL_CPPSUPPORT
2563d8536b4Sopenharmony_ci    bool "Enable C++ Support"
2573d8536b4Sopenharmony_ci    default n
2583d8536b4Sopenharmony_ci    depends on KERNEL_EXTKERNEL
2593d8536b4Sopenharmony_ci    help
2603d8536b4Sopenharmony_ci      If you wish to build LiteOS with support for C++.
2613d8536b4Sopenharmony_ci
2623d8536b4Sopenharmony_cirsource "components/signal/Kconfig"
2633d8536b4Sopenharmony_ci
2643d8536b4Sopenharmony_ciconfig BASE_CORE_CPUP
2653d8536b4Sopenharmony_ci    bool
2663d8536b4Sopenharmony_ci    default n
2673d8536b4Sopenharmony_ci
2683d8536b4Sopenharmony_ciconfig KERNEL_CPUP
2693d8536b4Sopenharmony_ci    bool "Enable Cpup"
2703d8536b4Sopenharmony_ci    default n
2713d8536b4Sopenharmony_ci    depends on KERNEL_EXTKERNEL
2723d8536b4Sopenharmony_ci    select BASE_CORE_CPUP
2733d8536b4Sopenharmony_ci    help
2743d8536b4Sopenharmony_ci      If you wish to build LiteOS with support for cpup.
2753d8536b4Sopenharmony_ci
2763d8536b4Sopenharmony_ciconfig CPUP_INCLUDE_IRQ
2773d8536b4Sopenharmony_ci    bool "Enable Cpup include irq"
2783d8536b4Sopenharmony_ci    default y
2793d8536b4Sopenharmony_ci    depends on KERNEL_CPUP
2803d8536b4Sopenharmony_ci    help
2813d8536b4Sopenharmony_ci      If you wish to include irq usage for cpup.
2823d8536b4Sopenharmony_ci
2833d8536b4Sopenharmony_ciconfig KERNEL_DYNLINK
2843d8536b4Sopenharmony_ci    bool "Enable Dynamic Link Feature"
2853d8536b4Sopenharmony_ci    default n
2863d8536b4Sopenharmony_ci    depends on KERNEL_EXTKERNEL && ARCH_ARM
2873d8536b4Sopenharmony_ci    help
2883d8536b4Sopenharmony_ci      If you wish to build LiteOS with support for dynamic link.
2893d8536b4Sopenharmony_ci
2903d8536b4Sopenharmony_ciconfig KERNEL_PM
2913d8536b4Sopenharmony_ci    bool "Enable Power Management"
2923d8536b4Sopenharmony_ci    default n
2933d8536b4Sopenharmony_ci    depends on KERNEL_EXTKERNEL
2943d8536b4Sopenharmony_ci    help
2953d8536b4Sopenharmony_ci      Configuration item for low power frame tailoring.
2963d8536b4Sopenharmony_ci      If you wish to build LiteOS with support for power management.
2973d8536b4Sopenharmony_ci
2983d8536b4Sopenharmony_ciconfig KERNEL_PM_IDLE
2993d8536b4Sopenharmony_ci    bool "Enable Power Management Idle"
3003d8536b4Sopenharmony_ci    default n
3013d8536b4Sopenharmony_ci    depends on KERNEL_PM
3023d8536b4Sopenharmony_ci    help
3033d8536b4Sopenharmony_ci      Configuration item for low power frame tailoring.
3043d8536b4Sopenharmony_ci      If you wish to build LiteOS with support for power management idle.
3053d8536b4Sopenharmony_ci
3063d8536b4Sopenharmony_ciconfig KERNEL_PM_DEBUG
3073d8536b4Sopenharmony_ci    bool "Power Management Debug"
3083d8536b4Sopenharmony_ci    default n
3093d8536b4Sopenharmony_ci    depends on KERNEL_PM
3103d8536b4Sopenharmony_ci    help
3113d8536b4Sopenharmony_ci      Configuration item for low power frame debug tailoring.
3123d8536b4Sopenharmony_ci
3133d8536b4Sopenharmony_ciconfig PLATFORM_EXC
3143d8536b4Sopenharmony_ci    bool "Enable Platform Exc Hook"
3153d8536b4Sopenharmony_ci    default n
3163d8536b4Sopenharmony_ci    depends on KERNEL_EXTKERNEL
3173d8536b4Sopenharmony_ci
3183d8536b4Sopenharmony_ciconfig KERNEL_LMK
3193d8536b4Sopenharmony_ci    bool "Enable Low Memory Killer"
3203d8536b4Sopenharmony_ci    default n
3213d8536b4Sopenharmony_ci    depends on KERNEL_EXTKERNEL
3223d8536b4Sopenharmony_ci    help
3233d8536b4Sopenharmony_ci      Configuration item for low memory killer tailoring.
3243d8536b4Sopenharmony_ci      If you wish to build LiteOS with support for low memory killer.
3253d8536b4Sopenharmony_ci
3263d8536b4Sopenharmony_ciconfig KERNEL_LMK_DEBUG
3273d8536b4Sopenharmony_ci    bool "Low Memory Killer Debug"
3283d8536b4Sopenharmony_ci    default n
3293d8536b4Sopenharmony_ci    depends on KERNEL_LMK
3303d8536b4Sopenharmony_ci    help
3313d8536b4Sopenharmony_ci      Configuration item forlow memory killer debug tailoring.
3323d8536b4Sopenharmony_ci
3333d8536b4Sopenharmony_ci######################### config options of trace #########################
3343d8536b4Sopenharmony_cisource "components/trace/Kconfig"
3353d8536b4Sopenharmony_ci
3363d8536b4Sopenharmony_ci######################### config options of lms #########################
3373d8536b4Sopenharmony_cisource "components/lms/Kconfig"
3383d8536b4Sopenharmony_ci
3393d8536b4Sopenharmony_ciendmenu
3403d8536b4Sopenharmony_ci
3413d8536b4Sopenharmony_ci######################### config options of compatibility ##############
3423d8536b4Sopenharmony_cimenu "Compat"
3433d8536b4Sopenharmony_ci
3443d8536b4Sopenharmony_cirsource "kal/Kconfig"
3453d8536b4Sopenharmony_ci
3463d8536b4Sopenharmony_ciendmenu
3473d8536b4Sopenharmony_ci
3483d8536b4Sopenharmony_ci######################## config options of filesystem ##################
3493d8536b4Sopenharmony_cimenu "FileSystem"
3503d8536b4Sopenharmony_ci
3513d8536b4Sopenharmony_cirsource "components/fs/Kconfig"
3523d8536b4Sopenharmony_ci
3533d8536b4Sopenharmony_ciendmenu
3543d8536b4Sopenharmony_ci
3553d8536b4Sopenharmony_ci######################## config options of net ############################
3563d8536b4Sopenharmony_cimenu "Net"
3573d8536b4Sopenharmony_ciconfig NET_LWIP
3583d8536b4Sopenharmony_ci    bool "Enable Lwip"
3593d8536b4Sopenharmony_ci    default n
3603d8536b4Sopenharmony_ci    select NET_LWIP_SACK
3613d8536b4Sopenharmony_ci
3623d8536b4Sopenharmony_ci    help
3633d8536b4Sopenharmony_ci      Answer Y to enable LiteOS support lwip.
3643d8536b4Sopenharmony_ci
3653d8536b4Sopenharmony_ciconfig NET_LWIP_SACK
3663d8536b4Sopenharmony_ci    bool
3673d8536b4Sopenharmony_ci    default n
3683d8536b4Sopenharmony_ci
3693d8536b4Sopenharmony_ciendmenu
3703d8536b4Sopenharmony_ci
3713d8536b4Sopenharmony_ci######################## config options of debug ########################
3723d8536b4Sopenharmony_cimenu "Debug"
3733d8536b4Sopenharmony_ci
3743d8536b4Sopenharmony_ciconfig THUMB
3753d8536b4Sopenharmony_ci    bool "Enable Thumb"
3763d8536b4Sopenharmony_ci    default n
3773d8536b4Sopenharmony_ci    depends on ARCH_ARM
3783d8536b4Sopenharmony_ci    help
3793d8536b4Sopenharmony_ci      Answer Y to build thumb version.  This will make LiteOS smaller.
3803d8536b4Sopenharmony_ci
3813d8536b4Sopenharmony_ciconfig DEBUG_VERSION
3823d8536b4Sopenharmony_ci    bool "Enable a Debug Version"
3833d8536b4Sopenharmony_ci    default y
3843d8536b4Sopenharmony_ci    help
3853d8536b4Sopenharmony_ci      If you do not select this option that means you enable a release version for LiteOS.
3863d8536b4Sopenharmony_ci      It also means you do not want to use debug modules, like shell,telnet,tftp,nfs and
3873d8536b4Sopenharmony_ci      memory check, etc.
3883d8536b4Sopenharmony_ci      If you select this option that means you enable a debug version for LiteOS.
3893d8536b4Sopenharmony_ci      That means you want a opposite behaviour compared to release version.
3903d8536b4Sopenharmony_ci
3913d8536b4Sopenharmony_ciconfig DEBUG_KERNEL
3923d8536b4Sopenharmony_ci    bool "Enable Debug LiteOS Kernel Resource"
3933d8536b4Sopenharmony_ci    default n
3943d8536b4Sopenharmony_ci    depends on DEBUG_VERSION
3953d8536b4Sopenharmony_ci    help
3963d8536b4Sopenharmony_ci      If you select this option that means you enable debugging kernel resource.
3973d8536b4Sopenharmony_ci      It also means you want to get queue, mutex, semaphore, memory debug information.
3983d8536b4Sopenharmony_ci      That means you want a opposite behaviour compared to release version.
3993d8536b4Sopenharmony_ci
4003d8536b4Sopenharmony_ciconfig MUTEX_CREATE_TRACE
4013d8536b4Sopenharmony_ci    bool "Enable Mutex Trace Debugging"
4023d8536b4Sopenharmony_ci    default n
4033d8536b4Sopenharmony_ci    depends on ARCH_ARM
4043d8536b4Sopenharmony_ci    depends on DEBUG_KERNEL
4053d8536b4Sopenharmony_ci    help
4063d8536b4Sopenharmony_ci      Answer Y to enable debug mutex trace.
4073d8536b4Sopenharmony_ci
4083d8536b4Sopenharmony_ciconfig NET_LWIP_SACK_TFTP
4093d8536b4Sopenharmony_ci    bool "Enable Tftp"
4103d8536b4Sopenharmony_ci    default y
4113d8536b4Sopenharmony_ci    depends on SHELL && NET_LWIP_SACK && DEBUG_VERSION
4123d8536b4Sopenharmony_ci    help
4133d8536b4Sopenharmony_ci      Answer Y to enable LiteOS support tftp cmd and tftp tool.
4143d8536b4Sopenharmony_ci
4153d8536b4Sopenharmony_ciconfig DEBUG_HOOK
4163d8536b4Sopenharmony_ci    bool "Enable Hook Framework"
4173d8536b4Sopenharmony_ci    default n
4183d8536b4Sopenharmony_ci    depends on DEBUG_VERSION
4193d8536b4Sopenharmony_ci    help
4203d8536b4Sopenharmony_ci      Enable the kernel hook framework to support customized trace information capture.
4213d8536b4Sopenharmony_ci
4223d8536b4Sopenharmony_ciconfig SHELL_CMD_DEBUG
4233d8536b4Sopenharmony_ci    bool "Enable shell cmd Debug"
4243d8536b4Sopenharmony_ci    default n
4253d8536b4Sopenharmony_ci    depends on DEBUG_VERSION && SHELL
4263d8536b4Sopenharmony_ci
4273d8536b4Sopenharmony_ciconfig DEBUG_TOOLS
4283d8536b4Sopenharmony_ci    bool "Enable DEBUG TOOLS"
4293d8536b4Sopenharmony_ci    default n
4303d8536b4Sopenharmony_ci    depends on DEBUG_VERSION
4313d8536b4Sopenharmony_ci    help
4323d8536b4Sopenharmony_ci      Answer Y to enable LiteOS debug tools, include stackdump, hwidump, tasktrack.
4333d8536b4Sopenharmony_ci
4343d8536b4Sopenharmony_ciconfig MEM_DEBUG
4353d8536b4Sopenharmony_ci    bool "Enable MEM Debug"
4363d8536b4Sopenharmony_ci    default n
4373d8536b4Sopenharmony_ci    depends on DEBUG_VERSION
4383d8536b4Sopenharmony_ci    help
4393d8536b4Sopenharmony_ci      Answer Y to enable LiteOS support mem debug.
4403d8536b4Sopenharmony_ci
4413d8536b4Sopenharmony_ciconfig MEM_LEAKCHECK
4423d8536b4Sopenharmony_ci    bool "Enable Function call stack of Mem operation recorded"
4433d8536b4Sopenharmony_ci    default n
4443d8536b4Sopenharmony_ci    depends on DEBUG_VERSION && MEM_DEBUG
4453d8536b4Sopenharmony_ci    select KERNEL_BACKTRACE
4463d8536b4Sopenharmony_ci    help
4473d8536b4Sopenharmony_ci      Answer Y to enable record the LR of Function call stack of Mem operation, it can check the mem leak through the information of mem node.
4483d8536b4Sopenharmony_ciconfig BASE_MEM_NODE_INTEGRITY_CHECK
4493d8536b4Sopenharmony_ci    bool "Enable integrity check or not"
4503d8536b4Sopenharmony_ci    default n
4513d8536b4Sopenharmony_ci    depends on DEBUG_VERSION && MEM_DEBUG
4523d8536b4Sopenharmony_ciconfig MEM_WATERLINE
4533d8536b4Sopenharmony_ci    bool "Enable memory pool waterline or not"
4543d8536b4Sopenharmony_ci    default n
4553d8536b4Sopenharmony_ci    depends on DEBUG_VERSION && MEM_DEBUG
4563d8536b4Sopenharmony_ci
4573d8536b4Sopenharmony_ciconfig TASK_MEM_USED
4583d8536b4Sopenharmony_ci    bool "Enable show task mem used or not"
4593d8536b4Sopenharmony_ci    default n
4603d8536b4Sopenharmony_ci    depends on DEBUG_VERSION && MEM_DEBUG
4613d8536b4Sopenharmony_ci
4623d8536b4Sopenharmony_cisource "components/shell/Kconfig"
4633d8536b4Sopenharmony_ci
4643d8536b4Sopenharmony_ciendmenu
4653d8536b4Sopenharmony_ci
4663d8536b4Sopenharmony_ci######################## config options os drivers ########################
4673d8536b4Sopenharmony_cimenu "Driver"
4683d8536b4Sopenharmony_cisource "drivers/Kconfig"
4693d8536b4Sopenharmony_ciendmenu
4703d8536b4Sopenharmony_ci
4713d8536b4Sopenharmony_ci######################## config options os security #######################
4723d8536b4Sopenharmony_cimenu "Security"
4733d8536b4Sopenharmony_ciconfig SECURE_TRUSTZONE
4743d8536b4Sopenharmony_ci    bool "Enable ARM TrustZone"
4753d8536b4Sopenharmony_ci    default n
4763d8536b4Sopenharmony_ci    depends on ARCH_ARM
4773d8536b4Sopenharmony_ci    depends on ARCH_ARM_V8M
4783d8536b4Sopenharmony_ciconfig SECURE_HEAP_SIZE
4793d8536b4Sopenharmony_ci    int "TrustZone Heap Size (bytes)"
4803d8536b4Sopenharmony_ci    default 2048
4813d8536b4Sopenharmony_ci    depends on SECURE_TRUSTZONE
4823d8536b4Sopenharmony_ciconfig SECURE
4833d8536b4Sopenharmony_ci    bool "Enable Security"
4843d8536b4Sopenharmony_ci    default n
4853d8536b4Sopenharmony_ci    select MPU_ENABLE
4863d8536b4Sopenharmony_ciconfig MPU_ENABLE
4873d8536b4Sopenharmony_ci    bool "Enable MPU"
4883d8536b4Sopenharmony_ci    default n
4893d8536b4Sopenharmony_ciendmenu
4903d8536b4Sopenharmony_ci
4913d8536b4Sopenharmony_cimenu "Test"
4923d8536b4Sopenharmony_ciconfig TEST
4933d8536b4Sopenharmony_ci    bool
4943d8536b4Sopenharmony_ci    default n
4953d8536b4Sopenharmony_ciconfig KERNEL_TEST
4963d8536b4Sopenharmony_ci    bool "Enable Kernel Test"
4973d8536b4Sopenharmony_ci    default n
4983d8536b4Sopenharmony_ci    select TEST
4993d8536b4Sopenharmony_ciconfig KERNEL_TEST_FULL
5003d8536b4Sopenharmony_ci    bool "Full Kernel Test"
5013d8536b4Sopenharmony_ci    default n
5023d8536b4Sopenharmony_ci    depends on KERNEL_TEST
5033d8536b4Sopenharmony_ciendmenu
5043d8536b4Sopenharmony_ci
5053d8536b4Sopenharmony_cimenu "Stack Smashing Protector (SSP) Compiler Feature"
5063d8536b4Sopenharmony_ci
5073d8536b4Sopenharmony_cichoice
5083d8536b4Sopenharmony_ci    prompt "Enable stack buffer overflow detection"
5093d8536b4Sopenharmony_ci    default  CC_STACKPROTECTOR_STRONG
5103d8536b4Sopenharmony_ci    ---help---
5113d8536b4Sopenharmony_ci    This option turns on the -fstack-protector GCC feature. This
5123d8536b4Sopenharmony_ci    feature puts, at the beginning of functions, a canary value on
5133d8536b4Sopenharmony_ci    the stack just before the return address, and validates
5143d8536b4Sopenharmony_ci    the value just before actually returning.  Stack based buffer
5153d8536b4Sopenharmony_ci    overflows (that need to overwrite this return address) now also
5163d8536b4Sopenharmony_ci    overwrite the canary, which gets detected and the attack is then
5173d8536b4Sopenharmony_ci    neutralized via a kernel panic.
5183d8536b4Sopenharmony_ci
5193d8536b4Sopenharmony_ci    This feature requires gcc version 4.2 or above, or a distribution
5203d8536b4Sopenharmony_ci    gcc with the feature backported. Older versions are automatically
5213d8536b4Sopenharmony_ci    detected and for those versions, this configuration option is
5223d8536b4Sopenharmony_ci    ignored. (and a warning is printed during bootup)
5233d8536b4Sopenharmony_ci
5243d8536b4Sopenharmony_ciconfig CC_NO_STACKPROTECTOR
5253d8536b4Sopenharmony_ci    bool "-fno-stack-protector"
5263d8536b4Sopenharmony_ci
5273d8536b4Sopenharmony_ciconfig CC_STACKPROTECTOR
5283d8536b4Sopenharmony_ci    bool "-fstack-protector"
5293d8536b4Sopenharmony_ci
5303d8536b4Sopenharmony_ciconfig CC_STACKPROTECTOR_STRONG
5313d8536b4Sopenharmony_ci    bool "-fstack-protector-strong"
5323d8536b4Sopenharmony_ci
5333d8536b4Sopenharmony_ciconfig CC_STACKPROTECTOR_ALL
5343d8536b4Sopenharmony_ci    bool "-fstack-protector-all"
5353d8536b4Sopenharmony_ci
5363d8536b4Sopenharmony_ciendchoice
5373d8536b4Sopenharmony_ci
5383d8536b4Sopenharmony_ciendmenu
539