Boot Jetson xavier NX using M.2 Key-M SSD

Hello,

Regarding : Boot Jetson Xavier NX from external SSD - #10 by user103370

I made one change in CBOOT boot loader as well as added some debug prints in cboot code where NVME SSD gets detected. I made below changes:

+#define NVME_CLASS_CODE 0x060400
+//#define NVME_CLASS_CODE 0x010802
-#define NVME_CLASS_CODE 0x010802

After that, cboot bootloader will be able to detect the PCIe device and gives the below logs:

[0008.593] I> Number of PCIe devices detected: 2
[0008.597] E> tegrabl_pcie_get_dev, returning enumeration data
[0008.603] E> pcie_dev=0xa0694cb8
[0008.606] E> Found NVMe pcie device

After that, It will not be able to get the bar. It will receive the bar value as 0x0.

[0008.609] E> NVME: bar=0x0

Can you please help me to resolve this issue?

Thanks and regards

Hi,

Is this an issue specific to one kind of NVMe drive?

Hi WayneWWW,

Thank you for the quick response.

Nop, We connected same NVMe drive with NX devkit and it is able to boot from same NVMe drive.

In our case, We have PCIe switch in between to NX SoM and M.2 Key-M connector. If we are performing the experiment with the NX devkit its working fine, but with our case its not working. I am not able to understand where I need to change in cboot source code for the port changes.

Thanks and regards

Is this nvme drive able to get detected in kernel?

Hello WayneWWW,

Yes, we are able to detect the same NVMe drive in kernel.

Thanks and regards

Could you share the original log from your cboot where no change is applied?

Oh, I just realized, are you talking about you are using a custom board?

Hi WayneWWW,

Please find the attached cboot logs.
cboot_log.txt (32.1 KB)

Are you talking about you are using a custom board?
→ Yes

Thanks and regards

Hello WayneWWW,

Is there any update from above attached logs?

I tried to update the bar instance from 0-5, but with all the instance, I am geeting the bar value as 0x0 only. So where we can have to debug?

uint64_t bar = pcie_dev->bar[0].start;

Thanks and regards

Hello,

Is there any update? Please help us to resolve this.

Thanks and regards

Hello WayneWWW,

After updating pcie_bus_walk API, I am able to detect the NVMe SSD as well as also getting the Bar address. Now, It will failing at below stage:

So can you please help me to resolve this issue?

Thanks and regards

Hi,

Sorry that I want to clarify this issue again

  1. Same version of cboot software, when it moves from your carrier board to devkit, it would work?

  2. Have you tried different kind of NVMe drive?

Hello WayneWWW,

  1. Same version of cboot software, when it moves from your carrier board to devkit, it would work?
    Ans : Yes, It is correct

  2. Have you tried different kind of NVMe drive?
    Ans : Yes, we tried with 4 different NVMe drive, but getting the same error.

I am attaching the CBOOT logs here of NX devkit and our custom carrier board.
nx_custom.txt (18.5 KB)
NX_Devkit.txt (54.8 KB)

Thanks and regards

Hello WayneWWW,

I made below changes in cboot source code to detect the NVMe SSD in custom device.
nx_custom_device_changes.patch (5.3 KB)

Case-1 : If we are not doing any changes in cboot source code, and plugin SSD with NX devkit. It is working fine.

Case-2 : If we made above changes in cboot source code, it is able to detect NVMe drive as well as it is able to get the bar address properly, but it is getting the empty mqes. So I need your help to resolve this issue.

Case-3 : If we made above changes in cboot source code and update the #define NVME_CLASS_CODE 0x010802” value then it is also working in NX devkit.

Please let me know if any query regarding the mentioned cases and attached patch and help me to resolve this issue.

Thanks and regards

Actually, what I want to say is we should clarify the hardware difference between your board and devkit.

This issue may not be resolved by software patching in cboot part.

Hello WayneWWW,

In our custom device architecture, we replaced the M.2 Key-M connector with the PCIe switch, and M.2 Key-M connector is connected with the PCIe switch DSP port. Below image clarifying the same thing.

So this is the hardware difference between the NX devkit and our custom device.

Please let me know, if any query in above mentioned architecture.

Thanks and regards

Hello WayneWWW,

Is there any update?

Thanks and regards

The CBoot PCIE failed to read due to your HW change, and that’s we never tested. currently no idea aboit this, will forward to internal team to see if can have some suggestions.

Hello Kayccc,

Thank you for the response. Please inform me, if any update receive from your internal team.

Thanks and regards

Hello,

Is there any update from internal team?

Thanks and regards