[nvcamera-daemon] open("/dev/nvhost-ctrl-vi", O_RDWR|O_CLOEXEC) = -1 ENODEV (No such devic

Hello,

I’ve problems getting the TX1 onboard camera (OV5693) to work. I followed the guideline “V4L2 on Jetson TX1” and “Example Sensor: OV5693” and I got one frame via yavta tool.

But whenever I tried to use

nvgstcapture-1.0

or use

/usr/bin/gst-launch-1.0 nvcamerasrc ! 'video/x-raw(memory:NVMM),width=1920, height=1080, format=(string)I420' ! nvhdmioverlaysink -e

I always get “Camera Daemon stopped functioning…”

After some debugging it turns out that nvcamera-daemon tries to open “/dev/nvhost-ctrl-vi” which is not there that forces a SIGSEGV:

SCF: Error ResourceError: Unable to open Ioctl FD (in src/services/power/PowerServiceHwVi.cpp, function initialize(), line 41)
SCF: Error ResourceError: (propagating) (in src/services/power/PowerServiceCore.cpp, function initialize(), line 50)

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0xf5d05450 (LWP 30236)]
0xf71e7078 in ?? () from /usr/lib/arm-linux-gnueabihf/tegra/libscf.so
(gdb) quit
[pid 30260] open("/dev/nvhost-ctrl-vi", O_RDWR|O_CLOEXEC) = -1 ENODEV (No such device)
[pid 30260] write(2, "SCF: Error ResourceError: Unable"..., 127SCF: Error ResourceError: Unable to open Ioctl FD (in src/services/power/PowerServiceHwVi.cpp, function initialize(), line 41)
) = 127
[pid 30260] close(-1)                   = -1 EBADF (Bad file descriptor)
[pid 30260] write(2, "SCF: Error ResourceError: (propa"..., 117SCF: Error ResourceError: (propagating) (in src/services/power/PowerServiceCore.cpp, function initialize(), line 50)
) = 117
[pid 30260] --- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_addr=0xffffffff} ---

A previously opened “/dev/nvhost-ctrl” (not “/dev/nvhost-ctrl-vi”!) just went fine.

I’m using a L4T R23.2 with nVidia provided kernel source for 3.10.67 with patches to support OV5693.

Any hints?

Thank you.

Are all of the nVidia-specific files in place? You can check via:

sha1sum -c /etc/nv_tegra_release

The “/dev” files are added by a kernel feature, and are not real files. If the file is not found, then it means either your kernel was not compiled with the feature or a module version of the feature was not loaded.

1 Like

Gives:

ubuntu@tegra-ubuntu:~$ sha1sum -c /etc/nv_tegra_release
/usr/lib/arm-linux-gnueabihf/tegra/libnvmmlite_image.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvomx.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmedia.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmmlite_utils.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libglx.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libscf.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvexif.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvrm_gpu.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmm_parser.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvrm.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmm_contentpipe.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvos.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvtnr.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvavp.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmmlite_video.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvodm_imager.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvjpeg.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvtvmr.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvdc.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libtegrav4l2.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmm.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvapputil.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvcameratools.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvcam_imageencoder.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmmlite_audio.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmm_utils.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvomxilclient.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvwinsys.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnveglstreamproducer.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvrm_graphics.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvddk_2d_v2.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvtestresults.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvparser.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvddk_vic.so: OK
/usr/lib/arm-linux-gnueabihf/tegra/libnvmmlite.so: OK
/usr/lib/xorg/modules/drivers/nvidia_drv.so: OK
/usr/lib/xorg/modules/extensions/libglx.so: OK
ubuntu@tegra-ubuntu:~$

Here is a little misunderstanding: The file “/dev/nvhost-ctrl-vi” exists but the device behind it is missing - ENODEV

[pid 30260] open("/dev/nvhost-ctrl-vi", O_RDWR|O_CLOEXEC) = -1 ENODEV (No such device)

Which module/driver/device is “responsible” for “nvhost-ctrl-vi”?

Thanks.

Does “lsmod” show “nvhost_vi”? There is a module file nvhost_vi.ko.

FYI, a cloned copy of the root file system will show only actual files in “/dev”, and will not show files which are created dynamically via a kernel feature. I checked a cloned copy for “/dev/nvhost-ctrl-vi”, and it does not exist…the file exists only when the kernel module or feature is active. This implies that at minimum the driver itself is there. Everything needed to talk to the device or hardware behind the feature is there.

Perhaps the issue is about permissions to open the device (which goes beyond permissions to open an ordinary file). Try with sudo.

As to the actual device/hardware the driver interfaces with, I do not know.

Hi linuxdev,

thanks for your reply.

Actually I’m tired of hunting bugs while L4T R24.1 is available. And guess what? On L4T R24.1 the whole camera stuff is working right away - without applying a single patch.

Thanks to nVidia.