devicetree vs. MODULE_DEPEND

Manuel Stühn freebsdnewbie at freenet.de
Wed Aug 9 21:21:55 UTC 2017


Hi list,

is it correct, that the sequence in the devicetree-blob defines the 
probing sequence without considering the MODULE_DEPEND-macro?

I stumbled over an unexpected behavior during the ti_pruss-driver 
development. Because the ti-pruss is gone in the default devicetree, I 
activate it via the overlay-framework and put it to the address 
"/ocp/pruss at 4a300000".  The devicetree-blob contains the entry and the 
driver gets probed, but it fails to enable its clock. 
This is quite obvious as according to dmesg the am335x_prcm0 is probed 
_after_ the ti_pruss0 device. So I tried to handle this by adding an 
explicit dependency to ti_prcm into the ti_pruss driver like: 
MODULE_DEPEND(ti_pruss, ti_prcm, 1, 1, 1);

It compiles cleanly, unfortunately this changes nothing. Only placing it 
in the devicetree after the prcm-node or loading it as a module after 
the OS booted up makes the device probe correctly.

Any ideas?


More information about the freebsd-arm mailing list