CrossCompile ok, run error!

We need to crosscompile our application on x86-64.

/home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/home/cross/third_libs_binary/cuda-8.0/include -I./inc/GL -I/home/cross/third_libs_binary/tegra/include -fPIC -o main.o -c main.cpp
/home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/home/cross/third_libs_binary/cuda-8.0/include -I./inc/GL -I/home/cross/third_libs_binary/tegra/include -fPIC -o bmphandle.o -c bmphandle.cpp
/home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/home/cross/third_libs_binary/cuda-8.0/include -I./inc/GL -I/home/cross/third_libs_binary/tegra/include -fPIC -o algorithm.o -c algorithm.cpp
/home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/home/cross/third_libs_binary/cuda-8.0/include -I./inc/GL -I/home/cross/third_libs_binary/tegra/include -fPIC -o display.o -c display.cpp
/home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/home/cross/third_libs_binary/cuda-8.0/include -I./inc/GL -I/home/cross/third_libs_binary/tegra/include -fPIC -o endoscopedevice.o -c endoscopedevice.cpp
/home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/home/cross/third_libs_binary/cuda-8.0/include -I./inc/GL -I/home/cross/third_libs_binary/tegra/include -fPIC -o videodata/videodata.o -c videodata/videodata.cpp
make -C ./ImageProcessor
make[1]: Entering directory /home/wuyk/TX2/videoapp_cc/JetsonTX2Video/ImageProcessor' /usr/local/cuda-8.0/bin/nvcc -ccbin /home/cross/gcc-4.8.5-aarch64/ccbin -I/usr/local/cuda-8.0/include -I/home/cross/third_libs_binary/tegra/include -I./ -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -c kernel.cu -o kernel.o /usr/local/cuda-8.0/bin/nvcc -ccbin /home/cross/gcc-4.8.5-aarch64/ccbin -I/usr/local/cuda-8.0/include -I/home/cross/third_libs_binary/tegra/include -I./ -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -c ImageProcBase.cpp -o ImageProcBase.o /usr/local/cuda-8.0/bin/nvcc -ccbin /home/cross/gcc-4.8.5-aarch64/ccbin -I/usr/local/cuda-8.0/include -I/home/cross/third_libs_binary/tegra/include -I./ -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -c ImageProcessor.cpp -o ImageProcessor.o /usr/local/cuda-8.0/bin/nvcc -ccbin /home/cross/gcc-4.8.5-aarch64/ccbin -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -shared -o libMyCuda.so kernel.o ImageProcBase.o ImageProcessor.o -L/usr/local/cuda-8.0/targets/aarch64-linux/lib -lnppi -lnpps -lnppc mkdir -p ./../alglib/ cp -rf libMyCuda.so ./../alglib/libMyCuda.so make[1]: Leaving directory /home/wuyk/TX2/videoapp_cc/JetsonTX2Video/ImageProcessor’
make -C ./OV_Sensors
make[1]: Entering directory /home/wuyk/TX2/videoapp_cc/JetsonTX2Video/OV_Sensors' /home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-gcc -DDebug=0 -c ov_sensors.c /home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-ar -rcs libovsensor.a ov_sensors.o make[1]: Leaving directory /home/wuyk/TX2/videoapp_cc/JetsonTX2Video/OV_Sensors’
/home/cross/gcc-4.8.5-aarch64/bin/aarch64-unknown-linux-gnu-g++ -fPIC -o VideoTest main.o bmphandle.o algorithm.o display.o endoscopedevice.o videodata/videodata.o -L/home/cross/third_libs_binary/tegra/lib -lGL -lGLU -lX11 -lglut -pthread -L ./alglib/linux/aarch64 -lGLEW -L./ImageProcessor -lMyCuda -L./OV_Sensors -lovsensor -L/home/cross/third_libs_binary/cuda-8.0/targets/aarch64-linux/lib -lnppi -lnpps -lnppc -L/home/cross/third_libs_binary/cuda-8.0/lib64 -lcudart -L/home/cross/third_libs_binary/aarch64-X11 -lXext -lXi -lXxf86vm -lxcb -lXau -lXdmcp -L/home/cross/third_libs_binary/tegra/lib -lnvidia-tls -lnvidia-glcore -lnvdc -lnvidia-rmapi-tegra -lnvimp -lnvrm -lnvrm_gpu -lnvos -lnvrm_graphics

everthing is ok .scp the VideoTest to tx2.

