SiFive SPI controller
Schema identifier ($id): "http://devicetree.org/schemas/spi/spi-sifive.yaml#"
Schema dialect ($schema): "http://devicetree.org/meta-schemas/core.yaml#"
Maintainers (maintainers): "Pragnesh Patel <pragnesh.patel@sifive.com>", "Paul Walmsley <paul.walmsley@sifive.com>", "Palmer Dabbelt <palmer@sifive.com>"
All of these rules must match (allOf) #
Rule 1 #
Shared schema rule (
$ref):spi-controller.yaml#
Properties and child nodes (properties) #
compatible — required here #
Array item rules (items) #
Item 1
Allowed values (
enum):"sifive,fu540-c000-spi","sifive,fu740-c000-spi"
Item 2
Exact value (
const):"sifive,spi0"
Should be "sifive,<chip>-spi" and "sifive,spi<version>". Supported compatible strings are - "sifive,fu540-c000-spi" and "sifive,fu740-c000-spi" for the SiFive SPI v0 as integrated onto the SiFive FU540 and FU740 chip resp, and "sifive,spi0" for the SiFive SPI v0 IP block with no chip integration tweaks. Please refer to sifive-blocks-ip-versioning.txt for details SPI RTL that corresponds to the IP block version numbers can be found here - https://github.com/sifive/sifive-blocks/tree/master/src/main/scala/devices/spi
reg — required here #
Minimum number of items (minItems): 1
Array item rules (items) #
Item 1
SPI registers region
Item 2
Memory mapped flash region
interrupts — required here #
Maximum number of items (maxItems): 1
clocks — required here #
Maximum number of items (maxItems): 1
Must reference the frequency given to the controller
sifive,fifo-depth — not listed as required here #
Depth of hardware queues; defaults to 8
Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32
Default value (default): 8
sifive,max-bits-per-word — not listed as required here #
Maximum bits per word; defaults to 8
Shared schema rule ($ref): /schemas/types.yaml#/definitions/uint32
Allowed values (enum): 0, 1, 2, 3, 4, 5, 6, 7, 8
Default value (default): 8
Required in this object (required): "compatible", "reg", "interrupts", "clocks"
Properties not evaluated by applicable rules (unevaluatedProperties) #
false
Not allowed by this rule.
Examples (examples) #
spi: spi@10040000 {
compatible = "sifive,fu540-c000-spi", "sifive,spi0";
reg = <0x10040000 0x1000>, <0x20000000 0x10000000>;
interrupt-parent = <&plic>;
interrupts = <51>;
clocks = <&tlclk>;
#address-cells = <1>;
#size-cells = <0>;
sifive,fifo-depth = <8>;
sifive,max-bits-per-word = <8>;
};
Source notes #
Annotations retained from the schema source
Line 1: SPDX-License-Identifier: GPL-2.0