AGX Orin - Kernel panic when camera streaming restarts

Under Jetpack 5.1.2 we were experiencing occasional kernel panic.
The problem was solved with a patch to capture-ivc.c.
The details can be found in topic:

We are now moving to Jetpack 6.2.
Checking the source code, it does not look like the patch is applied in Jetpack 6.2.

Does Jetpack 6.2 require a similar patch or the problem was addressed in another way?

*** Please note that this reply is generated by LLM automatically ***

Based on the provided context, I’ll provide a comprehensive answer to your question.

Background

You were experiencing occasional kernel panic issues under Jetpack 5.1.2 when restarting camera streaming on Jetson AGX Orin. The problem was solved with a patch, and the details can be found in the topic “Kernel panic when camera streaming restarts Jetson AGX Orin”.

Current Situation

You are now moving to Jetpack 6.2 and are concerned that the patch may not be applied in this version. After checking the source code, you suspect that the patch may not be included in Jetpack 6.2.

Analysis

To determine if Jetpack 6.2 requires a similar patch, we need to analyze the changes made in Jetpack 6.2 compared to Jetpack 5.1.2. Unfortunately, the provided context does not contain information about the specific changes made in Jetpack 6.2.

However, we can look at the general information about Jetpack 6.2. According to the context, Jetpack 6.1 GA is a software package for AI applications, and Jetpack 6.2 is likely a subsequent version. It is possible that the kernel panic issue was addressed in another way in Jetpack 6.2, but without more information, we cannot confirm this.

Comparison with Other Issues

We can look at other issues reported in the context to see if there are any similar kernel panic issues reported for Jetpack 6.2. One issue that stands out is the “Kernel BUG at drivers/soc/tegra/cbb/tegra194-cbb.c:2057!” reported for Jetson Xavier NX. Although this issue is not directly related to camera streaming, it does indicate that there may be kernel-related issues in Jetpack 6.2.

Conclusion

Based on the provided context, it is unclear if Jetpack 6.2 requires a similar patch to address the kernel panic issue when restarting camera streaming. Without more information about the changes made in Jetpack 6.2, we cannot confirm if the issue was addressed in another way. It is recommended to further investigate the changes made in Jetpack 6.2 and to test the camera streaming functionality to determine if the issue still exists.

Recommendation

To resolve this issue, you may want to:

  1. Check the Jetpack 6.2 release notes and documentation to see if there are any known issues or fixes related to kernel panic or camera streaming.
  2. Test the camera streaming functionality on Jetpack 6.2 to determine if the issue still exists.
  3. If the issue still exists, consider reaching out to NVIDIA support or the Jetpack community for further assistance.

This is what I am trying to do.

Hello @Agtonomy,

How is it going?

Have you tried reaching out to NVIDIA support or the Jetpack community ?
haha, just kidding, I thought it was super funny.

Quick couple of questions?

  1. Have you already tried running JP6.2? And if so, are you experiencing the same issue?

  2. Do you have still have the patch at hand?

  3. If you are experiencing the same behavior and still have the patch at hand, have you tried applying the patch? It might require some tweaking to get it ported to JP6.2.

best regards,
Andrew
Embedded Software Engineer at ProventusNova

I have Jetpack 6.2 stock running but the camera driver is not ready yet, so cannot test for it yet.
I am currently working on kernel customization and going through the patches that we applied to Jetpack 5.1.2.
Since the issue was confirmed by Nvidia and solved with a kernel patch, I though they should know if it was resolved in later releases.
On JP 5.1.2 it was not deterministic, sometime it took a days to experience the fault - so it’s not easy to test.
The patch itself is available there:

As far as I can tell it has not been implemented in JP 6.2 - but maybe the issue was resolved in another way.

Hi @Agtonomy,

Understood, thanks for the details.

We have been using Jetpack 6.2 with one of our customers and haven’t experienced that issue yet. After porting the camera drivers from them and testing, we encountered this issue though, however, we applied that patch and our dual camera system started working as expected. Just letting you know in case you run into a similar situation in the future.

And, with regards to the patch you mentioned, haven’t experienced anything similar playing with JP6.2. What we would do in your shoes would be to not port the patch for the moment, just to keep the system simple and avoid adding new variables to the equation. Later, if the issue appears during testing, we would considering porting the patch.

Maybe we can get @JerryChang involved in this thread since he was who recommended the patch in the first place.

Anyway, please do not hesitate to reach out if you need further support or if you want to speed up porting process.

best regards,
Andrew
Embedded Software Engineer at ProventusNova

Hi Andrew
Thank you for the info. The issue we were experiencing with JP 5.1.2 was most likely to occur when multiple camera string were starting/restarting at the same time.
Best Regards

HI @Agtonomy,

Sure ! It’s a pleasure to help.

Got it. Yeah, we are running simultaneous camera capture on JP6.2 in our customer’s project without any issues. You might be using more camera with could trigger the behavior you have experienced.

Please keep us posted on the tests you run.
We would love to hear if you find out anything interesting on JP6.2.

best regards,
Andrew
Embedded Software Engineer at ProventusNova

hello Agtonomy,

we still need that change for rel-36.
FYI, we’ve complete the code-review progress, and having the fix (i.e. add semaphore to avoid multi-cam race condition) landed to rel-36 code-line.
however.. such fix did not included in JP-6.2 public release since it did not catch the JP-6.2/r36.4.2 release date.

Thank you for confirmation. Will you be able to provide an official patch?

hello Agtonomy,

please give it a try with the attachment,
0001-capture-ivc-fix-multi-cam-race-condition.patch (4.3 KB)

Thank you for the patch. Are there any other important kernel patches that did not make it to the 36.4.3 release but have been completed since then?

hello Agtonomy,

ummm… there should be no other important kernel patches.