Skip to content

Commit 7072460

Browse files
ananglkartben
authored andcommitted
dts: bindings: spi: Fix "nordic,nrf-spis" binding
The nRF SPIS peripheral is not an SPI controller but an SPI target device, so its binding should not include "spi-controller.yaml" (and so far it did, through "nordic,nrf-spi-common.yaml"). Fix this so that it is no longer possible to incorrectly add child DT nodes as "devices" on the SPIS "bus" and then for example misuse the SPI_CONFIG_DT() macro for such constructs. Since this requires a small correction in the "overrun-character" property in "nordic,nrf-spi-common.yaml", improve also its description by adding there information from the corresponding property from "spi-controller.yaml". Signed-off-by: Andrzej Głąbek <andrzej.glabek@nordicsemi.no>
1 parent 315ff5d commit 7072460

File tree

4 files changed

+17
-4
lines changed

4 files changed

+17
-4
lines changed

dts/bindings/spi/nordic,nrf-spi-common.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33

44
# Common fields for Nordic nRF family SPI peripherals
55

6-
include: [spi-controller.yaml, pinctrl-device.yaml, nordic-clockpin.yaml]
6+
include:
7+
- pinctrl-device.yaml
8+
- nordic-clockpin.yaml
79

810
properties:
911
reg:
@@ -26,8 +28,11 @@ properties:
2628
property must be set at SoC level DTS files.
2729
2830
overrun-character:
31+
type: int
2932
default: 0xff
3033
description: |
34+
The overrun character (ORC) is used when all bytes from the TX buffer
35+
are sent, but the transfer continues due to RX.
3136
Configurable, defaults to 0xff (line high), the most common value used
3237
in SPI transfers.
3338

dts/bindings/spi/nordic,nrf-spi.yaml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,6 @@ description: Nordic nRF family SPI (SPI master)
55

66
compatible: "nordic,nrf-spi"
77

8-
include: nordic,nrf-spi-common.yaml
8+
include:
9+
- spi-controller.yaml
10+
- nordic,nrf-spi-common.yaml

dts/bindings/spi/nordic,nrf-spim.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@ description: Nordic nRF family SPIM (SPI master with EasyDMA)
55

66
compatible: "nordic,nrf-spim"
77

8-
include: ["nordic,nrf-spi-common.yaml", "memory-region.yaml"]
8+
include:
9+
- spi-controller.yaml
10+
- nordic,nrf-spi-common.yaml
11+
- memory-region.yaml
912

1013
properties:
1114
anomaly-58-workaround:

dts/bindings/spi/nordic,nrf-spis.yaml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,10 @@ description: Nordic nRF family SPIS (SPI slave with EasyDMA)
55

66
compatible: "nordic,nrf-spis"
77

8-
include: ["nordic,nrf-spi-common.yaml", "memory-region.yaml"]
8+
include:
9+
- base.yaml
10+
- nordic,nrf-spi-common.yaml
11+
- memory-region.yaml
912

1013
properties:
1114
def-char:

0 commit comments

Comments
 (0)