[Feature] 完善components\drivers目录下Kconfig的help提示

This commit is contained in:
ruanqiuqiu
2026-01-02 12:00:21 +08:00
committed by GitHub
parent fdb16a407f
commit 7179ab2e03
44 changed files with 825 additions and 8 deletions

View File

@@ -1,4 +1,8 @@
menu "Device Drivers"
help
Select which RT-Thread driver stacks are built into the firmware. Each
submenu groups related peripherals (IPC, storage, networking, etc.) and
exposes their own configuration knobs.
rsource "core/Kconfig"
rsource "ipc/Kconfig"

View File

@@ -4,18 +4,35 @@ menuconfig RT_USING_ATA
depends on RT_USING_BLK
depends on RT_USING_DMA
default n
help
Enable the ATA core so AHCI/legacy controllers can register themselves in
the driver model, allocate DMA resources, and expose block devices to the
RT-Thread block layer. Select this only on SoCs/boards that actually wire
SATA ports because it pulls in the SCSI translation layer and requires DMA
support. When disabled, no SATA disks will be enumerated.
config RT_ATA_AHCI
bool "Advanced Host Controller Interface (AHCI)"
depends on RT_USING_ATA
depends on RT_USING_SCSI
default y
help
Build the generic AHCI driver that maps HBA registers (ports, command list,
FIS receive, etc.), handles NCQ, and bridges each detected SATA device to
the RT-SCSI mid-layer so filesystems can treat them like disks. Enable it
whenever your SoC implements a standards-compliant AHCI core; disable if
you rely on a vendor-specific ATA engine.
config RT_ATA_AHCI_PCI
bool "AHCI support on PCI bus"
depends on RT_ATA_AHCI
depends on RT_USING_PCI
default n
help
Allow the AHCI driver to bind to PCI devices and fetch resources via PCI
config space. Required on PC-class hardware where the AHCI HBA is behind
PCI/PCIe; boards with platform AHCI (non-PCI) can leave this off to save a
little code.
if RT_USING_ATA
osource "$(SOC_DM_ATA_DIR)/Kconfig"

View File

@@ -1,18 +1,37 @@
config RT_USING_AUDIO
bool "Using Audio device drivers"
default n
help
Enable the RT-Thread audio framework so playback/record devices may be
registered, DMA pipes allocated, and ALSA-like controls exposed via
`rt_audio_*` APIs. Choose this whenever your board has I2S/TDM codecs or
PDM microphones; disable it on MCU builds that do not process audio data.
if RT_USING_AUDIO
config RT_AUDIO_REPLAY_MP_BLOCK_SIZE
int "Replay memory pool block size"
default 4096
help
Size in bytes for each block inside the replay memory pool used by
`dev_audio.c` to stage PCM data before pushing it to DMA. Larger
values increase latency but reduce IRQ pressure; shrink it when
RAM is tight and the codec tolerates smaller bursts.
config RT_AUDIO_REPLAY_MP_BLOCK_COUNT
int "Replay memory pool block count"
default 2
help
Number of replay memory pool blocks. Raising this allows more
outstanding audio buffers (useful for long DMA transfers) but
consumes additional RAM = `BLOCK_SIZE * COUNT`.
config RT_AUDIO_RECORD_PIPE_SIZE
int "Record pipe size"
default 2048
help
Size of the ring buffer used to capture samples before user-space
reads them. Increase this to prevent overflow when the recorder
callback runs slower than the DMA completion interrupt; reduce it
on memory constrained platforms.
endif

View File

@@ -2,4 +2,8 @@ if RT_USING_AUDIO
config RT_UTEST_USING_AUDIO_DRIVER
bool "Audio Test"
default n
endif
help
Build the audio driver utest cases which stream synthetic data through
the replay/record paths. Enable only when running the RT-Thread unit
test suite; it adds test hooks that are not required in production.
endif

View File

@@ -1,6 +1,11 @@
menuconfig RT_USING_BLK
bool "Using Block device drivers"
default n
help
Enable the generic block-device infrastructure so storage controllers can
register disks/partitions and the RT-Thread DFS layer can mount them.
Almost every filesystem, SDIO, SATA or NAND driver depends on this. Turn
it off only on firmware builds that never interact with block media.
if RT_USING_BLK
rsource "partitions/Kconfig"

View File

@@ -4,9 +4,20 @@ config RT_BLK_PARTITION_DFS
bool "DFS Partition support"
depends on RT_USING_DFS
default y
help
Parse the RT-Thread DFS partition table (vfs_part) so a single block
device can be split into multiple named logical volumes. Enable this when
you use the DFS tooling or `mkpart` scripts to carve flash storage; it is
harmless to keep on because it only activates when the table signature is
present.
config RT_BLK_PARTITION_EFI
bool "EFI Globally Unique Identifier (GUID) Partition support"
default y
help
Add GUID Partition Table (GPT) support, allowing disks formatted on
modern PCs to be recognized. Required for SATA/NVMe/USB disks that use
GPT; you may disable it on very small targets that only boot from DFS
partitions to save a few kilobytes.
endmenu

View File

@@ -3,6 +3,15 @@ menuconfig RT_USING_CLK
depends on RT_USING_DM
select RT_USING_ADT_REF
default y
help
Enable the common clock framework so SoC clock providers can register
themselves and consumers can obtain `struct rt_clk` handles to manage
gate, mux and divider trees. This is required by most complex drivers
(MMC, Ethernet, display) because they explicitly prepare and enable their
input clocks before accessing hardware. The framework relies on the DM
bus and device tree clock references, so disable it only on the smallest
MCUs where every peripheral runs off the same fixed clock and no driver
ever calls into the clock API.
if RT_USING_CLK
osource "$(SOC_DM_CLK_DIR)/Kconfig"

View File

@@ -1,3 +1,7 @@
config RT_UTEST_DRIVERS_CORE
bool "Drivers Core Test"
default n
help
Build the unit tests that exercise the driver-core (device model) APIs,
ensuring registration/probing flows behave as expected. Enable only when
running the RT-Thread utest suite; production images should leave it off.

View File

@@ -4,6 +4,13 @@ menuconfig RT_USING_DMA
select RT_USING_ADT
select RT_USING_ADT_BITMAP
default n
help
Enable the DMA framework so DM-aware SoC drivers can request DMA channels,
submit descriptors, and share controller instances that are described in
the device tree. This pulls in the generic DMA core (`dma.c`) and the pool
allocator used by slave/peripheral clients. Select it whenever your board
has DMA-capable peripherals (MMC, SPI, audio, etc.) that need offloading;
leave it disabled only on targets without DMA hardware to save code size.
if RT_USING_DMA
osource "$(SOC_DM_DMA_DIR)/Kconfig"

View File

@@ -1,3 +1,8 @@
config RT_USING_LCD
bool "Using LCD graphic drivers"
default n
help
Enable the RT-Thread LCD/graphics driver framework so display controllers
can expose framebuffers or panel pipelines. This pulls in the drawing
helpers used by GUI packages; select it whenever your board has an LCD or
RGB/MIPI panel. Disable it on headless builds to save code size.

View File

