Enable Cadence DesignWare SPI driver #10
SPI now loads ok:
# dmesg |grep spi
[ 3.923747] dw_spi_mmio 12410000.spi2: Detected FIFO size: 8 bytes
[ 3.930002] dw_spi_mmio 12410000.spi2: DMA init failed
[ 3.935487] dw_spi_mmio 12410000.spi2: registered master spi1
[ 3.941662] spi spi1.0: setup mode 0, 8 bits/w, 10000000 Hz max --> 0
[ 3.948847] dw_spi_mmio 12410000.spi2: registered child spi1.0
And spidev now exists:
# ls -ltar /dev/spidev1.0
crw-rw---- 1 root root 153, 0 Jan 1 00:00 /dev/spidev1.0
This also required adding spi2 node to the device tree like in beagle_uboot-opensbi:
https://github.com/starfive-tech/beagle_uboot-opensbi/blob/starfive/arch/riscv/dts/starfive_vic7100_evb.dts#L488
spi2:spi2@12410000 {
compatible = "snps,dw-apb-ssi";
#address-cells = <1>;
#size-cells = <0>;
interrupt-parent = <&plic>;
interrupts = <70>;
reg = <0x0 0x12410000 0x0 0x10000>;
clocks = <&ahb2clk>;
/*num-cs = <1>;
cs-gpios = <&gpio 0 0>;*/
spi_dev0: spi@0 {
compatible = "rohm,dh2228fv";
spi-max-frequency = <10000000>;
reg = <0>;
status = "okay";
};
};