Hello Svyatoslav, On Thu, Feb 19, 2026 at 7:44 PM Svyatoslav Ryhel <[email protected]> wrote: > > чт, 19 лют. 2026 р. о 19:51 Dario Binacchi > <[email protected]> пише: > > > > This series adds support for the Rocktech RK050HR345-CT106A panel. > > The initialization of this panel requires a 9-bit word length > > configuration. To support this, I have extended the STM32 SPI driver > > (including support for the STM32MP25 SoC) to implement the set_wordlen > > operation. > > > > To properly validate these changes and ensure the SPI uclass correctly > > handles the word length propagation, I have also implemented the > > corresponding logic in the sandbox driver and added a dedicated unit > > test. > > > > I have grouped these patches together to provide a complete overview of > > the implementation and its verification. > > > > > > Dario Binacchi (8): > > spi: add support for bits-per-word setting > > spi: sandbox_spi: support wordlen setup > > test: spi: add sandbox_spi_get_wordlen interface > > test: dm: spi: add testcase for spi_set_wordlen() > > Hello Dario! > > You should not need to modify spi framework to support 9 bit len xfer. > dm_spi_xfer supports this already, you need only stm32 support for > non-aligned xfers.
Thank you for the feedback. I initially explored the approach you suggested. However, following the STM32 driver implementation in the Linux kernel, I found that explicitly managing the bits-per-word parameter was necessary. In the current STM32MP2 driver, the word length is effectively hardcoded to 8 bits. To address this, I needed to implement the set_wordlen ops, which is already declared among the available SPI framework ops but had not yet been implemented or used. The proof of this approach is that the driver now correctly handles multi-word 16-bit transfers of any buffer size, using 9-bit words as required. This is a significant improvement over the common implementations that often only support single 16-bit data transfers. I believe this provides the necessary flexibility that dm_spi_xfer alone couldn't achieve without a way to redefine the word boundaries. Thanks and regards, Dario > > You can refer to ssd2825 bridge as an example of 9-bit spi > communication for write and 16 bit reads. > > > spi: stm32: clean up buffer length assignment > > spi: stm32: add support for bits-per-word setting > > spi: stm32: extend support to STM32MP25 > > video: support Rocktech RK050HR345-CT106A panel > > > > arch/sandbox/include/asm/test.h | 8 + > > drivers/spi/sandbox_spi.c | 21 ++ > > drivers/spi/spi-uclass.c | 19 ++ > > drivers/spi/stm32_spi.c | 67 +++++- > > drivers/video/Kconfig | 8 + > > drivers/video/Makefile | 1 + > > drivers/video/ilitek-ili9806e.c | 354 ++++++++++++++++++++++++++++++++ > > include/spi.h | 12 ++ > > test/dm/spi.c | 16 ++ > > 9 files changed, 499 insertions(+), 7 deletions(-) > > create mode 100644 drivers/video/ilitek-ili9806e.c > > > > -- > > 2.43.0 > > > > base-commit: 7dca54ef4c44c82bdc6716ac6cdc84c22c66e9ed > > branch: RK050HR345-CT106A-ON-SPI -- Dario Binacchi Senior Embedded Linux Developer [email protected] __________________________________ Amarula Solutions SRL Via Le Canevare 30, 31100 Treviso, Veneto, IT T. +39 042 243 5310 [email protected] www.amarulasolutions.com