@@ -1,165 +1,272 @@
menuconfig RT_USING_HWCRYPTO
bool "Using Hardware Crypto drivers"
default n
help
Enable the hardware crypto abstraction layer so SoC accelerators can
register cipher/hash/RNG engines and high-level components can route
requests through them. Select this when your platform provides AES,
HASH, RNG or big-number engines and you want to offload work from the
CPU; disable it to keep the image lean on chips without crypto IP.
if RT_USING_HWCRYPTO
config RT_HWCRYPTO_DEFAULT_NAME
string "Hardware crypto device name"
default "hwcryto"
help
Default device name announced via `rt_hwcrypto_dev_register`. You
may override it if multiple accelerators coexist or you need a
deterministic node name for auto-binding.
config RT_HWCRYPTO_IV_MAX_SIZE
int "IV max size"
default "16"
help
Maximum initialization-vector length (bytes) allocated in the
generic session context. Set this to match the longest IV your
hardware supports (for example 16 for AES) to avoid truncation.
config RT_HWCRYPTO_KEYBIT_MAX_SIZE
int "Key max bit length"
default 256
help
Upper bound on key size (bits) that the framework will accept.
Increase this if your accelerator supports longer RSA/ECC keys.
config RT_HWCRYPTO_USING_GCM
bool "Using Hardware GCM"
default n
help
Advertise AES-GCM authenticated encryption support. Only enable if
the hardware can perform GHASH + counter mode internally.
config RT_HWCRYPTO_USING_AES
bool "Using Hardware AES"
default n
help
Enable AES cipher acceleration (key setup + block operations). You
should only turn this on when the SoC AES engine is initialized
elsewhere in BSP code.
if RT_HWCRYPTO_USING_AES
config RT_HWCRYPTO_USING_AES_ECB
bool "Using Hardware AES ECB mode"
default y
help
Allow AES ECB operations. Keep it on unless your hardware
lacks ECB (rare) or you want to trim dead code.
config RT_HWCRYPTO_USING_AES_CBC
bool "Using Hardware AES CBC mode"
default n
help
Enable AES CBC mode helpers when the peripheral can chain IVs.
config RT_HWCRYPTO_USING_AES_CFB
bool "Using Hardware AES CFB mode"
default n
help
Advertise AES CFB streaming cipher support if the hardware
exposes it; leave disabled otherwise.
config RT_HWCRYPTO_USING_AES_CTR
bool "Using Hardware AES CTR mode"
default n
help
Enable AES counter mode processing for peripherals that can
increment counters internally.
config RT_HWCRYPTO_USING_AES_OFB
bool "Using Hardware AES OFB mode"
default n
help
Provide AES OFB (output feedback) mode wrappers. Only useful
when the engine implements OFB directly.
endif
config RT_HWCRYPTO_USING_DES
bool "Using Hardware DES"
default n
help
Toggle hardware DES acceleration. DES is legacy; enable it only
for compatibility with existing protocols.
if RT_HWCRYPTO_USING_DES
config RT_HWCRYPTO_USING_DES_ECB
bool "Using Hardware DES ECB mode"
default y
help
Support DES ECB mode if the IP block offers it.
config RT_HWCRYPTO_USING_DES_CBC
bool "Using Hardware DES CBC mode"
default n
help
Enable DES CBC helper functions when the peripheral supports
feedback chaining.
endif
config RT_HWCRYPTO_USING_3DES
bool "Using Hardware 3DES"
default n
help
Enable triple-DES acceleration (single/dual key). Required when
interacting with older security modules.
if RT_HWCRYPTO_USING_3DES
config RT_HWCRYPTO_USING_3DES_ECB
bool "Using Hardware 3DES ECB mode"
default y
help
Provide 3DES ECB support if your IP implements it.
config RT_HWCRYPTO_USING_3DES_CBC
bool "Using Hardware 3DES CBC mode"
default n
help
Provide 3DES CBC helpers for devices that offer feedback
chaining.
endif
config RT_HWCRYPTO_USING_RC4
bool "Using Hardware RC4"
default n
help
Enable the RC4 stream cipher hooks. Only rare legacy hardware
still implements RC4; keep disabled otherwise.
config RT_HWCRYPTO_USING_MD5
bool "Using Hardware MD5"
default n
help
Register MD5 digest offload support. Use this only if the SoC
exposes a hash module with MD5 capability.
config RT_HWCRYPTO_USING_SHA1
bool "Using Hardware SHA1"
default n
help
Enable SHA-1 hashing acceleration. SHA-1 is deprecated for secure
applications but may be required for compatibility.
config RT_HWCRYPTO_USING_SHA2
bool "Using Hardware SHA2"
default n
help
Turn on SHA-2 (224/256/384/512) acceleration. Select the exact
digests below to match your IP core.
if RT_HWCRYPTO_USING_SHA2
config RT_HWCRYPTO_USING_SHA2_224
bool "Using Hardware SHA2_224 mode"
default n
help
Provide SHA-224 digest routines if hardware supports them.
config RT_HWCRYPTO_USING_SHA2_256
bool "Using Hardware SHA2_256 mode"
default y
help
Enable SHA-256, the most commonly required SHA-2 variant.
config RT_HWCRYPTO_USING_SHA2_384
bool "Using Hardware SHA2_384 mode"
default n
help
Toggle SHA-384 support when present to support TLS-style HMAC.
config RT_HWCRYPTO_USING_SHA2_512
bool "Using Hardware SHA2_512 mode"
default n
help
Expose SHA-512 digest if your accelerator implements 512-bit
compression functions.
endif
config RT_HWCRYPTO_USING_RNG
bool "Using Hardware RNG"
default n
help
Enable the true/fast random number generator interface so the RNG
peripheral can feed entropy to TLS stacks or secure boot.
config RT_HWCRYPTO_USING_CRC
bool "Using Hardware CRC"
default n
help
Expose hardware CRC units and allow selecting supported
polynomials below. Useful for communication stacks that need
high-throughput CRC calculation.
if RT_HWCRYPTO_USING_CRC
config RT_HWCRYPTO_USING_CRC_07
bool "Using Hardware CRC-8 0x07 polynomial"
default n
help
Turn on support for the CRC-8 polynomial 0x07 (ATM/SMBus).
config RT_HWCRYPTO_USING_CRC_8005
bool "Using Hardware CRC-16 0x8005 polynomial"
default n
help
Enable CRC-16/IBM polynomial acceleration.
config RT_HWCRYPTO_USING_CRC_1021
bool "Using Hardware CRC-16 0x1021 polynomial"
default n
help
Enable CRC-16/CCITT-FALSE polynomial support.
config RT_HWCRYPTO_USING_CRC_3D65
bool "Using Hardware CRC-16 0x3D65 polynomial"
default n
help
Enable CRC-16/USB polynomial (0x3D65) support.
config RT_HWCRYPTO_USING_CRC_04C11DB7
bool "Using Hardware CRC-32 0x04C11DB7 polynomial"
default n
help
Enable CRC-32/IEEE polynomial support for Ethernet-like CRCs.
endif
config RT_HWCRYPTO_USING_BIGNUM
bool "Using Hardware bignum"
default n
help
Allow hardware accelerators to handle modular exponentiation and
other big-number math (RSA, DH, ECC). Enable when your SoC
includes a crypto accelerator with public-key instructions.
if RT_HWCRYPTO_USING_BIGNUM
config RT_HWCRYPTO_USING_BIGNUM_EXPTMOD
bool "Using Hardware bignum expt_mod operation"
default y
help
Provide modular exponentiation support (RSA decrypt/sign).
config RT_HWCRYPTO_USING_BIGNUM_MULMOD
bool "Using Hardware bignum mul_mod operation"
default y
help
Enable modular multiplication for ECC/DH operations.
config RT_HWCRYPTO_USING_BIGNUM_MUL
bool "Using Hardware bignum mul operation"
default n
help
Advertise raw big-number multiply support when hardware can do
wide integer multiplication.
config RT_HWCRYPTO_USING_BIGNUM_ADD
bool "Using Hardware bignum add operation"
default n
help
Enable big-number addition helpers when provided by silicon.
config RT_HWCRYPTO_USING_BIGNUM_SUB
bool "Using Hardware bignum sub operation"
default n
help
Expose big-number subtraction support if available.
endif
endif

View File

@@ -1,6 +1,12 @@
menuconfig RT_USING_HWTIMER
bool "Using Hardware Timer device drivers"
default n
help
Enable the generic hardware-timer framework so SoC timer blocks can
register themselves, expose capture/compare features, and provide high
resolution timing services beyond the system tick. Select this for chips
with general-purpose timers or watchdog-timer reuse; disable on systems
that only rely on the software tick.
config RT_HWTIMER_ARM_ARCH
bool "ARM ARCH Timer"
@@ -8,3 +14,8 @@ config RT_HWTIMER_ARM_ARCH
depends on RT_USING_HWTIMER
depends on ARCH_ARM_CORTEX_A || ARCH_ARMV8
default n
help
Enable the driver for the ARM architectural timer (ARMv7-A/v8 system
counter). This maps CNTFRQ/CNTV registers into the driver-model so the
kernel can expose a precise clocksource/clockevent. Only useful on Cortex-
A/R platforms that implement the generic timer block.

View File

