I have an out-of-tree sensor that communicates over a UART with my STM32MP13. I am writing its kernel module and I want to include the sensor so that it is directly recognized by the kernel.
The sensor is attached to UART8 so I thought that the sensor node should be a child node of the UART8 node. When building my image with Yocto I get an error when compiling the DTS. Any documentation or guidelines in this context are much appreciated.
&uart8 {
pinctrl-names = "default", "sleep", "idle";
pinctrl-0 = <&uart8_pins_a>;
pinctrl-1 = <&uart8_sleep_pins_a>;
pinctrl-2 = <&uart8_idle_pins_a>;
/delete-property/dmas;
/delete-property/dma-names;
status = "okay";
sensor: sensor@0 {
compatible = "vendor,sensor";
status = "okay"
current-speed = <115200>;
}
};
So i resolved this problem. What i was doing is assigning a non-declared property to my sensor "current-speed" which belongs to the uart8 node. By declaring "current-speed" under uart8 node everything went okay.