Description
Issue #10636 exposed a problem that a few cases that SPI slave drivers aren't converted to DTS. Doing a grep in the tree for SPI_._NAME or SPI_DRV_NAME or spi_config we come up with:
tests/drivers/spi/spi_loopback/Kconfig: default SPI_1_NAME
We need to convert these slave drivers to use DTS.
I'm working on it. So far I found only one thing that is missing on the master side (in
drivers/bluetooth/hci/spi.c
). The CS line is not asserted in the general case, there is only some specific steering of it for BlueNRG. But it's not that trivial to get this information from DTS since this line may be (at least for Nordic SoCs it is) configured incs-gpios
property in the parent node. Configuration of other settings is already in place (through the "zephyr,bt-hci-spi" node).
On the slave side (insamples/bluetooth/hci_spi
) to get the relevant settings I will follow the way you started in galak@f30bc9e, but I think that instead of adding thespi-slave
property and setting#address-cells
to0
I will use a separate binding for "nordic,nrf-spis" node that will inherit from "spi-device". But first I need to make the hci_spi example working. Currently it is not handling correctly SPI transactions as it does not configure SPI to work in the slave mode, so the whole communication does not start. But even after I corrected this I still get some "invalid message type" errors. I need to debug it further.
Any update on this?