nvidia@tegra-ubuntu:~/wuyk$ ldd VideoTest
linux-vdso.so.1 => (0x0000007f7829b000)
libGL.so.1 => /usr/lib/aarch64-linux-gnu/tegra/libGL.so.1 (0x0000007f78128000)
libGLU.so.1 => /usr/lib/aarch64-linux-gnu/libGLU.so.1 (0x0000007f780b6000)
libX11.so.6 => /usr/lib/aarch64-linux-gnu/libX11.so.6 (0x0000007f77f8d000)
libglut.so.3 => /usr/lib/aarch64-linux-gnu/libglut.so.3 (0x0000007f77f3b000)
libMyCuda.so => /home/nvidia/zhoudm/video/alglib/libMyCuda.so (0x0000007f77eb7000)
libnppi.so.8.0 => /usr/local/cuda-8.0/lib64/libnppi.so.8.0 (0x0000007f7352e000)
libnpps.so.8.0 => /usr/local/cuda-8.0/lib64/libnpps.so.8.0 (0x0000007f72f79000)
libnppc.so.8.0 => /usr/local/cuda-8.0/lib64/libnppc.so.8.0 (0x0000007f72f03000)
libcudart.so.8.0 => /usr/local/cuda-8.0/lib64/libcudart.so.8.0 (0x0000007f72e9f000)
libXext.so.6 => /usr/lib/aarch64-linux-gnu/libXext.so.6 (0x0000007f72e7f000)
libXi.so.6 => /usr/lib/aarch64-linux-gnu/libXi.so.6 (0x0000007f72e61000)
libXxf86vm.so.1 => /usr/lib/aarch64-linux-gnu/libXxf86vm.so.1 (0x0000007f72e4b000)
libxcb.so.1 => /usr/lib/aarch64-linux-gnu/libxcb.so.1 (0x0000007f72e20000)
libXau.so.6 => /usr/lib/aarch64-linux-gnu/libXau.so.6 (0x0000007f72e0d000)
libXdmcp.so.6 => /usr/lib/aarch64-linux-gnu/libXdmcp.so.6 (0x0000007f72df7000)
libnvidia-tls.so.28.1.0 => /usr/lib/aarch64-linux-gnu/tegra/libnvidia-tls.so.28.1.0 (0x0000007f72de6000)
libnvidia-glcore.so.28.1.0 => /usr/lib/aarch64-linux-gnu/tegra/libnvidia-glcore.so.28.1.0 (0x0000007f71438000)
libnvdc.so => /usr/lib/aarch64-linux-gnu/tegra/libnvdc.so (0x0000007f7141c000)
libnvidia-rmapi-tegra.so.28.1.0 => /usr/lib/aarch64-linux-gnu/tegra/libnvidia-rmapi-tegra.so.28.1.0 (0x0000007f713e1000)
libnvimp.so => /usr/lib/aarch64-linux-gnu/tegra/libnvimp.so (0x0000007f713cd000)
libnvrm.so => /usr/lib/aarch64-linux-gnu/tegra/libnvrm.so (0x0000007f71394000)
libnvrm_gpu.so => /usr/lib/aarch64-linux-gnu/tegra/libnvrm_gpu.so (0x0000007f7135f000)
libnvos.so => /usr/lib/aarch64-linux-gnu/tegra/libnvos.so (0x0000007f71342000)
libnvrm_graphics.so => /usr/lib/aarch64-linux-gnu/tegra/libnvrm_graphics.so (0x0000007f71330000)
libstdc++.so.6 => /usr/lib/aarch64-linux-gnu/libstdc++.so.6 (0x0000007f711a1000)
libm.so.6 => /lib/aarch64-linux-gnu/libm.so.6 (0x0000007f710f4000)
libgcc_s.so.1 => /lib/aarch64-linux-gnu/libgcc_s.so.1 (0x0000007f710d2000)
libpthread.so.0 => /lib/aarch64-linux-gnu/libpthread.so.0 (0x0000007f710a6000)
libc.so.6 => /lib/aarch64-linux-gnu/libc.so.6 (0x0000007f70f5f000)
libdl.so.2 => /lib/aarch64-linux-gnu/libdl.so.2 (0x0000007f70f4b000)
/lib/ld-linux-aarch64.so.1 (0x000000557f088000)
librt.so.1 => /lib/aarch64-linux-gnu/librt.so.1 (0x0000007f70f34000)

ldd the VideoTest

I alse compile the app on tx2.

