Can function failed after flash pcie endpoint

Hi
I want to use xavier in pcie endpint mode.
I consulted the L4T doc and only modified the odm value. After the flash , I found that the can bus can no longer send and receive data. I suspect that the odm value affected the function of the can bus. If it is changed to the default odm, the can is normal.

Flashing the PCIe Endpoint on a Jetson AGX Xavier Series System

A Jetson system must be flashed in a specific way to enable PCIe endpoint mode. Use the following steps to flash the endpoint system:

1.In the extracted L4T release directory, edit p2972-0000.conf.common. Set bit 12 of the ODMDATA value, i.e. change it from 0x09190000 to 0x09191000.

2.Run the following command to re-flash the system:

sudo ./flash.sh jetson-xavier mmcblk0p1

Note that this completely erases any data previously stored on the Jetson system.

3.Edit p2972-0000.conf.common again and restore the ODMDATA property’s original value. This ensures that any systems flashed in the future operate in PCIe root port mode.

Except for changing the odm value , Is there any other way to enable pcie’s endpoint mode?

Changing the ODM data is the only way to configure Jetson-Xavier in EP mode. Ideally it shouldn’t effect the CAN operation. We’ll look into it and get back to you on this.

Hi,

Any error log from dmesg when CAN bus stop working?

Hi
there is the log on endpoint xavier:

[ 11.819019] can: controller area network core (rev 20120528 abi 9)
[ 11.825767] can: raw protocol (rev 20120528)
[ 11.859129] net can0: mttcan device registered (regs=ffffff800b0e1000, irq=71)
[ 11.862429] net can1: mttcan device registered (regs=ffffff800b0e7000, irq=72)
[ 11.866748] mttcan c310000.mttcan can0: bitrate error 0.2%
[ 11.868765] mttcan c310000.mttcan can0: Bitrate set
[ 11.868828] mttcan_controller_config: ctrlmode 0
[ 11.868844] mttcan c310000.mttcan can0: Bitrate set
[ 11.869252] IPv6: ADDRCONF(NETDEV_CHANGE): can0: link becomes ready

[ 2417.635487] mttcan c310000.mttcan can0: entered error warning state
[ 2417.635635] mttcan c310000.mttcan can0: entered error passive state
[ 2417.636253] mttcan c310000.mttcan can0: entered bus off state

however on the root point there is not have the log after [2417.635487]…only has below log

can: controller area network core (rev 20120528 abi 9)
can: raw protocol (rev 20120528)
net can0: mttcan device registered (regs=ffffff800b0e1000, irq=71)
net can1: mttcan device registered (regs=ffffff800b0e7000, irq=72)
mttcan c310000.mttcan can0: bitrate error 0.2%
mttcan c310000.mttcan can0: Bitrate set
mttcan_controller_config: ctrlmode 0
mttcan c310000.mttcan can0: Bitrate set
IPv6: ADDRCONF(NETDEV_CHANGE): can0: link becomes ready

Which software release are you using?

Hi
The version we are using is L4T 32.4.3.

Hi.

Is it always waiting for 40 mins to let this issue get hit?

[ 2417.635487] mttcan c310000.mttcan can0: entered error warning state
[ 2417.635635] mttcan c310000.mttcan can0: entered error passive state
[ 2417.636253] mttcan c310000.mttcan can0: entered bus off state

Hi
Not a fixed time error, but an error after I execute the can command to send and receive

Can you try this for like 10 times and see if the result is stable? Also, what commands are your using?

  1. Run the CAN command

  2. Check the result

  3. Reboot

  4. Repeat (1)

Hi
On endponint xavier :I use cansend can0 1F334455#1122334455
On rootpoint Xavier: I use candump can0

  On endpint command will execute okay,but there is nothing accept on rootpoint candump.

Does PCIe have anything to do with the CAN data transfer here?

Hi
I have tested it more than 10 times and the results are the same, do you have similar conditions in the test?

Hi
I think pcie and can have nothing to do, but this can interface is reserved for peripheral equipment

I mean can we use both devices in RP mode PCIe to test or both devices in EP mode PCIe to test?

If you suspect the pcie EP mode will cause problem, then the both EP mode case should always hit CAN bus error on both side. While the both RP mode case shall not.

Hi
I have tried both RP mode the can function works well,However both EP mode ,I haven’t tested it both in EP mode。

Hi,
Did you also tried sending from RP mode and receiving on EP mode?
I see the failure case is of RP as receiver and EP as sender.
Can you share vice-versa results?

1 Like

There is no update from you for a period, assuming this is not an issue any more.
Hence we are closing this topic. If need further support, please open a new one.
Thanks

Also, we would like to know which device/connector you are using with Jetson which you are using as RP mode? what are the signals it is sharing with jetson? Details would help to debug further.