The device mode you see for filesystems in a fully booted Jetson is just a demo. This mode is from the “Gadget” API spec and is entirely software setup. When using this as a filesystem access a partition or other mass storage device becomes visible, and in this case it isn’t the whole Jetson made visible (this would have some pretty serious security issues if it were). The particular filesystem happens to be a small file which is covered by loopback, formatted, and then treated as a disk partition for USB export. Note also that the filesystem type is one which Windows and Mac can understand; the actual Jetson uses ext4, which is what you’d get if you directly made the entire system available as a simple device. Quite often people attribute any such “show the whole device in USB” mode as being standard, which is not what USB device mode really is. If you have a goal of something you want to change it is easy to ask, but I’ll add some URLs (which basically talk about that block of code which @KevinFFF just quoted):
- https://forums.developer.nvidia.com/t/topic/240909/2
- https://forums.developer.nvidia.com/t/topic/240958/4
- https://forums.developer.nvidia.com/t/topic/254268/5
- https://forums.developer.nvidia.com/t/topic/240958/7
- https://forums.developer.nvidia.com/t/topic/254268/15
- https://forums.developer.nvidia.com/t/topic/305104/4
Something to note about the existing mass storage device mode emulation is that the partition itself, under loopback (it’s really just a file), is set as read-only. If you were to change the Gadget API file, then it would still be read-only unless both the filesystem (loopback file) and Gadget mode are read-write.