2012-02-05 20:57:21

by Knut Petersen

[permalink] [raw]
Subject: [BUG 3.3-rc2] spinlock trylock failure on UP on CPU#0

Booting 23783f817bceedd6d4e549385e3f400ea64059e5 I get the following trace
an AOpen i915GMm-hfs with Pentium-M Dothan:


[ 12.526390] BUG: spinlock trylock failure on UP on CPU#0, scsi_id/543
[ 12.528009] lock: f4ed8830, .magic: dead4ead, .owner: scsi_id/543, .owner_cpu: 0
[ 12.528009] Pid: 543, comm: scsi_id Not tainted 3.3.0-rc2-main+ #21
[ 12.528009] Call Trace:
[ 12.528009] [<c011dd19>] ? console_unlock+0x1ad/0x1d3
[ 12.528009] [<c043e56d>] spin_dump+0x6c/0x76
[ 12.528009] [<c043e594>] spin_bug+0x1d/0x21
[ 12.528009] [<c027739a>] do_raw_spin_trylock+0x33/0x38
[ 12.528009] [<c04429c2>] _raw_spin_trylock+0x17/0x63
[ 12.528009] [<c025fafa>] put_io_context+0xa1/0x10a
[ 12.528009] [<c0269d85>] __cfq_slice_expired+0x2f6/0x319
[ 12.528009] [<c026a8b2>] cfq_dispatch_requests+0x39/0x714
[ 12.528009] [<c025b328>] elv_drain_elevator+0x3f/0x7d
[ 12.528009] [<c025b3f0>] __elv_add_request+0x8a/0x169
[ 12.528009] [<c02604a4>] blk_execute_rq_nowait+0x88/0xab
[ 12.528009] [<c0260573>] blk_execute_rq+0xac/0xcd
[ 12.528009] [<c02603f4>] ? blk_rq_map_user+0x1b5/0x1b5
[ 12.528009] [<c0260775>] ? blk_recount_segments+0x16/0x24
[ 12.528009] [<c0263cf5>] sg_io+0x23c/0x325
[ 12.528009] [<c02642a3>] scsi_cmd_ioctl+0x1b1/0x332
[ 12.528009] [<c0264452>] scsi_cmd_blk_ioctl+0x2e/0x38
[ 12.528009] [<c035c15e>] sd_ioctl+0xd4/0xf4
[ 12.528009] [<c035c08a>] ? sd_getgeo+0x98/0x98
[ 12.528009] [<c02618ce>] __blkdev_driver_ioctl+0x26/0x2e
[ 12.528009] [<c026226a>] blkdev_ioctl+0x70e/0x728
[ 12.528009] [<c011af95>] ? __kunmap_atomic+0x61/0x78
[ 12.528009] [<c0137f14>] ? get_parent_ip+0xb/0x31
[ 12.528009] [<c04450e4>] ? add_preempt_count+0x98/0x9b
[ 12.528009] [<c01b3f87>] block_ioctl+0x31/0x39
[ 12.528009] [<c01b3f87>] ? block_ioctl+0x31/0x39
[ 12.528009] [<c01b3f56>] ? bd_set_size+0x62/0x62
[ 12.528009] [<c019ebb9>] do_vfs_ioctl+0x47b/0x4af
[ 12.528009] [<c0134c7e>] ? up_read+0x16/0x28
[ 12.528009] [<c0444ea7>] ? do_page_fault+0x3d4/0x402
[ 12.528009] [<c01957a8>] ? sys_fstat64+0x20/0x22
[ 12.528009] [<c019ec2e>] sys_ioctl+0x41/0x63
[ 12.528009] [<c0442c05>] syscall_call+0x7/0xb

cu,
-kp


2012-02-05 22:56:09

by Linus Torvalds

[permalink] [raw]
Subject: Re: [BUG 3.3-rc2] spinlock trylock failure on UP on CPU#0