@@ -1,20 +1,40 @@
config RT_USING_I2C
bool "Using I2C device drivers"
default n
help
Enable the RT-Thread I2C core so both DM aware controllers and legacy bus
drivers can register `struct rt_i2c_bus_device` objects, and client
drivers can issue transfers through the unified APIs. Select this on any
board that exposes an I2C peripheral or software bit-bang bus; disable it
only if you never interface with I2C sensors/PMICs/MCUs.
if RT_USING_I2C
config RT_I2C_DEBUG
bool "Use I2C debug message"
default n
help
Print verbose I2C transaction logs (start/stop, address, data) to the
console. Helpful while debugging board bring-up, but it slows down the
bus and should remain off in production firmware.
config RT_USING_I2C_BITOPS
bool "Use GPIO to simulate I2C"
default y
help
Build the generic bit-banging algorithm (`dev_i2c_bit_ops.c`) so
controller drivers or the software I2C backend can drive SCL/SDA pins
directly. Disable this only when every I2C controller is hardware-
assisted and you want to shave a few hundred bytes of code.
if RT_USING_I2C_BITOPS
config RT_I2C_BITOPS_DEBUG
bool "Use simulate I2C debug message"
default n
help
Emit timing-level diagnostics from the bit-bang implementation,
showing whether GPIO toggles are happening as expected. Useful to
diagnose board wiring or timing issues, but generates a lot of log
traffic and should stay disabled normally.
endif
menuconfig RT_USING_SOFT_I2C
@@ -22,10 +42,19 @@ if RT_USING_I2C
default n
select RT_USING_PIN
select RT_USING_I2C_BITOPS
help
Instantiate one or more fully software I2C buses backed by GPIO pins.
Each enabled bus entry below lets you choose SCL/SDA pin numbers, the
exported bus name, and bit-bang timing. Use this when the SoC lacks an
available controller but you still need to connect low-speed sensors.
if RT_USING_SOFT_I2C
menuconfig RT_USING_SOFT_I2C0
bool "Enable I2C0 Bus (software simulation)"
default y
help
Create a software I2C bus named by `RT_SOFT_I2C0_BUS_NAME`
using the selected SCL/SDA pins. Disable it if the board does
not wire up a first soft I2C channel.
if RT_USING_SOFT_I2C0
config RT_SOFT_I2C0_SCL_PIN
int "SCL pin number"
@@ -50,6 +79,10 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C1
bool "Enable I2C1 Bus (software simulation)"
default y
help
Enable the second software I2C controller and configure its
pins/name/timing below when multiple bit-bang buses are wired
out on the PCB.
if RT_USING_SOFT_I2C1
config RT_SOFT_I2C1_SCL_PIN
int "SCL pin number"
@@ -74,6 +107,10 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C2
bool "Enable I2C2 Bus (software simulation)"
default n
help
Optional third soft I2C bus for boards that expose additional
GPIO pairs. Turn this on only if you really route the
corresponding pins.
if RT_USING_SOFT_I2C2
config RT_SOFT_I2C2_SCL_PIN
int "SCL pin number"
@@ -98,6 +135,8 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C3
bool "Enable I2C3 Bus (software simulation)"
default n
help
Same as above but for the fourth software I2C instance.
if RT_USING_SOFT_I2C3
config RT_SOFT_I2C3_SCL_PIN
int "SCL pin number"
@@ -122,6 +161,9 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C4
bool "Enable I2C4 Bus (software simulation)"
default n
help
Enable the fifth configurable bit-bang bus if more GPIO-based
channels are required.
if RT_USING_SOFT_I2C4
config RT_SOFT_I2C4_SCL_PIN
int "SCL pin number"
@@ -146,6 +188,9 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C5
bool "Enable I2C5 Bus (software simulation)"
default n
help
Enable the sixth configurable bit-bang bus when the hardware
exposes yet another sensor connector.
if RT_USING_SOFT_I2C5
config RT_SOFT_I2C5_SCL_PIN
int "SCL pin number"
@@ -170,6 +215,9 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C6
bool "Enable I2C6 Bus (software simulation)"
default n
help
Enable the seventh software bus; use only on complex boards
because each additional bus increases code/data usage.
if RT_USING_SOFT_I2C6
config RT_SOFT_I2C6_SCL_PIN
int "SCL pin number"
@@ -194,6 +242,9 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C7
bool "Enable I2C7 Bus (software simulation)"
default n
help
Provide an eighth configurable software bus if still more GPIO
pairs are required for isolated peripherals.
if RT_USING_SOFT_I2C7
config RT_SOFT_I2C7_SCL_PIN
int "SCL pin number"
@@ -218,6 +269,10 @@ if RT_USING_I2C
menuconfig RT_USING_SOFT_I2C8
bool "Enable I2C8 Bus (software simulation)"
default n
help
Final reserved entry for a ninth soft I2C controller. Enable
it only when the design needs that many bit-bang buses; leave
disabled otherwise to save resources.
if RT_USING_SOFT_I2C8
config RT_SOFT_I2C8_SCL_PIN
int "SCL pin number"

View File

@@ -3,23 +3,41 @@ menuconfig RT_USING_DEVICE_IPC
default y
select RT_USING_MUTEX
select RT_USING_SEMAPHORE
help
Enable the device-layer IPC helpers (pipes, message queues, workqueues)
that many drivers rely on for buffering and deferred processing. Disable
only on extremely small systems that do not load drivers needing mutex or
semaphore-based IPC primitives.
if RT_USING_DEVICE_IPC
config RT_UNAMED_PIPE_NUMBER
int "The number of unamed pipe"
default 64
help
Maximum number of anonymous pipes that can be created at runtime.
Reduce this to save memory if your application uses few pipes.
config RT_USING_SYSTEM_WORKQUEUE
bool "Using system default workqueue"
default n
help
Create a global system workqueue thread so drivers can defer work out
of interrupt context without allocating their own threads.
if RT_USING_SYSTEM_WORKQUEUE
config RT_SYSTEM_WORKQUEUE_STACKSIZE
int "The stack size for system workqueue thread"
default 2048
help
Stack size in bytes for the common workqueue thread; increase when
queued jobs perform complex tasks or call into heavy subsystems.
config RT_SYSTEM_WORKQUEUE_PRIORITY
int "The priority level of system workqueue thread"
default 23
help
Scheduler priority assigned to the workqueue thread. Lower numbers
mean higher priority; adjust relative to other timing-sensitive
threads in your system.
endif
endif

View File

@@ -4,9 +4,15 @@ menu "IPC Test"
config RT_UTEST_COMPLETION
bool "IPC Completion Test"
default n
help
Build completion primitive unit tests to verify wait/notify semantics.
Enable only when running the IPC utest suite.
config RT_UTEST_WORKQUEUE
bool "IPC Workqueue Test"
default n
help
Compile the workqueue stress tests that schedule and cancel asynchronous
jobs. Useful for validating driver workqueue usage during development.
endmenu

View File

@@ -1,3 +1,7 @@
menuconfig RT_USING_KTIME
bool "Ktime: kernel time"
default n
help
Enable the ktime helpers which provide high-resolution timekeeping APIs
for drivers and subsystems that need more precision than the scheduler
tick. Disable if the platform sticks to coarse `rt_tick_get()` timing.

View File

@@ -2,6 +2,12 @@ menuconfig RT_USING_LED
bool "Using Light Emitting Diode (LED) device drivers"
depends on RT_USING_DM
default n
help
Enable the LED framework so on-board indicators described in device tree
can be registered and controlled via `rt_led_set_state()` (on/off/blink).
The core parses LED nodes, exports sysfs-like control via IPC, and lets
other subsystems (for example triggers) manipulate them. Disable it when
the hardware has no controllable LEDs.
config RT_LED_GPIO
bool "GPIO connected LEDs Support"
@@ -9,6 +15,12 @@ config RT_LED_GPIO
depends on RT_USING_PINCTRL
depends on RT_USING_OFW
default n
help
Provide the GPIO-backed LED driver that maps each `leds` device-tree node
to a pin, honours `default-state`/`default-trigger`, and optionally
applies pinctrl states per LED. Enable this for the common case where
LEDs are tied directly to GPIOs; leave disabled if LEDs are driven through
a different bus (I2C expanders, PMICs, etc.).
if RT_USING_LED
osource "$(SOC_DM_LED_DIR)/Kconfig"

View File

@@ -3,11 +3,23 @@ menuconfig RT_USING_MBOX
depends on RT_USING_DM
depends on RT_USING_OFW
default n
help
Enable the mailbox framework so multi-core SoCs or remote processors can
exchange messages via hardware mailbox/FIFO IP. The core registers mailbox
controllers described in device tree, manages channel timeouts, and
exposes asynchronous send/receive callbacks to drivers such as RPMsg or
audio DSP clients. Disable it only when the SoC lacks mailbox hardware.
config RT_MBOX_PIC
bool "RT-Thread PIC Mailbox"
depends on RT_USING_MBOX
default y
help
Build the PIC mailbox controller driver which exposes RT-Thread's
platform interrupt controller mailboxes through the common API. Select it
when the firmware runs on platforms where the PIC provides mailbox
registers (for example Sophgo SG2042); turning it off prevents those DTS
nodes from binding.
if RT_USING_MBOX
osource "$(SOC_DM_MBOX_DIR)/Kconfig"