g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/usr/local/cuda-8.0/include -I./inc/GL -fPIC -o main.o -c main.cpp
g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/usr/local/cuda-8.0/include -I./inc/GL -fPIC -o bmphandle.o -c bmphandle.cpp
g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/usr/local/cuda-8.0/include -I./inc/GL -fPIC -o algorithm.o -c algorithm.cpp
g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/usr/local/cuda-8.0/include -I./inc/GL -fPIC -o display.o -c display.cpp
g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/usr/local/cuda-8.0/include -I./inc/GL -fPIC -o endoscopedevice.o -c endoscopedevice.cpp
g++ -I./ImageProcessor -I./inc -I./videodata -I./OV_Sensors -I./ -I/usr/local/cuda-8.0/include -I./inc/GL -fPIC -o videodata/videodata.o -c videodata/videodata.cpp
make -C ./ImageProcessor
make[1]: Entering directory ‘/home/nvidia/wuyk/videoapp/JetsonTX2Video/ImageProcessor’
“/usr/local/cuda-8.0”/bin/nvcc -ccbin g++ -I"/usr/local/cuda-8.0"/include -I./ -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -c kernel.cu -o kernel.o
“/usr/local/cuda-8.0”/bin/nvcc -ccbin g++ -I"/usr/local/cuda-8.0"/include -I./ -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -c ImageProcBase.cpp -o ImageProcBase.o
“/usr/local/cuda-8.0”/bin/nvcc -ccbin g++ -I"/usr/local/cuda-8.0"/include -I./ -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -c ImageProcessor.cpp -o ImageProcessor.o
“/usr/local/cuda-8.0”/bin/nvcc -ccbin g++ -m64 -Xcompiler -fPIC -Xcompiler -Wall --gpu-architecture=compute_62 --gpu-code=sm_62 -shared -o libMyCuda.so kernel.o ImageProcBase.o ImageProcessor.o -L"/usr/local/cuda-8.0"/targets/aarch64-linux/lib -lnppi -lnpps -lnppc
mkdir -p ./…/alglib
cp -rf libMyCuda.so ./…/alglib/
make[1]: Leaving directory ‘/home/nvidia/wuyk/videoapp/JetsonTX2Video/ImageProcessor’
make -C ./OV_Sensors
make[1]: Entering directory ‘/home/nvidia/wuyk/videoapp/JetsonTX2Video/OV_Sensors’
gcc -DDebug=0 -c ov_sensors.c
ar -rcs libovsensor.a ov_sensors.o
make[1]: Leaving directory ‘/home/nvidia/wuyk/videoapp/JetsonTX2Video/OV_Sensors’
g++ -fPIC -o VideoTest main.o bmphandle.o algorithm.o display.o endoscopedevice.o videodata/videodata.o -lGL -lGLU -lX11 -lglut -pthread -L ./alglib/linux/aarch64 -lGLEW -L/usr/local/cuda-8.0/targets/aarch64-linux/lib -lnppi -lnpps -lnppc -L./ImageProcessor -lMyCuda -L./OV_Sensors -lovsensor -L/usr/local/cuda-8.0/lib64 -lcudart

ldd the VideoTest

