Hi Community:
I use MAX9296+MAX96705+ov01f10 in R34.1.1 with orin. My camera output format is YUV422 8bit.
I have done my drivers(even MAX9296 driver, I did’t use the driver by nvidia) and try to capture with command with command:
gst-launch-1.0 v4l2src ! video/x-raw,width=1280,height=720,format=YUY2 ! videoconvert ! video/x-raw,format=I420 ! xvimagesink sync=0
and I got this :
I tried to get yuv frame by:
v4l2-ctl -V --set-fmt-video=width=1280,height=720 --set-ctrl bypass_mode=0 --stream-mmap --stream-count=5 --stream-to=2M_yuyv_dtsi_video.yuv -d /dev/video0
then got kernel error:
3785.084971] bwmgr API not supported
[ 3785.085502] Unable to handle kernel NULL pointer dereference at virtual address 0000000000000000
[ 3785.085872] Mem abort info:
[ 3785.085958] ESR = 0x86000004
[ 3785.086050] EC = 0x21: IABT (current EL), IL = 32 bits
[ 3785.086212] SET = 0, FnV = 0
[ 3785.086302] EA = 0, S1PTW = 0
[ 3785.086394] user pgtable: 4k pages, 48-bit VAs, pgdp=000000019209f000
[ 3785.086593] [0000000000000000] pgd=0000000000000000, p4d=0000000000000000
[ 3785.086799] Internal error: Oops: 86000004 [#1] PREEMPT SMP
[ 3785.086966] Modules linked in: wj_ov01f10 wj_max96705 wj_max9296 fuse nvidia_modeset(O) xt_conntrack xt_MASQUERADE nf_conntrack_netlink nfnetlink xt_addrtype iptable_filter iptable_nat nf_nat nf_conntrack nf_defrag_ipv6 nf_defrag_ipv4 libcrc32c br_netfilter lzo_rle lzo_compress zram overlay bnep loop aes_ce_blk crypto_simd snd_soc_tegra186_asrc cryptd rtk_btusb snd_soc_tegra210_ope snd_soc_tegra186_dspk snd_soc_tegra210_afc snd_soc_tegra210_mvc snd_soc_tegra186_arad aes_ce_cipher snd_soc_tegra210_iqc snd_soc_tegra210_dmic snd_soc_tegra210_admaif btusb snd_soc_tegra210_adx ghash_ce rtl8822ce snd_soc_tegra210_amx snd_soc_tegra210_mixer snd_soc_tegra210_i2s btrtl snd_soc_tegra_pcm sha2_ce snd_soc_tegra210_sfc sha256_arm64 snd_soc_tegra210_adsp btbcm btintel sha1_ce snd_soc_tegra_machine_driver snd_hda_codec_hdmi cfg80211 ofpart snd_soc_tegra_utils ucsi_ccg cmdlinepart snd_hda_tegra snd_soc_spdif_tx snd_soc_simple_card_utils nvgpu pwm_fan typec_ucsi nvadsp snd_hda_codec qspi_mtd nct1008 typec
[ 3785.087043] snd_soc_tegra210_ahub snd_hda_core tegra_bpmp_thermal mtd userspace_alert tegra210_adma spi_tegra114 nvidia(O) binfmt_misc ina3221 ip_tables x_tables
[ 3785.144923] CPU: 4 PID: 4541 Comm: v4l2-ctl Tainted: G O 5.10.65-tegra #14
[ 3785.153320] Hardware name: /, BIOS r34.1-975eef6 05/16/2022
[ 3785.159097] pstate: 00400009 (nzcv daif +PAN -UAO -TCO BTYPE=--)
[ 3785.165135] pc : 0x0
[ 3785.167501] lr : v4l2sd_stream+0xec/0x1e0
[ 3785.171695] sp : ffff800012a039e0
[ 3785.175108] x29: ffff800012a039e0 x28: ffffb636683e8998
[ 3785.180620] x27: ffffb636680f6000 x26: 0000000000001008
[ 3785.186131] x25: ffffb63641ff8000 x24: ffff6bf549624158
[ 3785.191644] x23: ffff6bf5467c4020 x22: ffff6bf549625160
[ 3785.197158] x21: ffff6bf56b918880 x20: ffff6bf555f27480
[ 3785.202670] x19: 0000000000000001 x18: 0000000000000001
[ 3785.208181] x17: 0000000000000000 x16: 0000000000000000
[ 3785.213608] x15: ffffffffffffffff x14: ffffff0000000000
[ 3785.219120] x13: ffffffffffffffff x12: 0000000000000028
[ 3785.224458] x11: 0101010101010101 x10: 7f7f7f7f7f7f7f7f
[ 3785.229882] x9 : 0000000000000000 x8 : ffff6bf549625160
[ 3785.235220] x7 : 0000000000000000 x6 : 000000000000003f
[ 3785.240558] x5 : 0000000000000001 x4 : 0000000000000001
[ 3785.245983] x3 : ffffb63641ff8540 x2 : ffff6bf5741b8000
[ 3785.251320] x1 : 0000000000000000 x0 : ffff6bf56b918880
[ 3785.256657] Call trace:
[ 3785.259108] 0x0
[ 3785.260948] tegra_channel_set_stream+0x538/0x580
[ 3785.265497] vi5_channel_start_streaming+0x1b8/0x320
[ 3785.270309] tegra_channel_start_streaming+0x50/0x80
[ 3785.275122] vb2_start_streaming+0x6c/0x150
[ 3785.279146] vb2_core_streamon+0x98/0x1a0
[ 3785.283346] vb2_streamon+0x30/0x80
[ 3785.286846] vb2_ioctl_streamon+0x54/0x60
[ 3785.290871] v4l_streamon+0x3c/0x50
[ 3785.294545] __video_do_ioctl+0x180/0x3f0
[ 3785.298570] video_usercopy+0x27c/0x730
[ 3785.302333] video_ioctl2+0x3c/0x180
[ 3785.305833] v4l2_ioctl+0x64/0x90
[ 3785.309248] __arm64_sys_ioctl+0xa8/0xf0
[ 3785.313010] el0_svc_common.constprop.0+0x7c/0x1c0
[ 3785.317820] do_el0_svc+0x34/0xa0
[ 3785.321234] el0_svc+0x1c/0x30
[ 3785.324033] el0_sync_handler+0xa8/0xb0
[ 3785.327971] el0_sync+0x16c/0x180
[ 3785.331385] Code: bad PC value
[ 3785.334541] ---[ end trace 655a80b106df5975 ]---
[ 3785.339258] Kernel panic - not syncing: Oops: Fatal exception
[ 3785.345034] SMP: stopping secondary CPUs
[ 3785.349005] Kernel Offset: 0x363656700000 from 0xffff800010000000
[ 3785.354920] PHYS_OFFSET: 0xffff940bc0000000
[ 3785.358946] CPU features: 0x0040006,4a00aa38
[ 3785.363233] Memory Limit: none
[ 3785.370256] ---[ end Kernel panic - not syncing: Oops: Fatal exception ]---
My camera and ser/deser have tested on another platform, they work fine, so registers config should be OK.
I tested with v4l2:
wanji@orin:~$ v4l2-ctl -d0 --list-formats-ext
ioctl: VIDIOC_ENUM_FMT
Type: Video Capture
[0]: 'YVYU' (YVYU 4:2:2)
Size: Discrete 1280x720
Interval: Discrete 0.033s (30.000 fps)
[1]: 'YVYU' (YVYU 4:2:2)
Size: Discrete 1280x720
Interval: Discrete 0.033s (30.000 fps)
wanji@orin:~$ sudo media-ctl -p -d /dev/media0
Media controller API version 5.10.65
Media device information
------------------------
driver tegra-camrtc-ca
model NVIDIA Tegra Video Input Device
serial
bus info
hw revision 0x3
driver version 5.10.65
Device topology
- entity 1: 13e40000.host1x:nvcsi@15a00000- (2 pads, 2 links)
type V4L2 subdev subtype Unknown flags 0
device node name /dev/v4l-subdev0
pad0: Sink
<- "ov01f10 2-0036":0 [ENABLED]
pad1: Source
-> "vi-output, ov01f10 2-0036":0 [ENABLED]
- entity 4: ov01f10 2-0036 (1 pad, 1 link)
type V4L2 subdev subtype Sensor flags 0
device node name /dev/v4l-subdev1
pad0: Source
[fmt:YVYU8_1X16/1280x720 field:none colorspace:srgb]
-> "13e40000.host1x:nvcsi@15a00000-":0 [ENABLED]
- entity 6: vi-output, ov01f10 2-0036 (1 pad, 1 link)
type Node subtype V4L flags 0
device node name /dev/video0
pad0: Sink
<- "13e40000.host1x:nvcsi@15a00000-":1 [ENABLED]
Could someone tell me what should I check?
I have tried to modify bus-width,either 2 or 4 got the same result.
Attach is my device tree and drivers.
wj_max9296.c (6.9 KB)
wj-max96705.c (3.7 KB)
wj-ov01f10.c (12.2 KB)
wanji-camera-TZ026V02.dtsi (4.8 KB)
wanji.dtsi (1.8 KB)