View File

@@ -2,9 +2,18 @@ menuconfig RT_USING_MFD
bool "Using Multifunction device drivers"
depends on RT_USING_DM
default n
help
Enable the MFD framework so composite chips (PMICs, southbridges, etc.)
described in device tree can expose multiple child devices (GPIO, RTC,
regulator…) through the driver model. Required when your board uses such
multifunction ICs; disable to save code if every device is standalone.
config RT_MFD_SYSCON
bool "System Controller Register R/W"
depends on RT_USING_MFD
depends on RT_USING_OFW
default y
help
Provide the syscon helper that maps register banks described by
`syscon`/`simple-mfd` nodes and allows other drivers to read/write them.
Keep enabled on SoCs whose reset/clock/PHY drivers access syscon regions.

View File

@@ -1,37 +1,65 @@
config RT_USING_ADC
bool "Using ADC device drivers"
default n
help
Enable analog-to-digital converter framework support so MCU ADC channels
can be exposed through the RT-Thread device interface. Required when your
application samples voltages or sensors via ADC.
config RT_USING_DAC
bool "Using DAC device drivers"
default n
help
Build the digital-to-analog converter driver layer. Enable if you need to
output analog voltages or audio waveforms through DAC peripherals.
config RT_USING_NULL
bool "Using NULL device drivers"
default n
help
Register a `/dev/null` style sink device that discards written data and
always returns EOF when read. Handy for tests or redirecting logs.
config RT_USING_ZERO
bool "Using ZERO device drivers"
default n
help
Provide a `/dev/zero` like device that returns zero-filled buffers on
reads. Useful for quick buffer initialization without touching memory.
config RT_USING_RANDOM
bool "Using RANDOM device drivers"
default n
help
Expose a `/dev/random` source backed by software entropy or hardware RNG.
Enable only when you supply a randomness provider.
config RT_USING_PWM
bool "Using PWM device drivers"
default n
help
Enable the Pulse-Width Modulation driver layer so timers configured as PWM
can control motors, LEDs, etc. Required by many BSPs with PWM outputs.
config RT_USING_PULSE_ENCODER
bool "Using PULSE ENCODER device drivers"
default n
help
Build the pulse encoder (quadrature decoder) driver so incremental
encoders can be read through the RT-Thread device API.
config RT_USING_INPUT_CAPTURE
bool "Using INPUT CAPTURE device drivers"
default n
help
Enable input capture support, letting timers timestamp external pulses for
frequency/period measurements.
if RT_USING_INPUT_CAPTURE
config RT_INPUT_CAPTURE_RB_SIZE
int "Set input capture ringbuffer size"
default 100
help
Number of samples buffered per capture channel. Increase to avoid data
loss when interrupts arrive faster than the consumer drains them.
endif

View File

@@ -1,13 +1,23 @@
config RT_USING_MTD_NOR
bool "Using MTD Nor Flash device drivers"
default n
help
Enable the Memory Technology Device (MTD) NOR layer so SPI/QSPI or
parallel NOR flashes can be registered and exposed to the filesystem or
FAL. Select this when your design stores code/data in NOR.
config RT_USING_MTD_NAND
bool "Using MTD Nand Flash device drivers"
default n
help
Enable NAND flash management (bad-block handling, ECC hooks, partitions).
Requires platform-specific ECC support and is needed for raw NAND storage.
if RT_USING_MTD_NAND
config RT_MTD_NAND_DEBUG
bool "Enable MTD Nand operations debug information"
default n
help
Print verbose details for each NAND read/write/erase operation to aid
bring-up. Disable in production to avoid large log output.
endif

View File

@@ -4,6 +4,11 @@ menuconfig RT_USING_NVME
depends on RT_USING_BLK
depends on RT_USING_DMA
default n
help
Enable the NVMe driver stack so PCIe-connected SSDs can be discovered,
command queues created, and block devices exported through the block
layer. Requires DMA and the driver model; disable if your platform lacks
NVMe hardware.
config RT_USING_NVME_IO_QUEUE
int "Number of I/O Command queue"
@@ -11,12 +16,19 @@ config RT_USING_NVME_IO_QUEUE
default 2 if RT_THREAD_PRIORITY_8
default 4 if RT_THREAD_PRIORITY_32
default 8 if RT_THREAD_PRIORITY_256
help
Set how many submission/completion queue pairs to create for NVMe I/O.
More queues improve parallelism on multicore systems but consume more DMA
memory and interrupts.
config RT_NVME_PCI
bool "NVME support on PCI bus"
depends on RT_USING_NVME
depends on RT_USING_PCI
default y
help
Allow the driver to bind to NVMe controllers discovered via PCI/PCIe.
Disable only for non-PCI environments (for example, custom interconnects).
if RT_USING_NVME
osource "$(SOC_DM_NVME_DIR)/Kconfig"

View File

@@ -2,12 +2,19 @@ config RT_PCI_HOST_COMMON
bool "Common PCI host controller"
depends on RT_PCI_ECAM
default y
help
Include shared helper code for PCI host controllers that follow the ECAM
(Enhanced Configuration Access Mechanism) layout. Required by most PCIe
root complexes.
config RT_PCI_HOST_GENERIC
bool "Generic PCI host controller"
depends on RT_PCI_ECAM
select RT_PCI_HOST_COMMON
default y
help
Build the minimal ECAM-based PCI host driver that can enumerate devices at
a fixed base address. Useful for QEMU/virt platforms or simple SoCs.
rsource "dw/Kconfig"

View File

@@ -3,11 +3,21 @@ config RT_PCI_DW
depends on RT_MFD_SYSCON
depends on RT_USING_DMA
default n
help
Enable support for Synopsys DesignWare PCIe controllers that appear in
many SoCs. This pulls in common init logic that handles PHY resets, ATU
windows, and DMA operations shared between host and endpoint modes.
config RT_PCI_DW_HOST
bool
depends on RT_PCI_DW
help
Build the host-mode glue so the DesignWare IP enumerates downstream PCIe
devices. Usually selected by SoC-specific configs targeting host mode.
config RT_PCI_DW_EP
bool
depends on RT_PCI_DW
help
Build the endpoint-mode glue so the DesignWare controller can act as a PCIe
endpoint exposing its own BARs to a host.

View File

@@ -1,8 +1,16 @@
config RT_USING_PHY
bool "Using ethernet phy device drivers"
default n
help
Enable the Ethernet PHY framework so MAC drivers can negotiate link state
via MII/MDIO and apply vendor-specific fixes. Required when using RMII/RGMII
external PHYs.
config RT_USING_PHY_V2
bool "Using phy device and mii bus v2"
depends on !RT_USING_PHY
default n
help
Opt into the newer PHY/MDIO stack (version 2) which redesigns the PHY bus
representation. Only enable this when migrating to the new API; it is
mutually exclusive with the legacy PHY support.

View File

@@ -1,6 +1,11 @@
menuconfig RT_USING_PIN
bool "Using Generic GPIO device drivers"
default y
help
Enable the generic GPIO/pin driver interface so BSPs can expose pin mode,
read/write, and interrupt capabilities through `rt_pin_*` APIs. Most
drivers depend on this; disable only when building extremely tiny images
with no GPIO control.
if RT_USING_PIN
osource "$(SOC_DM_PIN_DIR)/Kconfig"

View File

@@ -3,6 +3,11 @@ menuconfig RT_USING_PINCTRL
depends on RT_USING_DM
depends on RT_USING_PIN
default n
help
Enable the pinctrl framework so pin multiplexing/state tables from the
device tree can be applied to peripherals (I2C, SPI, LEDs, etc.). Needed
on SoCs where GPIOs share multiple alternate functions; disable on simple
MCUs where pins have fixed roles.
if RT_USING_PINCTRL
osource "$(SOC_DM_PINCTRL_DIR)/Kconfig"

View File