Ok, interesting. You're triggering the issue because you have a UP
build with the spinlock debugging code enabled.

On Sun, Feb 5, 2012 at 12:57 PM, Knut Petersen
<[email protected]> wrote:
> Booting ?23783f817bceedd6d4e549385e3f400ea64059e5 I get the following trace
> an AOpen i915GMm-hfs with Pentium-M Dothan:

This is probably the same "technically legal" code that LOCKDEP also
is unhappy about - the nested fast path release. We do a trylock on
the queue lock while we already are holding the queue lock
recursively.

Jens, Tejun - the crazy-ass games that this code is playing is clearly
messing not just with lockdep, it's messing with some very reasonable
spinlock sanity checks on UP (which just boil down to "a spinlock
should never have contention on UP")

Any chance of sanitizing this all?

Linus

> [ ? 12.526390] BUG: spinlock trylock failure on UP on CPU#0, scsi_id/543
> [ ? 12.528009] ?lock: f4ed8830, .magic: dead4ead, .owner: scsi_id/543, .owner_cpu: 0
> [ ? 12.528009] Pid: 543, comm: scsi_id Not tainted 3.3.0-rc2-main+ #21
> [ ? 12.528009] Call Trace:
> [ ? 12.528009] ?[<c043e56d>] spin_dump+0x6c/0x76
> [ ? 12.528009] ?[<c043e594>] spin_bug+0x1d/0x21
> [ ? 12.528009] ?[<c027739a>] do_raw_spin_trylock+0x33/0x38
> [ ? 12.528009] ?[<c04429c2>] _raw_spin_trylock+0x17/0x63
> [ ? 12.528009] ?[<c025fafa>] put_io_context+0xa1/0x10a
> [ ? 12.528009] ?[<c0269d85>] __cfq_slice_expired+0x2f6/0x319
> [ ? 12.528009] ?[<c026a8b2>] cfq_dispatch_requests+0x39/0x714
> [ ? 12.528009] ?[<c025b328>] elv_drain_elevator+0x3f/0x7d
> [ ? 12.528009] ?[<c025b3f0>] __elv_add_request+0x8a/0x169
> [ ? 12.528009] ?[<c02604a4>] blk_execute_rq_nowait+0x88/0xab
> [ ? 12.528009] ?[<c0260573>] blk_execute_rq+0xac/0xcd
> [ ? 12.528009] ?[<c0263cf5>] sg_io+0x23c/0x325
> [ ? 12.528009] ?[<c02642a3>] scsi_cmd_ioctl+0x1b1/0x332
> [ ? 12.528009] ?[<c0264452>] scsi_cmd_blk_ioctl+0x2e/0x38
> [ ? 12.528009] ?[<c035c15e>] sd_ioctl+0xd4/0xf4
> [ ? 12.528009] ?[<c02618ce>] __blkdev_driver_ioctl+0x26/0x2e
> [ ? 12.528009] ?[<c026226a>] blkdev_ioctl+0x70e/0x728
> [ ? 12.528009] ?[<c01b3f87>] block_ioctl+0x31/0x39
> [ ? 12.528009] ?[<c019ebb9>] do_vfs_ioctl+0x47b/0x4af
> [ ? 12.528009] ?[<c019ec2e>] sys_ioctl+0x41/0x63
> [ ? 12.528009] ?[<c0442c05>] syscall_call+0x7/0xb
>
> cu,
> ?-kp

2012-02-06 01:25:04

by Shaohua Li

[permalink] [raw]
Subject: Re: [BUG 3.3-rc2] spinlock trylock failure on UP on CPU#0

2012/2/6 Linus Torvalds <[email protected]>:
> Ok, interesting. You're triggering the issue because you have a UP
> build with the spinlock debugging code enabled.
>
> On Sun, Feb 5, 2012 at 12:57 PM, Knut Petersen
> <[email protected]> wrote:
>> Booting ?23783f817bceedd6d4e549385e3f400ea64059e5 I get the following trace
>> an AOpen i915GMm-hfs with Pentium-M Dothan:
>
> This is probably the same "technically legal" code that LOCKDEP also
> is unhappy about - the nested fast path release. We do a trylock on
> the queue lock while we already are holding the queue lock
> recursively.
>
> Jens, Tejun - the crazy-ass games that this code is playing is clearly
> messing not just with lockdep, it's messing with some very reasonable
> spinlock sanity checks on UP (which just boil down to "a spinlock
> should never have contention on UP")
>
> Any chance of sanitizing this all?
I just sent out a debug patch, please try:
http://marc.info/?l=linux-kernel&m=132849146702770&w=2

2012-02-06 07:15:23

by Knut Petersen

[permalink] [raw]
Subject: Re: [BUG 3.3-rc2] spinlock trylock failure on UP on CPU#0

Am 06.02.2012 02:25, schrieb Shaohua Li:
> 2012/2/6 Linus Torvalds<[email protected]>:
>> Jens, Tejun - the crazy-ass games that this code is playing is clearly
>> messing not just with lockdep, it's messing with some very reasonable
>> spinlock sanity checks on UP (which just boil down to "a spinlock
>> should never have contention on UP")
>>
>> Any chance of sanitizing this all?
> I just sent out a debug patch, please try:
> http://marc.info/?l=linux-kernel&m=132849146702770&w=2
>

Your debug patch helps - but with you patch applied another problem is back again:

3.2.1 ... 3.2.4
===========
dvb-s reception with kaffeine works well, but starting kaffeine
triggers a circular locking dependency warning, see:
http://www.gossamer-threads.com/lists/linux/kernel/1487577


3.3-rc2+ (23783f817bceedd6d4e549385e3f400ea64059e5)
===============================================
spinlock trylock failure on UP on CPU#0 warning is triggered during system startup,
dvb-s with kaffeine is broken (only about 1-2 fps, video frames and audio distorted),
the circular locking dependency warning mentioned above is gone.


3.3-rc2+ (23783f817bceedd6d4e549385e3f400ea64059e5) + blk-icq-lock-fix.patch
=================================================================
spinlock trylock failure warning during system startup is gone,
dvb-s reception with kaffeine is still broken,
the circular locking dependency warning is triggered again by kaffeine:

[ 124.314255]
[ 124.314262] ======================================================
[ 124.314270] [ INFO: possible circular locking dependency detected ]
[ 124.314279] 3.3.0-rc2-main+ #22 Not tainted
[ 124.314285] -------------------------------------------------------
[ 124.314293] kaffeine/3743 is trying to acquire lock:
[ 124.314300] (&fe->lock){+.+.+.}, at: [<f85e70cf>] videobuf_dvb_find_frontend+0x16/0x3e [videobuf_dvb]
[ 124.314320]
[ 124.314321] but task is already holding lock:
[ 124.314327] (minor_rwsem#2){++++..}, at: [<f8e430c8>] dvb_device_open+0x24/0x185 [dvb_core]
[ 124.314348]
[ 124.314349] which lock already depends on the new lock.
[ 124.314351]
[ 124.314359]
[ 124.314360] the existing dependency chain (in reverse order) is:
[ 124.314369]
[ 124.314370] -> #2 (minor_rwsem#2){++++..}:
[ 124.314382] [<c0149609>] lock_acquire+0x45/0x5c
[ 124.314394] [<c0441070>] down_write+0x1b/0x36
[ 124.314405] [<f8e43521>] dvb_register_device+0x113/0x1ed [dvb_core]
[ 124.314420] [<f8e4b320>] dvb_register_frontend+0x172/0x19e [dvb_core]
[ 124.314437] [<f85e7266>] videobuf_dvb_register_bus+0xbe/0x2cb [videobuf_dvb]
[ 124.314450] [<f86d0c9e>] cx8802_dvb_probe+0x1eac/0x1f22 [cx88_dvb]
[ 124.314464] [<f857a420>] cx8802_register_driver+0x116/0x1cc [cx8802]
[ 124.314479] [<f8ce701c>] 0xf8ce701c
[ 124.314490] [<c0101070>] do_one_initcall+0x70/0x118
[ 124.314500] [<c01504d1>] sys_init_module+0x12a3/0x1543
[ 124.314510] [<c0442bf5>] syscall_call+0x7/0xb
[ 124.314520]
[ 124.314521] -> #1 (dvbdev_register_lock){+.+.+.}:
[ 124.314532] [<c0149609>] lock_acquire+0x45/0x5c
[ 124.314541] [<c0440b37>] mutex_lock_nested+0x35/0x275
[ 124.314550] [<f8e4342d>] dvb_register_device+0x1f/0x1ed [dvb_core]
[ 124.314564] [<f8e439a5>] dvb_dmxdev_init+0xc0/0xf0 [dvb_core]
[ 124.314577] [<f85e7311>] videobuf_dvb_register_bus+0x169/0x2cb [videobuf_dvb]
[ 124.314589] [<f86d0c9e>] cx8802_dvb_probe+0x1eac/0x1f22 [cx88_dvb]
[ 124.314601] [<f857a420>] cx8802_register_driver+0x116/0x1cc [cx8802]
[ 124.314612] [<f8ce701c>] 0xf8ce701c
[ 124.314620] [<c0101070>] do_one_initcall+0x70/0x118
[ 124.314629] [<c01504d1>] sys_init_module+0x12a3/0x1543
[ 124.314638] [<c0442bf5>] syscall_call+0x7/0xb
[ 124.314647]
[ 124.314648] -> #0 (&fe->lock){+.+.+.}:
[ 124.314658] [<c0148d54>] __lock_acquire+0xd88/0x12b8
[ 124.314667] [<c0149609>] lock_acquire+0x45/0x5c
[ 124.314675] [<c0440b37>] mutex_lock_nested+0x35/0x275
[ 124.314684] [<f85e70cf>] videobuf_dvb_find_frontend+0x16/0x3e [videobuf_dvb]
[ 124.314695] [<f86ced7a>] cx88_dvb_bus_ctrl+0x22/0x9a [cx88_dvb]
[ 124.314707] [<f8e4982f>] dvb_frontend_open+0x14b/0x2ee [dvb_core]
[ 124.314722] [<f8e43173>] dvb_device_open+0xcf/0x185 [dvb_core]
[ 124.314735] [<c0194f15>] chrdev_open+0x14e/0x16c
[ 124.314754] [<c019056b>] __dentry_open+0x193/0x288
[ 124.314768] [<c01913a9>] nameidata_to_filp+0x42/0x50
[ 124.314780] [<c019c89b>] do_last+0x6db/0x6ed
[ 124.314793] [<c019c973>] path_openat+0xa1/0x2c2
[ 124.314805] [<c019cc40>] do_filp_open+0x21/0x5d
[ 124.314818] [<c01914a5>] do_sys_open+0xee/0x167
[ 124.314830] [<c019153d>] sys_open+0x1f/0x27
[ 124.314842] [<c0442bf5>] syscall_call+0x7/0xb
[ 124.314855]
[ 124.314856] other info that might help us debug this:
[ 124.314857]
[ 124.314876] Chain exists of:
[ 124.314877] &fe->lock --> dvbdev_register_lock --> minor_rwsem#2
[ 124.314896]
[ 124.314906] Possible unsafe locking scenario:
[ 124.314908]
[ 124.314921] CPU0 CPU1
[ 124.314931] ---- ----
[ 124.314940] lock(minor_rwsem#2);
[ 124.314951] lock(dvbdev_register_lock);
[ 124.314964] lock(minor_rwsem#2);
[ 124.314977] lock(&fe->lock);
[ 124.314987]
[ 124.314987] *** DEADLOCK ***
[ 124.314989]
[ 124.315007] 2 locks held by kaffeine/3743:
[ 124.315016] #0: (dvbdev_mutex){+.+...}, at: [<f8e430be>] dvb_device_open+0x1a/0x185 [dvb_core]
[ 124.315040] #1: (minor_rwsem#2){++++..}, at: [<f8e430c8>] dvb_device_open+0x24/0x185 [dvb_core]
[ 124.315065]
[ 124.315066] stack backtrace:
[ 124.315080] Pid: 3743, comm: kaffeine Not tainted 3.3.0-rc2-main+ #22
[ 124.315091] Call Trace:
[ 124.315103] [<c011dd19>] ? console_unlock+0x1ad/0x1d3
[ 124.315116] [<c043cfa8>] print_circular_bug+0x215/0x222
[ 124.315129] [<c0148d54>] __lock_acquire+0xd88/0x12b8
[ 124.315141] [<c0103d67>] ? print_context_stack+0x7a/0x8d
[ 124.315153] [<c0103268>] ? dump_trace+0x78/0xa5
[ 124.315165] [<c0149609>] lock_acquire+0x45/0x5c
[ 124.315178] [<f85e70cf>] ? videobuf_dvb_find_frontend+0x16/0x3e [videobuf_dvb]
[ 124.315194] [<f85e70cf>] ? videobuf_dvb_find_frontend+0x16/0x3e [videobuf_dvb]
[ 124.315208] [<c0440b37>] mutex_lock_nested+0x35/0x275
[ 124.315222] [<f85e70cf>] ? videobuf_dvb_find_frontend+0x16/0x3e [videobuf_dvb]
[ 124.315237] [<f85e70cf>] videobuf_dvb_find_frontend+0x16/0x3e [videobuf_dvb]
[ 124.315254] [<f86ced7a>] cx88_dvb_bus_ctrl+0x22/0x9a [cx88_dvb]
[ 124.315273] [<f8e4982f>] dvb_frontend_open+0x14b/0x2ee [dvb_core]
[ 124.315293] [<f8e43173>] dvb_device_open+0xcf/0x185 [dvb_core]
[ 124.315307] [<c0194f15>] chrdev_open+0x14e/0x16c
[ 124.315320] [<c019056b>] __dentry_open+0x193/0x288
[ 124.315333] [<c044502f>] ? sub_preempt_count+0x81/0x8e
[ 124.315345] [<c01913a9>] nameidata_to_filp+0x42/0x50
[ 124.315357] [<c0194dc7>] ? cdev_put+0x1a/0x1a
[ 124.315369] [<c019c89b>] do_last+0x6db/0x6ed
[ 124.315381] [<c019c973>] path_openat+0xa1/0x2c2
[ 124.315393] [<c019cc40>] do_filp_open+0x21/0x5d
[ 124.315406] [<c044502f>] ? sub_preempt_count+0x81/0x8e
[ 124.315418] [<c04428ba>] ? _raw_spin_unlock+0x27/0x3d
[ 124.315432] [<c01a5a8f>] ? alloc_fd+0xb3/0xbe
[ 124.315444] [<c01914a5>] do_sys_open+0xee/0x167
[ 124.315456] [<c019153d>] sys_open+0x1f/0x27
[ 124.315468] [<c0442bf5>] syscall_call+0x7/0xb
[ 124.315480] [<c0440000>] ? schedule_timeout_interruptible+0x8/0x16

Software
=======
openSuSE 12.1, Tumbleweed
X.Org X Server 1.11.99.902 (1.12.0 RC 2), current git master
Kaffeine: 1.2.2 (Qt: 4.7.4, KDE: 4.7.2 (4.7.2) "release 5")

Hardware
========
AOpen i915GMm-hfs, Pentium-M Dothan (2GHz), 2GB RAM**
Hauppauge WinTV Nova-HD-S2

cu,
knut

2012-02-06 07:15:38

by Shaohua Li

[permalink] [raw]
Subject: Re: [BUG 3.3-rc2] spinlock trylock failure on UP on CPU#0

On Mon, 2012-02-06 at 08:11 +0100, Knut Petersen wrote:
> Am 06.02.2012 02:25, schrieb Shaohua Li:
> > 2012/2/6 Linus Torvalds <[email protected]>:
> > > Jens, Tejun - the crazy-ass games that this code is playing is clearly
> > > messing not just with lockdep, it's messing with some very reasonable
> > > spinlock sanity checks on UP (which just boil down to "a spinlock
> > > should never have contention on UP")
> > >
> > > Any chance of sanitizing this all?
> > I just sent out a debug patch, please try:
> > http://marc.info/?l=linux-kernel&m=132849146702770&w=2
> >
>
> Your debug patch helps - but with you patch applied another problem is
> back again:
Looks not related to the original block issue. please report it to DVB
guys.

Thanks,
Shaohua

> 3.2.1 ... 3.2.4
> ===========
> dvb-s reception with kaffeine works well, but starting kaffeine
> triggers a circular locking dependency warning, see:
> http://www.gossamer-threads.com/lists/linux/kernel/1487577
>
>
> 3.3-rc2+ (23783f817bceedd6d4e549385e3f400ea64059e5)
> ===============================================
> spinlock trylock failure on UP on CPU#0 warning is triggered during
> system startup,
> dvb-s with kaffeine is broken (only about 1-2 fps, video frames and
> audio distorted),
> the circular locking dependency warning mentioned above is gone.
>
>
> 3.3-rc2+ (23783f817bceedd6d4e549385e3f400ea64059e5) +
> blk-icq-lock-fix.patch
> =================================================================
> spinlock trylock failure warning during system startup is gone,
> dvb-s reception with kaffeine is still broken,
> the circular locking dependency warning is triggered again by
> kaffeine:
>
> [ 124.314255]
> [ 124.314262] ======================================================
> [ 124.314270] [ INFO: possible circular locking dependency detected ]
> [ 124.314279] 3.3.0-rc2-main+ #22 Not tainted
> [ 124.314285] -------------------------------------------------------
> [ 124.314293] kaffeine/3743 is trying to acquire lock:
> [ 124.314300] (&fe->lock){+.+.+.}, at: [<f85e70cf>]
> videobuf_dvb_find_frontend+0x16/0x3e [videobuf_dvb]
> [ 124.314320]
> [ 124.314321] but task is already holding lock:
> [ 124.314327] (minor_rwsem#2){++++..}, at: [<f8e430c8>]
> dvb_device_open+0x24/0x185 [dvb_core]
> [ 124.314348]
> [ 124.314349] which lock already depends on the new lock.
> [ 124.314351]
> [ 124.314359]
> [ 124.314360] the existing dependency chain (in reverse order) is:
> [ 124.314369]
> [ 124.314370] -> #2 (minor_rwsem#2){++++..}:
> [ 124.314382] [<c0149609>] lock_acquire+0x45/0x5c
> [ 124.314394] [<c0441070>] down_write+0x1b/0x36
> [ 124.314405] [<f8e43521>] dvb_register_device+0x113/0x1ed
> [dvb_core]
> [ 124.314420] [<f8e4b320>] dvb_register_frontend+0x172/0x19e
> [dvb_core]
> [ 124.314437] [<f85e7266>] videobuf_dvb_register_bus
> +0xbe/0x2cb [videobuf_dvb]
> [ 124.314450] [<f86d0c9e>] cx8802_dvb_probe+0x1eac/0x1f22
> [cx88_dvb]
> [ 124.314464] [<f857a420>] cx8802_register_driver+0x116/0x1cc
> [cx8802]
> [ 124.314479] [<f8ce701c>] 0xf8ce701c
> [ 124.314490] [<c0101070>] do_one_initcall+0x70/0x118
> [ 124.314500] [<c01504d1>] sys_init_module+0x12a3/0x1543
> [ 124.314510] [<c0442bf5>] syscall_call+0x7/0xb
> [ 124.314520]
> [ 124.314521] -> #1 (dvbdev_register_lock){+.+.+.}:
> [ 124.314532] [<c0149609>] lock_acquire+0x45/0x5c
> [ 124.314541] [<c0440b37>] mutex_lock_nested+0x35/0x275
> [ 124.314550] [<f8e4342d>] dvb_register_device+0x1f/0x1ed
> [dvb_core]
> [ 124.314564] [<f8e439a5>] dvb_dmxdev_init+0xc0/0xf0
> [dvb_core]
> [ 124.314577] [<f85e7311>] videobuf_dvb_register_bus
> +0x169/0x2cb [videobuf_dvb]
> [ 124.314589] [<f86d0c9e>] cx8802_dvb_probe+0x1eac/0x1f22
> [cx88_dvb]
> [ 124.314601] [<f857a420>] cx8802_register_driver+0x116/0x1cc
> [cx8802]
> [ 124.314612] [<f8ce701c>] 0xf8ce701c
> [ 124.314620] [<c0101070>] do_one_initcall+0x70/0x118
> [ 124.314629] [<c01504d1>] sys_init_module+0x12a3/0x1543
> [ 124.314638] [<c0442bf5>] syscall_call+0x7/0xb
> [ 124.314647]
> [ 124.314648] -> #0 (&fe->lock){+.+.+.}:
> [ 124.314658] [<c0148d54>] __lock_acquire+0xd88/0x12b8
> [ 124.314667] [<c0149609>] lock_acquire+0x45/0x5c
> [ 124.314675] [<c0440b37>] mutex_lock_nested+0x35/0x275
> [ 124.314684] [<f85e70cf>] videobuf_dvb_find_frontend
> +0x16/0x3e [videobuf_dvb]
> [ 124.314695] [<f86ced7a>] cx88_dvb_bus_ctrl+0x22/0x9a
> [cx88_dvb]
> [ 124.314707] [<f8e4982f>] dvb_frontend_open+0x14b/0x2ee
> [dvb_core]
> [ 124.314722] [<f8e43173>] dvb_device_open+0xcf/0x185
> [dvb_core]
> [ 124.314735] [<c0194f15>] chrdev_open+0x14e/0x16c
> [ 124.314754] [<c019056b>] __dentry_open+0x193/0x288
> [ 124.314768] [<c01913a9>] nameidata_to_filp+0x42/0x50
> [ 124.314780] [<c019c89b>] do_last+0x6db/0x6ed
> [ 124.314793] [<c019c973>] path_openat+0xa1/0x2c2
> [ 124.314805] [<c019cc40>] do_filp_open+0x21/0x5d
> [ 124.314818] [<c01914a5>] do_sys_open+0xee/0x167
> [ 124.314830] [<c019153d>] sys_open+0x1f/0x27
> [ 124.314842] [<c0442bf5>] syscall_call+0x7/0xb
> [ 124.314855]
> [ 124.314856] other info that might help us debug this:
> [ 124.314857]
> [ 124.314876] Chain exists of:
> [ 124.314877] &fe->lock --> dvbdev_register_lock --> minor_rwsem#2
> [ 124.314896]
> [ 124.314906] Possible unsafe locking scenario:
> [ 124.314908]
> [ 124.314921] CPU0 CPU1
> [ 124.314931] ---- ----
> [ 124.314940] lock(minor_rwsem#2);
> [ 124.314951]
> lock(dvbdev_register_lock);
> [ 124.314964] lock(minor_rwsem#2);
> [ 124.314977] lock(&fe->lock);
> [ 124.314987]
> [ 124.314987] *** DEADLOCK ***
> [ 124.314989]
> [ 124.315007] 2 locks held by kaffeine/3743:
> [ 124.315016] #0: (dvbdev_mutex){+.+...}, at: [<f8e430be>]
> dvb_device_open+0x1a/0x185 [dvb_core]
> [ 124.315040] #1: (minor_rwsem#2){++++..}, at: [<f8e430c8>]
> dvb_device_open+0x24/0x185 [dvb_core]
> [ 124.315065]
> [ 124.315066] stack backtrace:
> [ 124.315080] Pid: 3743, comm: kaffeine Not tainted 3.3.0-rc2-main+
> #22
> [ 124.315091] Call Trace:
> [ 124.315103] [<c011dd19>] ? console_unlock+0x1ad/0x1d3
> [ 124.315116] [<c043cfa8>] print_circular_bug+0x215/0x222
> [ 124.315129] [<c0148d54>] __lock_acquire+0xd88/0x12b8
> [ 124.315141] [<c0103d67>] ? print_context_stack+0x7a/0x8d
> [ 124.315153] [<c0103268>] ? dump_trace+0x78/0xa5
> [ 124.315165] [<c0149609>] lock_acquire+0x45/0x5c
> [ 124.315178] [<f85e70cf>] ? videobuf_dvb_find_frontend+0x16/0x3e
> [videobuf_dvb]
> [ 124.315194] [<f85e70cf>] ? videobuf_dvb_find_frontend+0x16/0x3e
> [videobuf_dvb]
> [ 124.315208] [<c0440b37>] mutex_lock_nested+0x35/0x275
> [ 124.315222] [<f85e70cf>] ? videobuf_dvb_find_frontend+0x16/0x3e
> [videobuf_dvb]
> [ 124.315237] [<f85e70cf>] videobuf_dvb_find_frontend+0x16/0x3e
> [videobuf_dvb]
> [ 124.315254] [<f86ced7a>] cx88_dvb_bus_ctrl+0x22/0x9a [cx88_dvb]
> [ 124.315273] [<f8e4982f>] dvb_frontend_open+0x14b/0x2ee [dvb_core]
> [ 124.315293] [<f8e43173>] dvb_device_open+0xcf/0x185 [dvb_core]
> [ 124.315307] [<c0194f15>] chrdev_open+0x14e/0x16c
> [ 124.315320] [<c019056b>] __dentry_open+0x193/0x288
> [ 124.315333] [<c044502f>] ? sub_preempt_count+0x81/0x8e
> [ 124.315345] [<c01913a9>] nameidata_to_filp+0x42/0x50
> [ 124.315357] [<c0194dc7>] ? cdev_put+0x1a/0x1a
> [ 124.315369] [<c019c89b>] do_last+0x6db/0x6ed
> [ 124.315381] [<c019c973>] path_openat+0xa1/0x2c2
> [ 124.315393] [<c019cc40>] do_filp_open+0x21/0x5d
> [ 124.315406] [<c044502f>] ? sub_preempt_count+0x81/0x8e
> [ 124.315418] [<c04428ba>] ? _raw_spin_unlock+0x27/0x3d
> [ 124.315432] [<c01a5a8f>] ? alloc_fd+0xb3/0xbe
> [ 124.315444] [<c01914a5>] do_sys_open+0xee/0x167
> [ 124.315456] [<c019153d>] sys_open+0x1f/0x27
> [ 124.315468] [<c0442bf5>] syscall_call+0x7/0xb
> [ 124.315480] [<c0440000>] ? schedule_timeout_interruptible+0x8/0x16
>
> Software
> =======
> openSuSE 12.1, Tumbleweed
> X.Org X Server 1.11.99.902 (1.12.0 RC 2), current git master
> Kaffeine: 1.2.2 (Qt: 4.7.4, KDE: 4.7.2 (4.7.2) "release 5")
>
> Hardware
> ========
> AOpen i915GMm-hfs, Pentium-M Dothan (2GHz), 2GB RAM
> Hauppauge WinTV Nova-HD-S2
>
> cu,
> knut