linux-vdso.so.1 =>  (0x0000007fa8908000)
libGL.so.1 => /usr/lib/aarch64-linux-gnu/tegra/libGL.so.1 (0x0000007fa8795000)
libGLU.so.1 => /usr/lib/aarch64-linux-gnu/libGLU.so.1 (0x0000007fa8723000)
libglut.so.3 => /usr/lib/aarch64-linux-gnu/libglut.so.3 (0x0000007fa86d0000)
libMyCuda.so => /home/nvidia/zhoudm/video/alglib/libMyCuda.so (0x0000007fa864c000)
libcudart.so.8.0 => /usr/local/cuda-8.0/targets/aarch64-linux/lib/libcudart.so.8.0 (0x0000007fa85e9000)
libstdc++.so.6 => /usr/lib/aarch64-linux-gnu/libstdc++.so.6 (0x0000007fa8459000)
libgcc_s.so.1 => /lib/aarch64-linux-gnu/libgcc_s.so.1 (0x0000007fa8438000)
libpthread.so.0 => /lib/aarch64-linux-gnu/libpthread.so.0 (0x0000007fa840c000)
libc.so.6 => /lib/aarch64-linux-gnu/libc.so.6 (0x0000007fa82c4000)
/lib/ld-linux-aarch64.so.1 (0x0000005570ef4000)
libnvidia-tls.so.28.1.0 => /usr/lib/aarch64-linux-gnu/tegra/libnvidia-tls.so.28.1.0 (0x0000007fa82b3000)
libnvidia-glcore.so.28.1.0 => /usr/lib/aarch64-linux-gnu/tegra/libnvidia-glcore.so.28.1.0 (0x0000007fa6905000)
libX11.so.6 => /usr/lib/aarch64-linux-gnu/libX11.so.6 (0x0000007fa67dc000)
libXext.so.6 => /usr/lib/aarch64-linux-gnu/libXext.so.6 (0x0000007fa67bc000)
libdl.so.2 => /lib/aarch64-linux-gnu/libdl.so.2 (0x0000007fa67a9000)
libm.so.6 => /lib/aarch64-linux-gnu/libm.so.6 (0x0000007fa66fb000)
libXi.so.6 => /usr/lib/aarch64-linux-gnu/libXi.so.6 (0x0000007fa66dd000)
libXxf86vm.so.1 => /usr/lib/aarch64-linux-gnu/libXxf86vm.so.1 (0x0000007fa66c8000)
libnppi.so.8.0 => /usr/local/cuda-8.0/targets/aarch64-linux/lib/libnppi.so.8.0 (0x0000007fa1d3f000)
libnpps.so.8.0 => /usr/local/cuda-8.0/targets/aarch64-linux/lib/libnpps.so.8.0 (0x0000007fa178a000)
librt.so.1 => /lib/aarch64-linux-gnu/librt.so.1 (0x0000007fa1773000)
libnvdc.so => /usr/lib/aarch64-linux-gnu/tegra/libnvdc.so (0x0000007fa1757000)
libnvidia-rmapi-tegra.so.28.1.0 => /usr/lib/aarch64-linux-gnu/tegra/libnvidia-rmapi-tegra.so.28.1.0 (0x0000007fa171c000)
libxcb.so.1 => /usr/lib/aarch64-linux-gnu/libxcb.so.1 (0x0000007fa16f0000)
libnppc.so.8.0 => /usr/local/cuda-8.0/targets/aarch64-linux/lib/libnppc.so.8.0 (0x0000007fa167a000)
libnvimp.so => /usr/lib/aarch64-linux-gnu/tegra/libnvimp.so (0x0000007fa1665000)
libnvrm.so => /usr/lib/aarch64-linux-gnu/tegra/libnvrm.so (0x0000007fa162d000)
libnvrm_gpu.so => /usr/lib/aarch64-linux-gnu/tegra/libnvrm_gpu.so (0x0000007fa15f8000)
libnvos.so => /usr/lib/aarch64-linux-gnu/tegra/libnvos.so (0x0000007fa15da000)
libnvrm_graphics.so => /usr/lib/aarch64-linux-gnu/tegra/libnvrm_graphics.so (0x0000007fa15c9000)
libXau.so.6 => /usr/lib/aarch64-linux-gnu/libXau.so.6 (0x0000007fa15b6000)
libXdmcp.so.6 => /usr/lib/aarch64-linux-gnu/libXdmcp.so.6 (0x0000007fa15a0000)

it’s different, and the VideoTest(crosscompile) run error.

[ 7358.654636] sono_ovxx 2-0036: sono_ovxx_power_on: power on
[ 7358.660527] wuyk:sono_ovxx_read_reg:i2c write debug, 300b = 27
[ 7358.666720] wuyk:sono_ovxx_read_reg:i2c write debug, 300c = 40
[ 7360.032219] nvcsi 150c0000.nvcsi: Sono:sensor chip OV2740
[ 7360.043787] nvcsi 150c0000.nvcsi: Sono:sensor chip OV2740
[ 7360.049400] sono_ovxx 2-0036: sono_ovxx_s_stream++
[ 7360.081708] sono_ovxx 2-0036: sono_ovxx_s_stream–
[ 7361.959686] ---- mlocks ----

[ 7361.964116] ---- syncpts ----
[ 7361.967089] id 4 (disp_d) min 21716 max 21716 refs 1 (previous client : )
[ 7361.973884] id 5 (disp_e) min 1 max 1 refs 1 (previous client : )
[ 7361.979985] id 7 (vblank1) min 441488 max 0 refs 1 (previous client : )
[ 7361.986611] id 18 (17000000.gp10b_507) min 566666 max 566666 refs 1 (previous client : )
[ 7361.994708] id 19 (17000000.gp10b_506) min 210 max 210 refs 1 (previous client : )
[ 7362.002280] id 20 (17000000.gp10b_505) min 112126 max 112126 refs 1 (previous client : 17000000.gp10b_505)
[ 7362.011940] id 25 (17000000.gp10b_500) min 32 max 32 refs 1 (previous client : 17000000.gp10b_500)
[ 7362.020900] id 29 (tegra-vi4) min 16027 max 16027 refs 1 (previous client : tegra-vi4)
[ 7362.028821] id 30 (tegra-vi4) min 16027 max 16028 refs 1 (previous client : tegra-vi4)
[ 7362.036741] id 31 (17000000.gp10b_498) min 31794 max 31794 refs 1 (previous client : 17000000.gp10b_498)

[ 7362.048282] ---- channels ----
[ 7362.051338]
channel 1 - 15820000.se

[ 7362.057789] NvHost basic channel registers:
[ 7362.061978] CMDFIFO_STAT_0: 00002040
[ 7362.065650] CMDFIFO_RDATA_0: a9822000
[ 7362.069319] CMDP_OFFSET_0: 00000000
[ 7362.072998] CMDP_CLASS_0: 00000000
[ 7362.076669] CHANNELSTAT_0: 00000000
[ 7362.080345] The CDMA sync queue is empty.

[ 7362.085849]
channel 2 - 15830000.se

[ 7362.092297] NvHost basic channel registers:
[ 7362.096488] CMDFIFO_STAT_0: 00002040
[ 7362.100156] CMDFIFO_RDATA_0: 8210460c
[ 7362.103825] CMDP_OFFSET_0: 00000000
[ 7362.107481] CMDP_CLASS_0: 00000000
[ 7362.111151] CHANNELSTAT_0: 00000000
[ 7362.114819] The CDMA sync queue is empty.

[ 7362.120334]
channel 3 - 15840000.se

[ 7362.126779] NvHost basic channel registers:
[ 7362.130968] CMDFIFO_STAT_0: 00002040
[ 7362.134636] CMDFIFO_RDATA_0: 41090e08
[ 7362.138306] CMDP_OFFSET_0: 00000000
[ 7362.141973] CMDP_CLASS_0: 00000000
[ 7362.145641] CHANNELSTAT_0: 00000000
[ 7362.149310] The CDMA sync queue is empty.

[ 7362.154814]
---- host general irq ----

[ 7362.161524] sync_intc0mask = 0x00000001
[ 7362.165367] sync_intmask = 0x50000003
[ 7362.169035]
---- host syncpt irq mask ----

[ 7362.176087]
---- host syncpt irq status ----

[ 7362.183316] syncpt_thresh_cpu0_int_status(0) = 0x00000000
[ 7362.188721] syncpt_thresh_cpu0_int_status(1) = 0x00000000
[ 7362.194127] syncpt_thresh_cpu0_int_status(2) = 0x00000000
[ 7362.199529] syncpt_thresh_cpu0_int_status(3) = 0x00000000
[ 7362.204935] syncpt_thresh_cpu0_int_status(4) = 0x00000000
[ 7362.210340] syncpt_thresh_cpu0_int_status(5) = 0x00000000
[ 7362.215747] syncpt_thresh_cpu0_int_status(6) = 0x00000000
[ 7362.221165] syncpt_thresh_cpu0_int_status(7) = 0x00000000
[ 7362.226571] syncpt_thresh_cpu0_int_status(8) = 0x00000000
[ 7362.231977] syncpt_thresh_cpu0_int_status(9) = 0x00000000
[ 7362.237387] syncpt_thresh_cpu0_int_status(10) = 0x00000000
[ 7362.242879] syncpt_thresh_cpu0_int_status(11) = 0x00000000
[ 7362.248369] syncpt_thresh_cpu0_int_status(12) = 0x00000000
[ 7362.253857] syncpt_thresh_cpu0_int_status(13) = 0x00000000
[ 7362.259346] syncpt_thresh_cpu0_int_status(14) = 0x00000000
[ 7362.264836] syncpt_thresh_cpu0_int_status(15) = 0x00000000
[ 7362.270327] syncpt_thresh_cpu0_int_status(16) = 0x00000000
[ 7362.275818] syncpt_thresh_cpu0_int_status(17) = 0x00000000
[ 7362.281311] 17000000.gp10b pbdma 0:
[ 7362.284719] id: 3 (tsg), next_id: 3 (tsg) chan status: invalid
[ 7362.290741] PUT: 000000010042f238 GET: 000000010042f238 FETCH: 00000c48 HEADER: 60400000

