What's difference between --gpus and --runtime=nvidia for the docker container?

To put it simply, use --gpus on x86 and --runtime=nvidia on jetson/ARM SBSA system.

On Jetson, CUDA and some device nodes are shared with the host. You can view this file for more information.
/etc/nvidia-container-runtime/host-files-for-container.d/l4t.csv

For newer Jetpack, please check /etc/nvidia-container-runtime/host-files-for-container.d/drivers.csv

In fact, more details need to refer to nvidia-container-toolkit,

The nvidia-container-toolkit uses the libnvml/nvidia-modprobe library to map device nodes, such as /dev/nvidiax, /dev/nvidia-modeset, and /dev/nvidia-uvm to containers, allowing the use of specified GPUs/vGPUs (mig) within the container.

Please refer to this repository

and this documentation.