@@ -1,39 +1,64 @@
config RT_USING_PM
bool "Using Power Management device drivers"
default n
help
Enable the system-level power management framework which coordinates
suspend/resume, tickless idle, and device low-power states. Required when
implementing sleep modes beyond simple tick suppression.
if RT_USING_PM
config PM_TICKLESS_THRESHOLD_TIME
int "PM tickless threashold time"
default 2
help
Minimum idle duration (in milliseconds) before the PM core enters
tickless mode. Tune based on wake-up latency vs power savings.
config PM_USING_CUSTOM_CONFIG
bool "PM using custom pm config"
default n
help
Allow BSPs to provide custom PM policy hooks instead of the stock
configuration.
config PM_ENABLE_DEBUG
bool "PM Enable Debug"
default n
help
Print suspend/resume decisions and timing for debugging purposes.
config PM_ENABLE_SUSPEND_SLEEP_MODE
bool "PM Device suspend change sleep mode"
default n
help
Permit PM to change system sleep mode dynamically when devices
suspend; requires board support.
config PM_ENABLE_THRESHOLD_SLEEP_MODE
bool "PM using threshold time change sleep mode"
default n
help
Automatically select light/deep/standby sleep based on idle time
thresholds configured below.
if PM_ENABLE_THRESHOLD_SLEEP_MODE
config PM_LIGHT_THRESHOLD_TIME
int "PM light mode threashold time"
default 5
help
Idle time in milliseconds required before entering light sleep.
config PM_DEEP_THRESHOLD_TIME
int "PM deep mode threashold time"
default 20
help
Idle duration required before requesting deep sleep.
config PM_STANDBY_THRESHOLD_TIME
int "PM standby mode threashold time"
default 100
help
Idle time before transitioning into standby (longest latency)
mode. Increase if standby exit is expensive.
endif
endif

View File

@@ -4,6 +4,15 @@ menuconfig RT_USING_REGULATOR
select RT_USING_ADT_REF
depends on RT_USING_DM
default n
help
Enable the regulator framework so power supplies described in the device
tree can be registered, referenced, and controlled at runtime. With this
selected, drivers may obtain regulators via `rt_regulator_get()`, request
enable/disable, or vote for specific voltage/current levels before their
peripherals start. The framework depends on the driver-model and ADT
parser because it walks the same device tree phandles. Disable it only
when the SoC has no controllable supplies and every peripheral is powered
permanently.
config RT_REGULATOR_FIXED
bool "Fixed regulator support"
@@ -11,12 +20,29 @@ config RT_REGULATOR_FIXED
depends on RT_USING_PIN
depends on RT_USING_PINCTRL
default y
help
Provide the "fixed" regulator type in which the output voltage is defined
entirely by the hardware (for example a PMIC LDO) and RT-Thread can only
toggle an optional GPIO enable pin. The driver parses standard device tree
properties such as `startup-delay-us`, `off-on-delay-us`, `enable-active-
high`, and also applies any pinctrl state before asserting the output.
Select this when the board DTS contains `regulator-fixed` nodes; it is
safe to leave enabled because it only instantiates devices that the DT
describes.
config RT_REGULATOR_GPIO
bool "GPIO regulator support"
depends on RT_USING_REGULATOR
depends on RT_USING_PIN
default y
help
Allow the framework to emulate simple DAC-like regulators using GPIO banks
where each output bit selects a discrete voltage/current point. The
driver reads the `states` table from the device tree and programs the GPIO
pins accordingly, so peripheral drivers can call `set_voltage()` and let
the framework choose the closest valid entry. Enable this when your board
uses GPIO strapping to select regulator levels (common with analog muxes)
or PMIC power modes; otherwise it adds no runtime cost.
if RT_USING_REGULATOR
osource "$(SOC_DM_REGULATOR_DIR)/Kconfig"

View File

@@ -3,11 +3,27 @@ menuconfig RT_USING_RESET
depends on RT_USING_DM
depends on RT_USING_OFW
default n
help
Turn on the reset-controller framework that lets platform drivers acquire
reset lines by phandle, assert/deassert them, and request pulse sequences.
This mirrors the Linux-style reset subsystem and requires both the device
model and flattened device tree parser because controllers and consumers
are linked by DT properties. Enable it whenever your SoC has shareable
reset gates (RCC, PRCM, etc.) described in DTS; otherwise peripheral
drivers such as DMA or watchdog blocks cannot safely leave reset.
config RT_RESET_SIMPLE
bool "Simple Reset Controller Driver"
depends on RT_USING_RESET
default n
help
Build the generic MMIO reset controller that toggles bits inside one or
more memory-mapped registers. The driver supports active-high/-low lines,
exposes optional delay-based `reset()` callbacks, and covers many SoC
reset managers listed in its compatible table (STM32 RCC, Allwinner,
Synopsys DW, Sophgo SG2042, etc.). Select this when your DTS describes
a `reset-simple`-compatible node or when downstream controllers reuse the
same register layout; leave it disabled if you rely on a custom reset IP.
if RT_USING_RESET
osource "$(SOC_DM_RESET_DIR)/Kconfig"

View File

@@ -1,32 +1,77 @@
config RT_USING_RTC
bool "Using RTC device drivers"
default n
help
Enable the RTC core so hardware real-time clocks can be registered via
`rt_hw_rtc_register`, the kernel can keep wall clock time across suspend/
resume, and applications can query or set calendar values through the
`rtc` character device. Turn this on whenever you have a peripheral or
PMIC that supplies timestamp/backup registers referenced from the device
tree; disable it only on chips that genuinely lack RTC hardware.
if RT_USING_RTC
config RT_USING_ALARM
bool "Using RTC alarm"
default n
help
Spawn the alarm service defined in `dev_alarm.c`. The driver
creates an RT-Thread worker thread that reconciles user-space
alarms with the RTC wakeup registers, automatically reprograms
oneshot/periodic alarms, and raises callbacks when the hardware
interrupt fires. Enable this if your application needs wakeup at a
given date/time; leave it disabled to save RAM/CPU when alarms are
not used.
if RT_USING_ALARM
config RT_ALARM_STACK_SIZE
int "stack size for alarm thread"
default 2048
help
Specify the stack size (bytes) used by the internal alarm
management thread. Increase this when alarm callbacks perform
complex logic or use libc time conversions; shrink it on very
constrained MCUs when you are sure the callbacks stay shallow.
config RT_ALARM_TIMESLICE
int "timeslice for alarm thread"
default 5
help
Define the timeslice (OS ticks) granted to the alarm thread
when it runs at the same priority as other time-sensitive
tasks. Lower values make the system more responsive at the
cost of additional context switches; higher values slightly
delay alarm handling under load.
config RT_ALARM_PRIORITY
int "priority for alarm thread"
default 10
help
RT-Thread priority (smaller numbers are higher priority) of
the alarm management thread. Choose a priority above most
application threads if you require deterministic wakeups, or
below CPU-intensive tasks when alarm latency is less critical.
config RT_ALARM_USING_LOCAL_TIME
bool "Using local time for the alarm calculation"
default n
depends on RT_USING_ALARM
help
Make the alarm service convert timestamps with `mktime()` so
alarms follow the configured local time zone instead of UTC.
Enable this when alarms must honor daylight saving or custom
offsets; otherwise keep it disabled to avoid the overhead of
repeatedly converting between UTC and local time.
endif
config RT_USING_SOFT_RTC
bool "Using software simulation RTC device"
default n
help
Build the tick-based software RTC implementation (`dev_soft_rtc`)
for boards without dedicated RTC hardware. The driver keeps time
by accumulating system ticks and stores values in RAM only, so it
resets to the compile-time default after power loss. Enable it for
simulations or low-cost MCUs that still need an `rtc` device node;
disable it when real RTC registers are available to avoid two
competing time sources.
endif

View File

@@ -2,18 +2,28 @@ menuconfig RT_USING_SCSI
bool "Using Small Computer System Interface (SCSI)"
depends on RT_USING_DM
default n
help
Enable the SCSI mid-layer which translates block requests to SCSI command
packets. Needed by AHCI, USB Mass Storage, and NVMe drivers that expose
disks as SCSI devices.
config RT_SCSI_SD
bool "SD device on SCSI"
depends on RT_USING_SCSI
depends on RT_USING_BLK
default y
help
Register disk-type SCSI devices (direct-access). Keep enabled unless you
intentionally drop support for SCSI disks.
config RT_SCSI_CDROM
bool "CD-ROM device on SCSI"
depends on RT_USING_SCSI
depends on RT_USING_BLK
default y
help
Provide SCSI CD-ROM device emulation (read-only block devices). Disable
only if optical-style devices are never needed.
if RT_USING_SCSI
osource "$(SOC_DM_SCSI_DIR)/Kconfig"

View File