[ 7362.300336] 17000000.gp10b eng 0:
[ 7362.303558] id: 3 (tsg), next_id: 3 (tsg), ctx status: valid
[ 7362.309327] faulted
[ 7362.310032] busy

[ 7362.313461] 17000000.gp10b eng 1:
[ 7362.316696] id: 5 (tsg), next_id: 5 (tsg), ctx status: valid

[ 7362.325608] 498-17000000.gp10b, pid 5333, refs: 2:
[ 7362.330316] channel status: in use idle not busy
[ 7362.335208] RAMFC : TOP: 8000001f08000080 PUT: 0000001f08000080 GET: 0000001f08000080 FETCH: 0000001f08000080
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00001f01 SEMAPHORE 0000001e 01ba0010 00000000 00000002

[ 7362.358660] 499-17000000.gp10b, pid 5329, refs: 2:
[ 7362.363367] channel status: in use idle not busy
[ 7362.368258] RAMFC : TOP: 8000000101803cd8 PUT: 0000000101803cd8 GET: 0000000101803cd8 FETCH: 0000000101803cd8
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000001 02207ffc 00000002 00001004

[ 7362.391734] 500-17000000.gp10b, pid 5329, refs: 2:
[ 7362.396444] channel status: in use idle not busy
[ 7362.401332] RAMFC : TOP: 8000001f08540018 PUT: 0000001f08540018 GET: 0000001f08540018 FETCH: 0000001f08540018
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00001901 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.424802] 501-17000000.gp10b, pid 5329, refs: 2:
[ 7362.429508] channel status: in use idle not busy
[ 7362.434400] RAMFC : TOP: 8000000101000294 PUT: 0000000101000294 GET: 0000000101000294 FETCH: 0000000101000294
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.457858] 502-17000000.gp10b, pid 5329, refs: 2:
[ 7362.462568] channel status: in use idle not busy
[ 7362.467477] RAMFC : TOP: 8000000100c00294 PUT: 0000000100c00294 GET: 0000000100c00294 FETCH: 0000000100c00294
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.490927] 503-17000000.gp10b, pid 5329, refs: 2:
[ 7362.495641] channel status: in use idle not busy
[ 7362.500539] RAMFC : TOP: 8000000100800294 PUT: 0000000100800294 GET: 0000000100800294 FETCH: 0000000100800294
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.524008] 504-17000000.gp10b, pid 5329, refs: 2:
[ 7362.528720] channel status: in use on_eng busy
[ 7362.533438] RAMFC : TOP: 800000010042f238 PUT: 000000010042f238 GET: 000000010042f238 FETCH: 000000010042f238
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000001 03000010 00000000 00001004

[ 7362.556916] 505-17000000.gp10b, pid 1291, refs: 6:
[ 7362.561628] channel status: in use pending busy
[ 7362.566435] RAMFC : TOP: 8000001f0800a9e0 PUT: 0000001f0800a9e0 GET: 0000001f0800a9e0 FETCH: 0000001f0800a9e0
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00001401 SEMAPHORE 0000001e 035a0030 00000001 00001001

[ 7362.589895] 506-17000000.gp10b, pid 887, refs: 2:
[ 7362.594524] channel status: in use idle not busy
[ 7362.599415] RAMFC : TOP: 8000001f081409d8 PUT: 0000001f081409d8 GET: 0000001f081409d8 FETCH: 0000001f081409d8
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00001301 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.622875] 507-17000000.gp10b, pid 887, refs: 8:
[ 7362.627499] channel status: in use pending busy
[ 7362.632307] RAMFC : TOP: 8000001f080258a0 PUT: 0000001f080258a0 GET: 0000001f080258a0 FETCH: 0000001f080258a0
HEADER: 60400000 COUNT: 80000000
SYNCPOINT 00000000 00001201 SEMAPHORE 00000003 fc001000 1880262c 01100002

