MCP2518FD not working with JetPack 6.0 GA

Could you check if it could work with 500000 as bitrate?

$ ip link set can1 type can bitrate 500000 restart-ms 1000

Please also share the device tree source including mcp251xfd CAN configuration in spi node.

Hi KevinFFF

Changing the bitrate does not change anything, still sending from the mcp251xfd CAN is not possible.

Here is the dts:

clocks {
			clk40m: mcp2518fd_osc {
				#clock-cells = <0>;
				compatible = "fixed-clock";
				clock-frequency = <40000000>;

spi@3210000{ /* SPI1 in 40 pin conn */
			status = "okay";
			can@0 {
				compatible = "microchip,mcp2518fd";
				status = "okay";
				reg = <0x0>;
				spi-max-frequency = <20000000>;
				clocks = <&clk40m>;
				interrupts-extended = <&gpio TEGRA234_MAIN_GPIO(Z, 7) IRQ_TYPE_LEVEL_LOW>;
				vdd-supply = <&vdd_5v0_sys>;
				xceiver-supply = <&vdd_5v0_sys>;
				controller-data {
					nvidia,cs-setup-clk-count = <0x1e>;
					nvidia,cs-hold-clk-count = <0x1e>;
					nvidia,rx-clk-tap-delay = <0x1f>;
					nvidia,tx-clk-tap-delay = <0x0>;

Do you also have MCP2515 module?

We have only this module to verify locally.
You can refer to MCP2515 Verification for the detailed steps from me.

Hi KevinFFF

No, we do not have an MCP2515 module.
Do you see any error in our device tree?
Can you tell us anything about the missing patches for the SPI driver?

Actually, the current SPI driver in JP6 has been verified internally.
The major difference between these 2 releases are about the driver in JP5 had an API to select best_parent_clk but it is removed in JP6 since it is not permitted from upstream.
It seems your issue may be caused from the clock parent using for SPI.

Hi sevm89

Could you please tell me how you ported the driver from K5.10 to K5.15?
I have tried compiling the driver from K5.10 on my Jetson running K5.15 and I’m having trouble.

Thank you.

Hi stanley.adams

We uploaded the spi driver file in a previous post:

Thank you for the quick response.
I was able to compile your modified version of the driver and insert it into the kernel.
Unfortunately it didn’t solve the problem I have.