Closed nielsavonds closed 3 years ago
Hey @nielsavonds Thanks for sharing this. I think we can add this check in the build time for safety, however, we are using the same/similar machine names as Nvidia have in Jetpack.
We could issue a warning on any MACHINE name longer than 31 characters, since the rest of the fields+separators shouldn't be more than 32 characters; an earlier warning would be better, I think. But also including a check on the total length of the spec during BUP generation is also a good idea, just in case.
I've also added a note about machine name length to the wiki page about creating a custom machine definition.
In our setup, the TNSPEC was 64 bytes long. Apparently, nv_update_engine is unable to cope with a TNSPEC longer than 63 bytes, probably due to some buffer overflow. This translates in failed updates showing the following log:
To Reproduce Steps to reproduce the behavior:
Suggestion I assume this is something out of your control, so I would suggest including a warning or error when building using a machine name that is too long, to avoid anyone else spending a lot of time trying to figure out what is going on. I would either create a separate function for this or put it in tegraflash_generate_bupgen_script. Something along the lines of: