FDT help

Milan Obuch freebsd-arm at dino.sk
Fri Apr 24 08:16:21 UTC 2015


On Fri, 24 Apr 2015 11:00:33 +0300
Daniel Braniss <danny at cs.huji.ac.il> wrote:

> Hi,
> I have this in my rpi.dts file:
> 	spi0 {
> 		rfid0 {
> 			compatible = “rfid,mfrc5”;
> 			spi-chipselect = <0>;
> 			reset {
> 				compatible = “pcd-reset”;
> 				gpios = <&gpio 22 2>;
> 			};
> 	};
> 
> my mfrc5 driver is starting to work - i can load, open, ioctl, unload,
> but after much grepping, I can’t figure out how from inside the
> driver i can access the reset pin - which i have defined as gpio 22
> ofwdump -aP
> 
> # ofwdump -aP
>     ...
>     Node 0x13c4: spi0
>       compatible:
>         62 72 6f 61 64 63 6f 6d 2c 62 63 6d 32 38 33 35 2d 73 70 69 
>         00 62 72 6f 61 64 63 6f 6d 2c 62 63 6d 32 37 30 38 2d 73 70 
>         69 00 
>       reg:
>         00 20 40 00 00 00 00 20 
>       interrupts:
>         00 00 00 3e 
>       interrupt-parent:
>         00 00 00 01 
>       Node 0x143c: rfid0
>         compatible:
>           72 66 69 64 2c 6d 66 72 63 35 00 
>           'rfid,mfrc5'
>         spi-chipselect:
>           00 00 00 00 
>         Node 0x1470: reset
>           compatible:
>             70 63 64 2d 72 65 73 65 74 00 
>             'pcd-reset'
>           gpios:
>             00 00 00 03 00 00 00 16 00 00 00 02 
> 
> thanks,
> 	danny
>

Hello,

I think following could help - I am forwarding what was given to me in
similar circumstances :)

http://pastebin.com/4mbZFuv1

Regards,
Milan


More information about the freebsd-arm mailing list