[ 7362.655788] 508-17000000.gp10b, pid 890, refs: 2:
[ 7362.660414] channel status: in use idle not busy
[ 7362.665308] RAMFC : TOP: 0000000000000000 PUT: 0000000000000000 GET: 0000000000000000 FETCH: 0000000000000000
HEADER: 60400000 COUNT: 00000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.688793] 509-17000000.gp10b, pid 890, refs: 2:
[ 7362.693417] channel status: in use idle not busy
[ 7362.698307] RAMFC : TOP: 0000000000000000 PUT: 0000000000000000 GET: 0000000000000000 FETCH: 0000000000000000
HEADER: 60400000 COUNT: 00000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.721772] 510-17000000.gp10b, pid 890, refs: 2:
[ 7362.726402] channel status: in use idle not busy
[ 7362.731295] RAMFC : TOP: 0000000000000000 PUT: 0000000000000000 GET: 0000000000000000 FETCH: 0000000000000000
HEADER: 60400000 COUNT: 00000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.754761] 511-17000000.gp10b, pid 890, refs: 2:
[ 7362.759384] channel status: in use idle not busy
[ 7362.764279] RAMFC : TOP: 0000000000000000 PUT: 0000000000000000 GET: 0000000000000000 FETCH: 0000000000000000
HEADER: 60400000 COUNT: 00000000
SYNCPOINT 00000000 00000000 SEMAPHORE 00000000 00000000 00000000 00000000

[ 7362.787774] gk20a 17000000.gp10b: gk20a_fifo_handle_mmu_fault: mmu fault on engine 0, engine subid 0 (gpc), client 4 (t1 1), addr 0x00000000:0x00000000, type 0 (pde), info 0x00000400,inst_ptr 0xdc3bb000

[ 7362.813797] gk20a 17000000.gp10b: gk20a_fifo_set_ctx_mmu_error_tsg: TSG 3 generated a mmu fault
[ 7362.822498] gk20a 17000000.gp10b: gk20a_set_error_notifier_locked: error notifier set to 31 for ch 504
[ 7362.831826] gk20a 17000000.gp10b: gk20a_set_error_notifier_locked: error notifier set to 31 for ch 503
[ 7362.841141] gk20a 17000000.gp10b: gk20a_set_error_notifier_locked: error notifier set to 31 for ch 502
[ 7362.850458] gk20a 17000000.gp10b: gk20a_set_error_notifier_locked: error notifier set to 31 for ch 501
[ 7362.859804] gk20a 17000000.gp10b: fifo_error_isr: channel reset initiated from fifo_error_isr; intr=0x10000000
[ 7364.012101] sono_ovxx 2-0036: sono_ovxx_s_stream++
[ 7364.017282] nvcsi 150c0000.nvcsi: Sono:sensor chip OV2740
[ 7364.023044] nvcsi 150c0000.nvcsi: Sono:sensor chip OV2740
[ 7364.030414] sono_ovxx 2-0036: sono_ovxx_power_off: power off

I also use the readelf -a VideoTest. and use the diff tool.

the crosscompile.
Dynamic section at offset 0x54140 contains 52 entries:
Tag Type Name/Value
0x0000000000000001 (NEEDED) Shared library: [libGL.so.1]
0x0000000000000001 (NEEDED) Shared library: [libGLU.so.1]
0x0000000000000001 (NEEDED) Shared library: [libglut.so.3]
0x0000000000000001 (NEEDED) Shared library: [libMyCuda.so]
0x0000000000000001 (NEEDED) Shared library: [libnppi.so.8.0]
0x0000000000000001 (NEEDED) Shared library: [libnpps.so.8.0]
0x0000000000000001 (NEEDED) Shared library: [libnppc.so.8.0]
0x0000000000000001 (NEEDED) Shared library: [libcudart.so.8.0]
0x0000000000000001 (NEEDED) Shared library: [libX11.so.6]
0x0000000000000001 (NEEDED) Shared library: [libXext.so.6]
0x0000000000000001 (NEEDED) Shared library: [libXi.so.6]
0x0000000000000001 (NEEDED) Shared library: [libXxf86vm.so.1]
0x0000000000000001 (NEEDED) Shared library: [libxcb.so.1]
0x0000000000000001 (NEEDED) Shared library: [libXau.so.6]
0x0000000000000001 (NEEDED) Shared library: [libXdmcp.so.6]
0x0000000000000001 (NEEDED) Shared library: [libnvidia-tls.so.28.1.0]
0x0000000000000001 (NEEDED) Shared library: [libnvidia-glcore.so.28.1.0]
0x0000000000000001 (NEEDED) Shared library: [libnvdc.so]
0x0000000000000001 (NEEDED) Shared library: [libnvidia-rmapi-tegra.so.28.1.0]
0x0000000000000001 (NEEDED) Shared library: [libnvimp.so]
0x0000000000000001 (NEEDED) Shared library: [libnvrm.so]
0x0000000000000001 (NEEDED) Shared library: [libnvrm_gpu.so]
0x0000000000000001 (NEEDED) Shared library: [libnvos.so]
0x0000000000000001 (NEEDED) Shared library: [libnvrm_graphics.so]
0x0000000000000001 (NEEDED) Shared library: [libstdc++.so.6]
0x0000000000000001 (NEEDED) Shared library: [libm.so.6]
0x0000000000000001 (NEEDED) Shared library: [libgcc_s.so.1]
0x0000000000000001 (NEEDED) Shared library: [libpthread.so.0]
0x0000000000000001 (NEEDED) Shared library: [libc.so.6]

