Add a new section documenting the TIOCSERGSTRUCT debug ioctl and CONFIG_SERIAL_TIOCSERGSTRUCT Kconfig option. The section covers enabling the feature, how the ioctl copies driver-internal state to user space, example usage with the 16550 UART driver, and a warning about the non-stable nature of exposed structures.
Signed-off-by: Arjav Patel <arjav1528@gmail.com>
This commit refactors the CC1101 driver's read interface to comply with
the standard NuttX wireless character driver API and introduces extended
hardware operation modes.
- Migrate `cc1101_file_read` to accept and populate the standard
`struct wlioc_rx_hdr_s` instead of returning raw byte arrays.
- Implement `cc1101_calc_rssi_dbm_x100` to preserve the hardware's
0.5 dBm RSSI precision when scaling to 1/100 dBm units, eliminating
the integer truncation loss present in the legacy calculation.
- Add `CC1101IOC_SETOPMODE` and `CC1101IOC_GETOPMODE` IOCTLs.
- Introduce four RF operation modes (`enum cc1101_opmode_e`):
1. NORMAL: Standard packet mode with hardware filtering.
2. PROMISCUOUS: Packet mode bypassing address filtering and retaining
packets with CRC errors.
3. SYNC_SERIAL: Bypasses FIFO, routes clock and data to GDO0/GDO2.
4. ASYNC_SERIAL: Bypasses FIFO, routes async data to GDO2.
- Fix the `GS2200M_FIRST` IOCTL block offset in `wireless/ioctl.h` and
allocate a dedicated IOCTL block for CC1101.
Signed-off-by: Chip L. <chplee@gmail.com>
Fix MAC address byte order by reversing 6 bytes after reading
from eFuse. Adjust offset logic to apply after byte reversal,
ensuring Ethernet MAC is base_mac +3. Comply with Espressif's
MAC address generation specification for ESP32S3
Signed-off-by: nuttxs <zhaoqing.zhang@sony.com>
This commit adds documentation entries for ESP32-P4 chip and its
board (ESP32-P4 Function-EV-Board).
Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
This commit adds support for the Espressif's RISC-V-based ESP32-P4
chip along with its ESP32-P4-Function-EV-Board board.
Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
- Added functionality to read patch content from stdin when using the '--stdin' option with the '-p' flag.
- Updated usage instructions to clarify the new stdin option for patch checks.
- Improved error handling for unsupported combinations of options.
Signed-off-by: Arjav Patel <arjav1528@gmail.com>
- Updated the check workflow to conditionally include a '-b' option for breaking change enforcement based on PR labels.
- Modified the checkpatch script to support reading commit messages from stdin when using the '-m -g' flags.
- Improved usage instructions to clarify the new stdin option for commit message checks.
Signed-off-by: Arjav Patel <arjav1528@gmail.com>
- Introduced a new flag '-b' to enforce breaking change format in commit messages.
- Added checks to ensure that breaking change commits start with '!' and contain 'BREAKING CHANGE:' in the body before 'Signed-off-by'.
- Updated usage instructions to reflect the new breaking change option.
Signed-off-by: Arjav Patel <arjav1528@gmail.com>
Increase default TX power from 14 to 17 dBm and enable CRC
by default to improve link reliability and data integrity.
Signed-off-by: Arjav Patel <arjav1528@gmail.com>
Previously, the ST7796 driver required the board to pass a struct
st7796_config_s at initialization time, carrying display resolution,
color depth, orientation (MADCTL), BGR flag, SPI frequency, and
initial rotation.
All of these are chip-level properties, not board wiring details.
This created an awkward split: board code computed MADCTL values,
selected BPP, and derived effective resolution depending on orientation
(knowledge that belongs exclusively in the generic driver).
This commit removes that split entirely, following the same pattern used
by the ST7789 driver in drivers/lcd/Kconfig. It also implements the
getpower/setpower interface for standard framebuffer power management.
What was changed (per file):
drivers/lcd/Kconfig:
- Added a full 'if LCD_ST7796' ... 'endif # LCD_ST7796' block containing
all chip-level configuration.
- Includes LCD_ST7796_XRES/YRES, LCD_ST7796_BPP, LCD_ST7796_FREQUENCY,
LCD_ST7796_SPIMODE, LCD_ST7796_BGR, LCD_ST7796_INVCOLOR,
and orientation/rotation choices.
drivers/lcd/st7796.c:
- Removed struct st7796_config_s from struct st7796_dev_s.
- Moved struct st7796_cmd_s from public header to Private Types.
- Added compile-time macros derived from Kconfig:
ST7796_XRES/YRES (swapped for landscape),
ST7796_MADCTL_BASE,
ST7796_SPIMODE,
ST7796_BYTESPP,
ST7796_COLORFMT.
- Implemented st7796_getpower() and st7796_setpower() using the
st7796_board_power() board callback.
- Registered power functions in st7796_fbinitialize() vtable.
- Updated st7796_init_display() to make INVON/INVOFF conditional on
CONFIG_LCD_ST7796_INVCOLOR.
- Simplified st7796_fbinitialize() signature to only take
'struct spi_dev_s *spi'.
include/nuttx/lcd/st7796.h:
- Removed legacy macros (ST7796_XRES_RAW, etc.) and configuration
structures.
- Updated st7796_fbinitialize() prototype.
- Added st7796_board_power() callback prototype.
- Removed private implementation details from the public header.
boards/arm/stm32h7/nucleo-h753zi/Kconfig:
- Removed chip-level menus (settings, orientation) now handled by the
generic driver.
- Retained only board-specific wiring concerns (pins and SPI bus).
boards/.../stm32_st7796.c:
- Removed g_st7796_config and associated board-side macros.
- Updated st7796_fbinitialize() call to the new signature.
- stm32_st7796_flush_fb() now queries effective resolution
via g_fb_vtable->getvideoinfo().
Verified on nucleo-h753zi:
Orientation: Landscape (480x320),
Rotation: 180 deg,
BGR: enabled,
INVCOLOR: disabled,
BPP: RGB565,
Frequency: 40 MHz.
Making INVCOLOR a Kconfig option (default n) fixes cases where panels
previously showed inverted colors due to hardcoded INVON.
Signed-off-by: vrmay23 <vmay.sweden@gmail.com>
* Fix GPIO unspecified behavior on some GPIO ports.
* Fix GPIO undefined behavior caused by uncleared set or reset bits.
Signed-off-by: Saurav Pal <resyfer.dev@gmail.com>
Increase the INIT_STACKSIZE from 2048 to 4096 (nsh and netnsh).
Increase the SYSTEM_TELNETD_SESSION_STACKSIZE from 2048 to 4096 (netnsh).
The stack sizes are increased in order to prevent stack overflows that
were encountered in some scenarios with these defconfigs.
Signed-off-by: Michal Matias <mich4l.matias@gmail.com>
A previous commit (d2c85a9fa0)
introduced an incomplete change to upstream regarding GPIO IRQ
selection on ESP32, ESP32-S2 and ESP32-S3. NuttX's upstream CI did
not get the error because of the rules that trigger specific
pipelines based on the modified files. In this case, the xtensa
jobs did not run to properly evaluate this issue.
Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
Add definition to setup appropriate reduced SRAM sizes
CONFIG_STM32H7_STM32H72XXX_OR_STM32H73XXX.
The define should make addition of other STM32H72X
and TM32H73X chips easier.
Signed-off-by: Pavel Pisa <pisa@fel.cvut.cz>
The citests.rst now documents how to run the CI test suites locally (the
same way they are done in NuttX GitHub CI). Other pages are created for
different parts of NuttX testing.
Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
Adds a documentation page describing the process that happens to each PR
submitted to nuttx and nuttx-apps.
Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
All of the tools listed on the original documentation are now given
their own individual doc pages. This makes it much easier to
cross-reference them from other documentation locations (as many are
used in CI/for specific architectures) and it also makes it easier for
users to digest the information.
Signed-off-by: Matteo Golin <matteo.golin@gmail.com>
Update SIM configuration and CMake toolchain to resolve
linker errors when building on macOS. Adjust POSIX host
implementation to ensure successful compilation and
proper behavior of the sim target.
Modified:
- arch/sim/Kconfig
- arch/sim/src/cmake/Toolchain.cmake
- arch/sim/src/sim/posix/sim_hostmisc.c
Signed-off-by: Aditya Yadav <166515021+aditya0yadav@users.noreply.github.com>
GPIO PIN base address calculation had double right shift, thus call
to SAM_PION_BASE was always with port = 0 instead of correct port
number. As a result, function sam_gpioirq didn't correctly configure
additional interrupt modes (only rising or falling edge and level
interrupts).
The issue occured on SAMv7 and SAM34 platforms (likely copy-pasted
from one to another).
Signed-off-by: Michal Lenc <michallenc@seznam.cz>
This commit updates the common-source integration for RISC-V-based
Espressif devices (ESP32-C3, ESP32-C6, and ESP32-H2). This is part of a
larger common-source update split by architecture for better maintainability
of the already-supported devices and upcoming devices.
Major components updated:
- IRQ allocator refactoring with intr_alloc integration
- Common-source drivers (GPIO, RMT, I2C, SPI, UART, etc.)
- Espressif components upgrade to release/master.b
- Peripheral drivers (ADC, PWM, LEDC, MCPWM, PCNT, Temperature Sensor, etc.)
- Wireless adapters (Wi-Fi and BLE)
- Board defconfigs for all RISC-V Espressif boards
- Critical section handling improvements
Key architectural changes:
- IRQ Allocator: The new interrupt allocator enables multiple mapping
options from interrupt sources to CPU interrupts, providing flexibility
required by modern peripherals. Although this introduces breaking changes
to the interrupt handling API, the required ARCH_MINIMAL_VECTORTABLE
Kconfig option is explicitly checked during startup to ensure proper
configuration. This validation prevents runtime issues from configuration
mismatches.
Note: This is a large commit to maintain bisectability. Breaking the
changes into smaller commits would result in non-building intermediate
states across the common-source infrastructure update.
Tested configurations:
- All defconfigs were built and tested, inclusing `ostest`.
Signed-off-by: Tiago Medicci Serrano <tiago.medicci@espressif.com>
To be merged with RISC-V implementation
Add open-amp patch 0019 to extend fw_rsc_config with h2r_buf_addr
and r2h_buf_addr fields, allowing the host and remote sides to
specify buffer physical addresses through the resource table.
This enables splitting the shared memory pool into separate regions.
Also update open-amp.defs and open-amp.cmake to apply the new patch
during the open-amp build process.
Signed-off-by: Bowen Wang <wangbowen6@xiaomi.com>
support specify the address by h2r_buf_addr and r2h_buf_addr
so is can split shared memory pool
Signed-off-by: yintao <yintao@xiaomi.com>
Signed-off-by: Bowen Wang <wangbowen6@xiaomi.com>
Implement `cc1101_file_ioctl` to map common NuttX wireless IOCTL commands
to CC1101 hardware registers. This allows dynamic configuration of radio
parameters from user-space applications.
* Map `WLIOC_SETRADIOFREQ` and `GETRADIOFREQ` to `FREQ[2:0]`.
* Map `WLIOC_SETADDR` and `GETADDR` to `ADDR`.
* Map `WLIOC_SETTXPOWER` and `GETTXPOWER` to internal PATABLE indexing.
* Map `WLIOC_SETMODU` and `GETMODU` to `MDMCFG2`.
* Map `WLIOC_FSK_SETBITRATE` and `GETBITRATE` to `MDMCFG4` and `MDMCFG3`.
* Map `WLIOC_FSK_SETFDEV` and `GETFDEV` to `DEVIATN`.
* Normalize positive SPI status byte returns from `cc1101_access` to `OK` (0)
to ensure POSIX compliance and prevent silently skipped register writes.
Signed-off-by: Chip L. <chplee@gmail.com>
Remove the unnecessary CONFIG_RPMSG_UART_CONSOLE preprocessor guard around
the console registration logic in uart_rpmsg_init().
The uart_rpmsg_init() function already accepts a bool isconsole parameter to
dynamically control console registration, which is designed to support flexible
console setup in distributed multi-core SOC systems. Adding the macro check on
top of this runtime parameter is redundant and negates the dynamic registration
capability.
This change fixes a regression introduced by PR #18410, which broke the functionality
of sim/rpproxy and sim/rpserver due to the incorrect macro guard preventing proper
console registration for the rpmsg UART device.
Signed-off-by: chao an <anchao.archer@bytedance.com>