@@ -2,31 +2,52 @@ config RT_USING_SDIO
bool "Using SD/MMC device drivers"
select RT_USING_BLK
default n
help
Enable the SDIO/MMC host stack so SD cards and eMMC devices can be
enumerated and exposed as block devices. Requires the block layer and an
SDIO host controller driver.
if RT_USING_SDIO
config RT_SDIO_STACK_SIZE
int "The stack size for sdio irq thread"
default 512
help
Stack size for the SDIO interrupt handler thread; increase if your
controller driver performs complex processing in IRQ context.
config RT_SDIO_THREAD_PRIORITY
int "The priority level value of sdio irq thread"
default 15
help
Scheduler priority assigned to the SDIO IRQ thread.
config RT_MMCSD_STACK_SIZE
int "The stack size for mmcsd thread"
default 1024
help
Stack size for the mmc/sd management thread that handles requests.
config RT_MMCSD_THREAD_PRIORITY
int "The priority level value of mmcsd thread"
default 22
help
Priority for the mmc/sd management thread; tune relative to other
storage tasks.
config RT_MMCSD_MAX_PARTITION
int "mmcsd max partition"
default 16
help
Maximum number of partitions to scan on an SD/MMC device.
config RT_SDIO_DEBUG
bool "Enable SDIO debug log output"
default n
help
Print verbose SDIO/MMC driver logs for debugging.
config RT_USING_SDHCI
bool "Using sdhci for sd/mmc drivers"
default n
help
Build the SD Host Controller Interface (SDHCI) compatible driver.
Enable when your controller follows the SDHCI specification.
endif

View File

@@ -2,14 +2,24 @@ config RT_USING_SENSOR
bool "Using Sensor device drivers"
select RT_USING_PIN
default n
help
Enable the sensor framework so accelerometers, gyros, temperature sensors,
etc. can register unified data channels. Depends on GPIO for interrupt
pins. Disable if no sensors are present.
if RT_USING_SENSOR
config RT_USING_SENSOR_V2
bool "Enable Sensor Framework v2"
default n
help
Opt in to the redesigned sensor framework (v2) that updates the device
APIs and CLI tools. Only enable if your BSP/drivers support it.
config RT_USING_SENSOR_CMD
bool "Using Sensor cmd"
select RT_KLIBC_USING_VSNPRINTF_STANDARD if RT_USING_SENSOR_V2
default y
help
Build the shell command helpers for listing and testing sensors. Useful
during bring-up; disable to save a bit of code.
endif

View File

@@ -3,6 +3,9 @@ menuconfig RT_USING_SERIAL
select RT_USING_DEVICE_IPC
select RT_USING_DEVICE
default y
help
Enable the UART/USART driver framework that backs the console and TTY
devices. Required for shell access or any serial communications.
if RT_USING_SERIAL
choice RT_USING_SERIAL_VERSION
@@ -12,6 +15,10 @@ menuconfig RT_USING_SERIAL
bool "RT_USING_SERIAL_V1"
config RT_USING_SERIAL_V2
bool "RT_USING_SERIAL_V2"
help
Select between the legacy serial core (V1) and the newer buffer/ISR
design (V2). Choose V2 for advanced buffer strategies, otherwise stay
with V1 for compatibility.
endchoice
choice RT_USING_SERIAL_MODE
@@ -22,17 +29,28 @@ menuconfig RT_USING_SERIAL
bool "drop new incoming data when the buffer is full"
config RT_SERIAL_BUF_STRATEGY_OVERWRITE
bool "overwrite old data when the buffer is full"
help
Define how V2 RX buffers behave on overflow: drop new bytes or
overwrite oldest data.
endchoice
config RT_SERIAL_USING_DMA
bool "Enable serial DMA mode"
default y
help
Allow serial drivers to use DMA for RX/TX to reduce CPU load. Turn
off if your SoC lacks UART DMA support.
config RT_SERIAL_RB_BUFSZ
int "Set RX buffer size"
depends on !RT_USING_SERIAL_V2
default 64
help
Size of the legacy (V1) receive ring buffer in bytes.
config RT_USING_SERIAL_BYPASS
bool "Using serial bypass"
default n
help
Enable bypass mode that forwards data between two serial devices,
useful for debugging or bridging.
endif

View File

@@ -4,33 +4,47 @@ menu "Serial Test"
bool "Serial Bypass Test"
default n
depends on RT_USING_SERIAL_BYPASS
help
Run tests validating the serial bypass feature.
config RT_UTEST_SERIAL_V2
bool "Serial V2 Test"
default n
depends on RT_USING_SERIAL_V2
help
Build testcases covering the Serial V2 core (buffer strategies, DMA).
if RT_UTEST_SERIAL_V2
config RT_SERIAL_TC_DEVICE_NAME
string "Device Name for Serial Test"
default "uart2"
help
UART device name used by the V2 testcases.
config RT_SERIAL_TC_RXBUF_SIZE
int "RX Buffer Size for Serial Test"
default 128
help
Receive buffer size used during V2 tests.
config RT_SERIAL_TC_TXBUF_SIZE
int "TX Buffer Size for Serial Test"
default 128
help
Transmit buffer size used during tests.
config RT_SERIAL_TC_SEND_ITERATIONS
int "Number of Iterations for Test Routines"
default 100
help
How many times each test loop runs; raise for stress testing.
config RT_UTEST_SERIAL_QEMU
bool "QEMU Dedicated Test"
default n
help
Enable extra scenarios tailored for QEMU environments.
config RT_UTEST_SERIAL_POSIX
bool "Serial POSIX Test"
@@ -38,19 +52,25 @@ menu "Serial Test"
select RT_USING_DFS
select RT_USING_POSIX_FS
select RT_USING_POSIX_TERMIOS
help
Include POSIX-style serial tests that rely on DFS and termios.
if RT_UTEST_SERIAL_POSIX
config RT_SERIAL_POSIX_TC_DEVICE_NAME
string "Device Name for Serial POSIX Test"
default "dev/uart2"
help
Path used by the POSIX testcases to open the serial device.
config RT_SERIAL_POSIX_TC_SEND_ITERATIONS
int "Number of Iterations for POSIX Test Routines"
default 100
help
Iteration count for the POSIX test loops.
endif
endif
endmenu
endmenu

View File

@@ -4,5 +4,7 @@ config RT_UTEST_SMP_CALL_FUNC
bool "SMP-Call Smoke Test"
default n
depends on RT_USING_SMP
help
Build SMP call function tests to ensure inter-core callbacks work.
endmenu

View File

