From 1a1d8e797bc732ae061ca86ba3da8511889bd931 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andrzej=20G=C5=82=C4=85bek?= Date: Thu, 12 Mar 2020 09:02:41 +0000 Subject: [PATCH] tests/drivers/spi/spi_loopback: Fix configurations for nRF boards MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Since commit 22326f6d99e8e710bbf7e6f9057bb96741e970f6 got in, this test requires that so-called NOP frames (bytes of value 0) are sent when no TX data is provided. For nRF SoCs, the over-read character (ORC) that is sent in such case is by default configured to the value of 0xFF. Alter configurations for nRF boards so that 0x00 is used instead. On the occasion, remove redundant selections of driver type in those configurations (CONFIG_SPI_x_NRF_SPI[M]=y), as such selections must be aligned with the value of "compatible" property in corresponding nodes in dts, so there's no much sense in having them separately here. Correct also the SPI instance to be used for nrf51_pca10028. Signed-off-by: Andrzej Głąbek --- tests/drivers/spi/spi_loopback/boards/nrf51_pca10028.conf | 6 +++--- .../drivers/spi/spi_loopback/boards/nrf52840_pca10056.conf | 2 +- tests/drivers/spi/spi_loopback/boards/nrf52_pca10040.conf | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/drivers/spi/spi_loopback/boards/nrf51_pca10028.conf b/tests/drivers/spi/spi_loopback/boards/nrf51_pca10028.conf index 23489ec73ff..6cc95a30f6e 100644 --- a/tests/drivers/spi/spi_loopback/boards/nrf51_pca10028.conf +++ b/tests/drivers/spi/spi_loopback/boards/nrf51_pca10028.conf @@ -1,7 +1,7 @@ -CONFIG_SPI_0=y -CONFIG_SPI_0_NRF_SPI=y +CONFIG_SPI_1=y +CONFIG_SPI_1_NRF_ORC=0x00 -CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_0" +CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_1" CONFIG_SPI_LOOPBACK_CS_GPIO=y CONFIG_SPI_LOOPBACK_CS_CTRL_GPIO_DRV_NAME="GPIO_0" CONFIG_SPI_LOOPBACK_CS_CTRL_GPIO_PIN=28 diff --git a/tests/drivers/spi/spi_loopback/boards/nrf52840_pca10056.conf b/tests/drivers/spi/spi_loopback/boards/nrf52840_pca10056.conf index d5d51ab8c22..d67fab0557e 100644 --- a/tests/drivers/spi/spi_loopback/boards/nrf52840_pca10056.conf +++ b/tests/drivers/spi/spi_loopback/boards/nrf52840_pca10056.conf @@ -1,6 +1,6 @@ CONFIG_SPI_NRFX_RAM_BUFFER_SIZE=8 CONFIG_SPI_3=y -CONFIG_SPI_3_NRF_SPIM=y +CONFIG_SPI_3_NRF_ORC=0x00 CONFIG_SPI_3_NRF_RX_DELAY=1 CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_3" diff --git a/tests/drivers/spi/spi_loopback/boards/nrf52_pca10040.conf b/tests/drivers/spi/spi_loopback/boards/nrf52_pca10040.conf index 8afd83eba11..6cc95a30f6e 100644 --- a/tests/drivers/spi/spi_loopback/boards/nrf52_pca10040.conf +++ b/tests/drivers/spi/spi_loopback/boards/nrf52_pca10040.conf @@ -1,5 +1,5 @@ CONFIG_SPI_1=y -CONFIG_SPI_1_NRF_SPI=y +CONFIG_SPI_1_NRF_ORC=0x00 CONFIG_SPI_LOOPBACK_DRV_NAME="SPI_1" CONFIG_SPI_LOOPBACK_CS_GPIO=y