On Mon Sep 30, 2024 at 6:58 PM MSK, Michael van Elst wrote:
> [email protected] ("Nikita Donskov") writes:
>
> >from RPI's firmware repo:
> >https://github.com/raspberrypi/firmware/blob/master/boot/overlays/spi1-1cs.=
> >dtbo
>
> Maybe spi0-1cs.dtbo works better.
>
>
> >     dtoverlay=3Dspi1-1cs,cs0_spidev=3Doff
>
> The *spidev* attributes are for Linux and the Linux driver.
>
> You can use http://cdn.netbsd.org/pub/NetBSD/misc/mlelstv/spi.dtbo,
> the source is http://cdn.netbsd.org/pub/NetBSD/misc/mlelstv/spi.dts:
>
> /dts-v1/;
> /plugin/;
>
> / {
>       compatible = "brcm,bcm2835";
>
>       fragment@0 {
>               target = <&spi>;
>
>               __overlay__ {
>                       status = "okay";
>                       pinctrl-names = "default";
>                       pinctrl-0 = <&spi0_gpio7>;
>               };
>       };
> };
>
>
> Greetings,

This worked! Thank you very much.
I replaced `/boot/overlays/spi1-1cs.dtbo` with `/boot/overlays/spi.dtbo`,
modified `/boot/config.txt`:
        dtoverlay=spi

and everything just worked as it ought to be.

I am wondering why NetBSD image doesn't have this overlay and
`/boot/overlays/` directory at all.

-Nikita

Reply via email to