Bug 5339

Summary: ps ax crash after kdetv-bug
Product: v4l-dvb Reporter: Sveinung Kvilhaugsvik (sveinung)
Component: dvb-otherAssignee: Mauro Carvalho Chehab (mchehab)
Status: REJECTED INSUFFICIENT_DATA    
Severity: normal CC: diegocg, mchehab, protasnb
Priority: P2    
Hardware: i386   
OS: Linux   
Kernel Version: 2.6.23 Subsystem:
Regression: --- Bisected commit-id:

Description Sveinung Kvilhaugsvik 2005-09-30 14:14:30 UTC
Most recent kernel where this bug did not occur: unsure, mabe 2.6.12
Distribution: Gentoo
Hardware Environment: x86, tvcard: pv951 (V4L number 42, tuner 8)
Software Environment: gcc-3.3.6-hardened-nopiessp, GNU, Xorg, KDE
Problem Description: Sometimes KDEtv running as a unprivileged user crashes in
sutch a way that ps ax will hang.

Steps to reproduce: Whatch TV using KDEtv, to be root is not needed. Switch
between fullscreen and a window, between X and the terminals (using
ctrl-alt-f[something]), and between channels, all randomly combined. This will
make the crash more likely.
Comment 1 Sveinung Kvilhaugsvik 2005-09-30 16:12:09 UTC
w will also crash, when the bug is active.
Comment 2 Zwane Mwaikambo 2005-10-30 23:39:19 UTC
Would it be possible for you to capture the crash/oops output via screenshot or
serial console?
Comment 3 Sveinung Kvilhaugsvik 2005-10-31 11:01:10 UTC
All that happens is that the program (ps or w) freezes in the middle of
printing. There is no message. It just stops in the middle, and becomes
unkillable using eiather ctrl+c or kill -9 processid. (Other consolls and the
rest of the system works fine)
Comment 4 Diego Calleja 2006-07-30 10:45:54 UTC
Doesn't the dmesg has some oops? ps and w maybe be crashing while trying to scan
the /proc directory of a task that has oopsed somewhere, so the real bug should
be the oopsing task
Comment 5 Philipp Groeschler 2008-01-29 01:58:22 UTC
Please view

  http://lkml.org/lkml/2007/9/9/138
  http://bugs.kde.org/show_bug.cgi?id=148119
  http://forums.gentoo.org/viewtopic.php?t=629024

for a lot more information on this issue. Serveral call traces available. According to the message from the LKML it seems to be a possible kernel deadlock in the videobuf code, triggered by accessing it through different threads from the same application. At this time, only KDETV is known to do so.

The problem PERSISTS on recent kernel versions, as far as I can tell up to 2.6.23

Who is going to care about this? Some comments would be rather appreciated.
Comment 6 Natalie Protasevich 2008-03-15 00:03:32 UTC
It looks like the bug is still present. Copying to Mauro, it seems to implicate bttv driver every time.
Comment 7 Mauro Carvalho Chehab 2008-03-18 06:35:36 UTC
There were several changes on videobuf code and its lock handing. Those changes are at the latest 2.6.25-rc. There are also some other programmed fixes.

Could you please test the latest v4l-dvb development tree, available at:
    http://linuxtv.org/hg/v4l-dvb