the tx2 compile.

0x0000000000000001 (NEEDED) Shared library: [libGL.so.1]
0x0000000000000001 (NEEDED) Shared library: [libGLU.so.1]
0x0000000000000001 (NEEDED) Shared library: [libglut.so.3]
0x0000000000000001 (NEEDED) Shared library: [libMyCuda.so]
0x0000000000000001 (NEEDED) Shared library: [libcudart.so.8.0]
0x0000000000000001 (NEEDED) Shared library: [libstdc++.so.6]
0x0000000000000001 (NEEDED) Shared library: [libgcc_s.so.1]
0x0000000000000001 (NEEDED) Shared library: [libpthread.so.0]
0x0000000000000001 (NEEDED) Shared library: [libc.so.6]
0x0000000000000001 (NEEDED) Shared library: [ld-linux-aarch64.so.1]

On the Jetson do you see any errors from “sha1sum -c /etc/nv_tegra_release”? What release is shown from “head -n 1 /etc/nv_tegra_release”?

On your x86_64 host, what was the source of any files linked against (e.g., was it a Linaro sysroot and copy of any needed libraries individually directly from the Jetson, versus an apt-get of Ubuntu aarch64 files)?

Hi linuxdev, thanks for your reply.

Here is the result.

nvidia@tegra-ubuntu:~ sha1sum -c /etc/nv_tegra_release /usr/lib/aarch64-linux-gnu/libv4l/plugins/libv4l2_nvvideocodec.so: OK /usr/lib/aarch64-linux-gnu/libv4l/plugins/libv4l2_nvvidconv.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvomx.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnveglstreamproducer.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtx_helper.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvddk_vic.so: OK /usr/lib/aarch64-linux-gnu/tegra/libglx.so: OK /usr/lib/aarch64-linux-gnu/tegra/libargus_socketserver.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvddk_2d_v2.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvwinsys.so: OK /usr/lib/aarch64-linux-gnu/tegra/libargus.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvjpeg.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvexif.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvdc.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvavp.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtestresults.so: OK /usr/lib/aarch64-linux-gnu/tegra/libargus_socketclient.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm_utils.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvfnet.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvll.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcameratools.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvapputil.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnveglstream_camconsumer.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvrm.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcam_imageencoder.so: OK /usr/lib/aarch64-linux-gnu/tegra/libtegrav4l2.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvparser.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtvmr.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvrm_gpu.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtnr.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcamerautils.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvidia-egl-wayland.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvfnetstoredefog.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvodm_imager.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite_utils.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcolorutil.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite_video.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite_image.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm_contentpipe.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvimp.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvos.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvrm_graphics.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmedia.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvfnetstorehdfx.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvomxilclient.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcamlog.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm_parser.so: OK /usr/lib/aarch64-linux-gnu/tegra/libscf.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvosd.so: OK /usr/lib/xorg/modules/drivers/nvidia_drv.so: OK /usr/lib/xorg/modules/extensions/libglx.so: OK nvidia@tegra-ubuntu:~ head -n 1 /etc/nv_tegra_release

R28 (release), REVISION: 1.0, GCID: 9379712, BOARD: t186ref, EABI: aarch64, DATE: Thu Jul 20 07:59:31 UTC 2017

on our X86-64 hosts.

The libraries: copy of any needed libraries individually directly from the Jetson.
The cross compile tool chain is downloaded from the download centre. gcc-4.8.5-aarch64
the cuda-8.0 is x86-64 , because we need the nvcc, but the target is aarch64(copy from Jetson)

any advise is acceptable .

the problem is fixed by ourselves. the app need a parameter, which need by the cuda code.

we alse build the code in the qemu environment,the same result, thanks all .

One tip for people running into dependency issues. You might run “ldd /which/ever/program” to see what it wants to link to and see if anything shows as missing. You can see what the default library availability is on a system from “ldconfig -p”.