Kernel Oops while capturing video from camera
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 35/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- c, linux
- Domain
- embedded-iot, operating-systems
Research direction
Start with the reproduction commands and the attached raspinfo.txt, especially the dmesg output around the ARM kernel oops. Reproduce video capture with the Pi Zero W and camera, then use the resulting kernel logs to identify the failing subsystem; done means FFmpeg captures video without a kernel crash.
Written by the indexing model from the issue text.
Description
Describe the bug
Sometimes when capturing video from Pi Camera, I get a kernel oops. It's not always the same oops number.
To reproduce
pi@pizero:~ $ v4l2-ctl -p 30
Frame rate set to 30.000 fps
pi@pizero:~ $ ffmpeg -f h264 -i /dev/video0 -c:v copy -an out.mp4 -loglevel debug
ffmpeg version 4.2.2 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 8 (Raspbian 8.3.0-6+rpi1)
configuration: --prefix=/usr/local --enable-omx-rpi --enable-nonfree --enable-gpl --enable-mmal --enable-libx264 --disable-filters
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Splitting the commandline.
Reading option '-f' ... matched as option 'f' (force format) with argument 'h264'.
Reading option '-i' ... matched as input url with argument '/dev/video0'.
Reading option '-c:v' ... matched as option 'c' (codec name) with argument 'copy'.
Reading option '-an' ... matched as option 'an' (disable audio) with argument '1'.
Reading option 'out.mp4' ... matched as output url.
Reading option '-loglevel' ... matched as option 'loglevel' (set logging level) with argument 'debug'.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option loglevel (set logging level) with argument debug.
Successfully parsed a group of options.
Parsing a group of options: input url /dev/video0.
Applying option f (force format) with argument h264.
Successfully parsed a group of options.
Opening an input file: /dev/video0.
[h264 @ 0x1584370] Opening '/dev/video0' for reading
[file @ 0x1584b50] Setting default whitelist 'file,crypto'
[h264 @ 0x1584370] Before avformat_find_stream_info() pos: 0 bytes read:29 seeks:0 nb_streams:1
[AVBSFContext @ 0x15ae2c0] nal_unit_type: 7(SPS), nal_ref_idc: 1
[AVBSFContext @ 0x15ae2c0] nal_unit_type: 8(PPS), nal_ref_idc: 1
[AVBSFContext @ 0x15ae2c0] nal_unit_type: 5(IDR), nal_ref_idc: 1
[h264 @ 0x1585510] nal_unit_type: 7(SPS), nal_ref_idc: 1
[h264 @ 0x1585510] nal_unit_type: 8(PPS), nal_ref_idc: 1
[h264 @ 0x1585510] nal_unit_type: 5(IDR), nal_ref_idc: 1
[h264 @ 0x1585510] Format yuv420p chosen by get_format().
[h264 @ 0x1585510] Reinit context to 1920x1088, pix_fmt: yuv420p
[h264 @ 0x1585510] nal_unit_type: 1(Coded slice of a non-IDR picture), nal_ref_idc: 1
Last message repeated 5 times
Message from syslogd@pizero at Jan 29 01:45:02 ...
kernel:[ 183.693275] Internal error: Oops: 80f [#1] ARM
Expected behaviour
FFmpeg should capture a video
Actual behaviour
FFmpeg crashes and I see lots of kernel errors on screen
System
- PiZeroW with NoIR camera v2
Logs
dmesg included in raspinfo.txt
raspinfo.txt
- Dominant language
- C
- Stars
- 13.2k
- Forks
- 5.5k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 21
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from raspberrypi/linux
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
raspberrypi/linux#7415 · 2 comments · 1 reaction ·
-
rp1-cfe doesn't forward V4L2_EVENT_SOURCE_CHANGE event from csi-2 sensor driver to userspace app Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
raspberrypi/linux#7399 · 1 comment ·
-
Difficulty 1/5 Under an hour Newbie friendliness 82/100
raspberrypi/linux#7357 · 1 comment ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
raspberrypi/linux#7054 · 2 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
raspberrypi/linux#7634 · 8 comments · 1 reaction ·
All issues in raspberrypi/linux
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
zephyrproject-rtos/zephyr#119726 ·
-
[Bounty proposal] fix(web): memory insights count an evening memory on the next day ($25 proposed) Open
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
BasedHardware/omi#15320 ·
-
[adam] AdamNet network read doesn't cap to MAX_ADAM_PACKET_LEN, overflows client receive buffers Open
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
FujiNetWIFI/fujinet-firmware#1649 · 2 comments ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
HarbourMasters/Shipwright#7229 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
riscv-software-src/riscv-isa-sim#2435 · 1 comment ·