@@ -1,21 +1,42 @@
menuconfig RT_USING_SPI
bool "Using SPI Bus/Device device drivers"
default n
help
Enable the SPI framework so hardware controllers and client drivers can
register SPI buses/devices through RT-Thread. This brings in the SPI core,
the DM glue, and the optional software backend. Turn it on for any board
that connects SPI flashes, sensors, RF chips, or display panels; disable
only when SPI is unused to save footprint.
if RT_USING_SPI
menuconfig RT_USING_SPI_ISR
bool "Enable interrupt-safe SPI operations (using spinlocks in ISR context)"
default y
help
Allow SPI APIs to be invoked from interrupt context by guarding
transfer state with spinlocks instead of mutexes. Enable it when
DMA completion or GPIO IRQ handlers need to queue SPI work; leave
it off if every transfer happens in thread context to slightly
reduce locking overhead.
menuconfig RT_USING_SOFT_SPI
bool "Use GPIO to simulate SPI"
default n
select RT_USING_PIN
help
Build software (bit-banged) SPI masters that toggle GPIO pins in
software. Each bus selected below lets you pick SCK/MISO/MOSI pins
and an exported bus name, ideal for simple sensors or when all
hardware SPI controllers are in use.
if RT_USING_SOFT_SPI
menuconfig RT_USING_SOFT_SPI0
bool "Enable SPI0 Bus (software simulation)"
default y
help
Instantiate the first software SPI bus using the pins
configured below. Disable it if your board does not need a
bit-banged SPI0 instance.
if RT_USING_SOFT_SPI0
config RT_SOFT_SPI0_SCK_PIN
int "SCK pin number"
@@ -40,6 +61,9 @@ menuconfig RT_USING_SPI
menuconfig RT_USING_SOFT_SPI1
bool "Enable SPI1 Bus (software simulation)"
default y
help
Enable a second software SPI channel for additional
low-speed peripherals when dedicated controllers run out.
if RT_USING_SOFT_SPI1
config RT_SOFT_SPI1_SCK_PIN
int "SCK pin number"
@@ -64,6 +88,9 @@ menuconfig RT_USING_SPI
menuconfig RT_USING_SOFT_SPI2
bool "Enable SPI2 Bus (software simulation)"
default n
help
Optional third soft SPI bus. Only enable when the PCB
routes the corresponding GPIO pins.
if RT_USING_SOFT_SPI2
config RT_SOFT_SPI2_SCK_PIN
int "SCK pin number"
@@ -88,6 +115,9 @@ menuconfig RT_USING_SPI
menuconfig RT_USING_SOFT_SPI3
bool "Enable SPI3 Bus (software simulation)"
default n
help
Fourth bit-banged SPI bus entry. Leave disabled to save
resources if not wired.
if RT_USING_SOFT_SPI3
config RT_SOFT_SPI3_SCK_PIN
int "SCK pin number"
@@ -112,6 +142,9 @@ menuconfig RT_USING_SPI
menuconfig RT_USING_SOFT_SPI4
bool "Enable SPI4 Bus (software simulation)"
default n
help
Provide a fifth software SPI bus; adds static data for the
pin descriptors even when unused.
if RT_USING_SOFT_SPI4
config RT_SOFT_SPI4_SCK_PIN
int "SCK pin number"
@@ -136,6 +169,9 @@ menuconfig RT_USING_SPI
menuconfig RT_USING_SOFT_SPI5
bool "Enable SPI5 Bus (software simulation)"
default n
help
Optional sixth software bus for complex designs with many
discrete chips.
if RT_USING_SOFT_SPI5
config RT_SOFT_SPI5_SCK_PIN
int "SCK pin number"
@@ -160,6 +196,9 @@ menuconfig RT_USING_SPI
menuconfig RT_USING_SOFT_SPI6
bool "Enable SPI6 Bus (software simulation)"
default n
help
Enable a seventh software SPI controller if more GPIO-only
buses are necessary.
if RT_USING_SOFT_SPI6
config RT_SOFT_SPI6_SCK_PIN
int "SCK pin number"
@@ -187,57 +226,99 @@ menuconfig RT_USING_SPI
bool "Use simulate SPI debug message"
depends on RT_USING_SOFT_SPI
default n
help
Print the edge-level toggling performed by the software SPI
backend. Useful when verifying custom wiring, but it slows down
transfers considerably.
config RT_USING_QSPI
bool "Enable QSPI mode"
default n
help
Adds Quad-SPI support to the SPI core so flash drivers can switch
MISO/MOSI pins into quad data mode and use controller-specific
QSPI ops. Enable this when your SoC exposes a QSPI controller or
you plan to run SFUD in quad mode.
config RT_USING_SPI_MSD
bool "Using SD/TF card driver with spi"
select RT_USING_DFS
default n
help
Build the SPI-based block driver for SD/TF cards (Mass Storage
Device). Select this when your design wires SD cards to an SPI
bus instead of a dedicated SDIO host; it pulls in DFS for the
filesystem layer.
config RT_USING_SFUD
bool "Using Serial Flash Universal Driver"
default n
help
An using JEDEC's SFDP standard serial (SPI) flash universal driver library
Pull in the Serial Flash Universal Driver which speaks the JEDEC
SFDP standard, auto-detects parameters, and exposes SPI NOR chips
through the RT-Thread MTD interface. Enable this for off-chip SPI
NOR/QSPI flash storage; disable it if you rely on SoC-specific
flash drivers instead.
if RT_USING_SFUD
config RT_SFUD_USING_SFDP
bool "Using auto probe flash JEDEC SFDP parameter"
default y
help
Parse the flash SFDP tables at runtime for sizing, erase
commands, and quad support. Disable only if your flash lacks
SFDP and you prefer hard-coded settings.
config RT_SFUD_USING_FLASH_INFO_TABLE
bool "Using defined supported flash chip information table"
default y
help
Keep the built-in flash info table so chips without valid SFDP
headers can still be recognized. You can turn it off to reduce
the binary when you know SFDP probing always succeeds.
config RT_SFUD_USING_QSPI
bool "Using QSPI mode support"
select RT_USING_QSPI
default n
help
Allow SFUD to drive flashes via Quad-SPI instructions. Requires
a QSPI-capable controller and board routing.
config RT_SFUD_SPI_MAX_HZ
int "Default spi maximum speed(HZ)"
range 0 50000000
default 50000000
help
Read the JEDEC SFDP command must run at 50 MHz or less,and you also can use rt_spi_configure(); to config spi speed.
int "Default spi maximum speed(HZ)"
range 0 50000000
default 50000000
help
Default maximum bus frequency SFUD will request when
probing flashes. Keep it at or below 50 MHz for SFDP per
the JEDEC spec; runtime drivers may still lower it with
`rt_spi_configure()`.
config RT_DEBUG_SFUD
bool "Show more SFUD debug information"
default n
help
Verbosely log SFUD operations (probe, erase, write). Enable
when bringing up new flash parts; keep disabled in production.
endif
config RT_USING_ENC28J60
bool "Using ENC28J60 SPI Ethernet network interface"
select RT_USING_LWIP
default n
help
Build the ENC28J60 Ethernet driver which talks to Microchip's SPI
MAC+PHY and registers a netif on top of lwIP. Enable it when your
board uses the ENC28J60; otherwise it adds dead code.
config RT_USING_SPI_WIFI
bool "Using RW009/007 SPI Wi-Fi wireless interface"
select RT_USING_LWIP
default n
help
Include the RW009/RW007 Wi-Fi driver that exchanges frames via
SPI. Requires lwIP and a matching module connected to the bus.
endif
if RT_USING_DM && RT_USING_SPI

View File

@@ -2,6 +2,10 @@ menuconfig RT_USING_THERMAL
bool "Using Thermal Management device drivers"
depends on RT_USING_DM
default n
help
Enable the thermal framework which registers sensors/cooling devices and
lets policies throttle clocks, fans, or regulators. Required on SoCs that
monitor die temperature.
if RT_USING_THERMAL
comment "Thermal Sensors Drivers"
@@ -22,6 +26,9 @@ config RT_THERMAL_COOL_PWM_FAN
depends on RT_USING_REGULATOR
depends on RT_USING_OFW
default n
help
Build the cooling device that drives fans via PWM and regulator APIs based
on thermal policy requests.
if RT_USING_THERMAL
osource "$(SOC_DM_THERMAL_COOL_DIR)/Kconfig"

View File

@@ -1,8 +1,14 @@
config RT_USING_TOUCH
bool "Using Touch device drivers"
default n
help
Enable the touchscreen input framework so controllers (capacitive,
resistive, I2C, SPI) can register coordinate events.
if RT_USING_TOUCH
config RT_TOUCH_PIN_IRQ
bool "touch irq use pin irq"
default n
help
Use GPIO pin interrupts for touch controllers that can signal via an
external interrupt line instead of polling.
endif

View File

@@ -1 +1,8 @@
menu "USB Drivers"
help
Select USB host/device controller stacks. CherryUSB provides both device
and host implementations used by RT-Thread.
rsource "cherryusb/Kconfig.rtt"
endmenu

View File

@@ -1,6 +1,9 @@
menuconfig RT_USING_VIRTIO
bool "Using VirtIO device drivers"
default n
help
Enable VirtIO front-end drivers for virtualized environments (QEMU,
cloud). Requires a hypervisor exposing VirtIO MMIO or PCI devices.
if RT_USING_VIRTIO
choice RT_USING_VIRTIO_VERSION
@@ -9,35 +12,54 @@ menuconfig RT_USING_VIRTIO
config RT_USING_VIRTIO10
bool "VirtIO v1.0"
help
Use the modern VirtIO 1.0 device layout with feature bits in
the standard registers.
endchoice
config RT_USING_VIRTIO_MMIO_ALIGN
bool "Using VirtIO MMIO alignment"
default y
help
Enforce strict MMIO alignment handling required by some hosts.
config RT_USING_VIRTIO_BLK
bool "Using VirtIO BLK"
default y
help
Build the VirtIO block driver to expose virtual disks as RT-Thread
block devices.
config RT_USING_VIRTIO_NET
bool "Using VirtIO NET"
default y
help
Build the VirtIO network driver to connect to the hypervisor's
virtual NIC.
menuconfig RT_USING_VIRTIO_CONSOLE
bool "Using VirtIO Console"
default y
help
Enable the VirtIO console port driver for serial I/O via hypervisor.
if RT_USING_VIRTIO_CONSOLE
config RT_USING_VIRTIO_CONSOLE_PORT_MAX_NR
int "Max number of port in VirtIO Console"
default 4
help
Maximum number of sub-ports exposed by the VirtIO console.
endif
config RT_USING_VIRTIO_GPU
bool "Using VirtIO GPU"
default y
help
Build the VirtIO GPU driver for virtual display support.
config RT_USING_VIRTIO_INPUT
bool "Using VirtIO Input"
default y
help
Register VirtIO input devices (keyboard, pointer) through RT-Thread.
endif

