I'm having an issue with FLEXCAN on i.mx6sx. It fails to probe during Linux bootup (linux-fslc v4.1-2.0.x).
In dts, I just enable the peripheral:
&flexcan1 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_flexcan1_1>;
status = "okay";
};
...
pinctrl_flexcan1_1: flexcan1grp_1 {
fsl,pins = <
MX6SX_PAD_SD3_DATA5__CAN1_TX 0x1b0b0
MX6SX_PAD_SD3_DATA7__CAN1_RX 0x1b0b0
>;
};
Kernel boot log:
CAN device driver interface
2090000.can supply xceiver not found, using dummy regulator
flexcan 2090000.can: registering netdev failed
flexcan: probe of 2090000.can failed with error -110
After debugging the driver, I found register_flexcandev() enables the two clocks and calls flexcan_chip_disable() which timeouts.
I guess I'm missing some stupid little thing here. Does anybody have a suggestion what's wrong?
<dummy>
Hi kubiznak_petr
for community linux "linux-fslc" one can look at boundary devices settings in
https://github.com/boundarydevices/u-boot-imx6/tree/boundary-v2016.03/board/boundary/nitrogen6sx
Best regards
igor
Hi igor,
Thanks for your reply. I don't see any remarkable difference in the referenced dts file. I neither see anything remarkable in the u-boot - they only configure the pads, that shouldn't play any role, right?
I've cut the dts node to the minimum, i.e.:
&flexcan1 {
status = "okay";
};
Hence only enabling the node as defined in imx6sx.dtsi. Still does not work. The same behaviour for flexcan2.
Any idea why the FLEXCAN_MCR_LPM_ACK flag is not asserted?
Best Regards,
Petr
Hi Petr
one can try to debug in probe() function using
AN4553 Using Open Source Debugging Tools for Linux on i.MX Processors
https://www.nxp.com/docs/en/application-note/AN4553.pdf
Best regards
igor