View File

@@ -1,6 +1,15 @@
menuconfig RT_USING_WDT
bool "Using Watch Dog device drivers"
default n
help
Enable the common watchdog device layer so watchdog-capable SoCs or
external supervisors can be exposed through the RT-Thread `rt_watchdog`
APIs. Selecting this option allows watchdog platform drivers to register
/dev/wdt style devices, lets applications query/set timeout windows, and
integrates watchdog notifications into the driver-model (DM) probe/remove
flow. Disable it only when the hardware has no watchdog or it is managed
entirely outside of RT-Thread, because the system will no longer be able
to arm, feed or inspect watchdogs during boot and runtime.
config RT_WDT_DW
bool "Synopsys DesignWare watchdog"
@@ -8,12 +17,31 @@ config RT_WDT_DW
depends on RT_USING_WDT
depends on RT_USING_RESET
default n
help
Build the driver for Synopsys DesignWare watchdog blocks that appear in
many ARM and RISC-V SoCs. The driver maps the DM platform resources,
exports the 16 preset timeout levels ("TOPs"), supports optional pre-
timeout interrupts, and automatically toggles the associated reset line
through `RT_USING_RESET`. Once started the DW watchdog cannot be disabled,
so the driver only gates the peripheral clock and pulses the reset
controller to keep it under control. Use this when your device tree
exposes a `snps,dw-wdt` node and you need either reset-based system
recovery or two-stage IRQ/Reset supervision; otherwise leave it off.
config RT_WDT_I6300ESB
bool "Intel 6300ESB Timer/Watchdog"
depends on RT_USING_DM
depends on RT_USING_WDT
depends on RT_USING_PCI
help
Enable support for the watchdog integrated in Intel 6300ESB southbridge
chipsets. The driver binds to the PCI device, unlocks the dual-stage timer,
and exposes the 1 kHz heartbeat window (12046 seconds) through the
standard watchdog IOCTLs. It can optionally enter "nowayout" mode when the
firmware locks the control register, so be careful when testing on shared
x86 hardware. Select this only on boards that actually contain the 6300ESB
watchdog because the driver directly touches PCI config space and assumes
the LPC reset registers are routed correctly.
if RT_USING_DM && RT_USING_WDT
osource "$(SOC_DM_WDT_DIR)/Kconfig"

View File

@@ -1,154 +1,223 @@
menuconfig RT_USING_WIFI
bool "Using Wi-Fi framework"
default n
help
Enable the RT-Thread Wi-Fi middleware which manages STA/AP interfaces,
connection profiles, protocol glue, workqueues, and debugging hooks.
if RT_USING_WIFI
config RT_WLAN_DEVICE_STA_NAME
string "The device name for station"
default "wlan0"
help
Logical device name used for the station interface.
config RT_WLAN_DEVICE_AP_NAME
string "The device name for ap"
default "wlan1"
help
Logical device name for the SoftAP interface.
config RT_WLAN_SSID_MAX_LENGTH
int "SSID maximum length"
default 32
help
Upper bound for SSID strings stored by the framework.
config RT_WLAN_PASSWORD_MAX_LENGTH
int "Password maximum length"
default 32
help
Maximum length of passphrases saved in configs.
config RT_WLAN_DEV_EVENT_NUM
int "Driver events maxcount"
default 2
help
Number of event objects reserved for notifying upper layers.
config RT_WLAN_MANAGE_ENABLE
bool "Connection management Enable"
default y
help
Turn on the connection manager (auto reconnect, scanning, CLI).
if RT_WLAN_MANAGE_ENABLE
config RT_WLAN_SCAN_WAIT_MS
int "Set scan timeout time(ms)"
default 10000
help
Timeout for synchronous scan requests in milliseconds.
config RT_WLAN_CONNECT_WAIT_MS
int "Set connect timeout time(ms)"
default 10000
help
Connection attempt timeout.
config RT_WLAN_SCAN_SORT
bool "Automatic sorting of scan results"
default y
help
Sort scan results by RSSI/channel automatically.
config RT_WLAN_MSH_CMD_ENABLE
bool "MSH command Enable"
default y
help
Add msh shell commands (`wifi`, etc.) for management.
config RT_WLAN_JOIN_SCAN_BY_MGNT
bool "Enable wlan join scan"
default y
help
Allow connection manager to trigger scans before joining.
config RT_WLAN_AUTO_CONNECT_ENABLE
bool "Auto connect Enable"
select RT_WLAN_CFG_ENABLE
select RT_WLAN_WORK_THREAD_ENABLE
default y
help
Automatically reconnect using saved profiles when link drops.
if RT_WLAN_AUTO_CONNECT_ENABLE
config AUTO_CONNECTION_PERIOD_MS
int "Auto connect period(ms)"
default 2000
help
Interval between automatic reconnect attempts.
endif
endif
config RT_WLAN_CFG_ENABLE
bool "WiFi information automatically saved Enable"
default y
help
Persist Wi-Fi credentials and settings to storage.
if RT_WLAN_CFG_ENABLE
config RT_WLAN_CFG_INFO_MAX
int "Maximum number of WiFi information automatically saved"
default 3
help
Maximum number of networks stored for auto-connect.
endif
config RT_WLAN_PROT_ENABLE
bool "Transport protocol manage Enable"
default y
help
Allow protocol modules (lwIP, etc.) to register with WLAN core.
if RT_WLAN_PROT_ENABLE
config RT_WLAN_PROT_NAME_LEN
int "Transport protocol name length"
default 8
help
Max length for protocol identifier strings.
config RT_WLAN_PROT_MAX
int "Transport protocol maxcount"
default 2
help
Number of protocol backends that can be registered.
config RT_WLAN_DEFAULT_PROT
string "Default transport protocol"
default "lwip"
help
Name of the protocol backend used when none specified.
config RT_WLAN_PROT_LWIP_ENABLE
bool "LWIP transport protocol Enable"
select RT_USING_LWIP
default y
help
Register lwIP as a transport backend for WLAN sockets.
if RT_WLAN_PROT_LWIP_ENABLE
config RT_WLAN_PROT_LWIP_NAME
string "LWIP transport protocol name"
default "lwip"
help
Name exported for the lwIP backend.
config RT_WLAN_PROT_LWIP_PBUF_FORCE
bool "Forced use of PBUF transmission"
default n
help
Force PBUF-based data path even when zero-copy is possible.
endif
endif
config RT_WLAN_WORK_THREAD_ENABLE
bool "WLAN work queue thread Enable"
default y
help
Spawn the WLAN workqueue thread that handles asynchronous tasks.
if RT_WLAN_WORK_THREAD_ENABLE
config RT_WLAN_WORKQUEUE_THREAD_NAME
string "WLAN work queue thread name"
default "wlan"
help
Name of the workqueue thread.
config RT_WLAN_WORKQUEUE_THREAD_SIZE
int "WLAN work queue thread size"
default 2048
help
Stack size in bytes for the workqueue thread.
config RT_WLAN_WORKQUEUE_THREAD_PRIO
int "WLAN work queue thread priority"
default 15
help
RT-Thread priority of the WLAN workqueue.
endif
menuconfig RT_WLAN_DEBUG
bool "Enable WLAN Debugging Options"
default n
help
Enable fine-grained debug switches for WLAN subsystems.
if RT_WLAN_DEBUG
config RT_WLAN_CMD_DEBUG
bool "Enable Debugging of wlan_cmd.c"
default n
help
Log detailed info from the command module.
config RT_WLAN_MGNT_DEBUG
bool "Enable Debugging of wlan_mgnt.c"
default n
help
Debug connection management state transitions.
config RT_WLAN_DEV_DEBUG
bool "Enable Debugging of wlan_dev.c"
default n
help
Trace driver-level operations.
config RT_WLAN_PROT_DEBUG
bool "Enable Debugging of wlan_prot.c"
default n
help
Dump protocol manager operations.
config RT_WLAN_CFG_DEBUG
bool "Enable Debugging of wlan_cfg.c"
default n
help
Trace configuration load/save.
config RT_WLAN_LWIP_DEBUG
bool "Enable Debugging of wlan_lwip.c"
default n
help
Print lwIP glue logs.
endif
endif