public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Lockdep warning
@ 2013-12-19 13:36 Jonas Bonn
  2013-12-19 14:02 ` Borislav Petkov
  0 siblings, 1 reply; 13+ messages in thread
From: Jonas Bonn @ 2013-12-19 13:36 UTC (permalink / raw)
  To: linux-kernel@vger.kernel.org, netdev

Hi,

Here's a lockdep warning that I'm seeing on an MX28 with 3.13-rc4.  This 
seems to happen as soon as the network link comes up... including the 
'netdev' list here as the backtrace shows the FEC driver in the stacktrace.

Any advice on how to proceed to track this down appreciated...

/Jonas

[   37.140857] fec 800f0000.ethernet eth0: Freescale FEC PHY driver 
[Generic PHY] (mii_bus:phy_addr=800f0000.etherne:00, irq=-1)
[   37.148951] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   39.155538] libphy: 800f0000.etherne:00 - Link is Up - 100/Full
[   39.162273] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready
[   41.167998]
[   41.169546] =================================
[   41.173925] [ INFO: inconsistent lock state ]
[   41.178308] 3.13.0-rc4-00018-g3b78c2f-dirty #8 Not tainted
[   41.183808] ---------------------------------
[   41.188182] inconsistent {SOFTIRQ-ON-W} -> {IN-SOFTIRQ-W} usage.
[   41.194213] connmand/337 [HC0[0]:SC1[1]:HE1:SE0] takes:
[   41.199452]  (&(&sk->sk_dst_lock)->rlock){+.?...}, at: [<c03d8088>] 
__udp4_lib_rcv+0x7e0/0x8a8
[   41.208175] {SOFTIRQ-ON-W} state was registered at:
[   41.213071]   [<c0046cb8>] __lock_acquire+0x5d0/0x1a64
[   41.218274]   [<c0048694>] lock_acquire+0x9c/0x104
[   41.223115]   [<c046a690>] _raw_spin_lock+0x28/0x38
[   41.228052]   [<c042be50>] ip6_datagram_connect+0x258/0x43c
[   41.233669]   [<c03e0478>] inet_dgram_connect+0x58/0x84
[   41.238945]   [<c0376c7c>] SyS_connect+0x64/0x8c
[   41.243610]   [<c0009560>] ret_fast_syscall+0x0/0x44
[   41.248629] irq event stamp: 70302
[   41.252050] hardirqs last  enabled at (70302): [<c0057c98>] 
__getnstimeofday+0x15c/0x178
[   41.260193] hardirqs last disabled at (70301): [<c0057b64>] 
__getnstimeofday+0x28/0x178
[   41.268243] softirqs last  enabled at (70208): [<c001a158>] 
__do_softirq+0x198/0x2c4
[   41.276049] softirqs last disabled at (70217): [<c001a640>] 
irq_exit+0xa4/0xf8
[   41.283309]
[   41.283309] other info that might help us debug this:
[   41.289856]  Possible unsafe locking scenario:
[   41.289856]
[   41.295793]        CPU0
[   41.298250]        ----
[   41.300706]   lock(&(&sk->sk_dst_lock)->rlock);
[   41.305277]   <Interrupt>
[   41.307908]     lock(&(&sk->sk_dst_lock)->rlock);
[   41.312652]
[   41.312652]  *** DEADLOCK ***
[   41.312652]
[   41.318605] 2 locks held by connmand/337:
[   41.322628]  #0:  (rcu_read_lock){.+.+..}, at: [<c0386648>] 
__netif_receive_skb_core+0x34/0x5e0
[   41.331445]  #1:  (rcu_read_lock){.+.+..}, at: [<c03abf80>] 
ip_local_deliver+0x5c/0x30c
[   41.339559]
[   41.339559] stack backtrace:
[   41.343959] CPU: 0 PID: 337 Comm: connmand Not tainted 
3.13.0-rc4-00018-g3b78c2f-dirty #8
[   41.352208] [<c000d970>] (unwind_backtrace+0x0/0xf0) from 
[<c000bd84>] (show_stack+0x10/0x14)
[   41.360797] [<c000bd84>] (show_stack+0x10/0x14) from [<c0463cb4>] 
(print_usage_bug.part.27+0x218/0x280)
[   41.370251] [<c0463cb4>] (print_usage_bug.part.27+0x218/0x280) from 
[<c0046308>] (mark_lock+0x288/0x668)
[   41.379784] [<c0046308>] (mark_lock+0x288/0x668) from [<c0046c80>] 
(__lock_acquire+0x598/0x1a64)
[   41.388620] [<c0046c80>] (__lock_acquire+0x598/0x1a64) from 
[<c0048694>] (lock_acquire+0x9c/0x104)
[   41.397639] [<c0048694>] (lock_acquire+0x9c/0x104) from [<c046a690>] 
(_raw_spin_lock+0x28/0x38)
[   41.406390] [<c046a690>] (_raw_spin_lock+0x28/0x38) from [<c03d8088>] 
(__udp4_lib_rcv+0x7e0/0x8a8)
[   41.415399] [<c03d8088>] (__udp4_lib_rcv+0x7e0/0x8a8) from 
[<c03abfec>] (ip_local_deliver+0xc8/0x30c)
[   41.424667] [<c03abfec>] (ip_local_deliver+0xc8/0x30c) from 
[<c03ac58c>] (ip_rcv+0x35c/0x74c)
[   41.433247] [<c03ac58c>] (ip_rcv+0x35c/0x74c) from [<c03868ec>] 
(__netif_receive_skb_core+0x2d8/0x5e0)
[   41.442611] [<c03868ec>] (__netif_receive_skb_core+0x2d8/0x5e0) from 
[<c03894ac>] (napi_gro_receive+0x74/0xa0)
[   41.452675] [<c03894ac>] (napi_gro_receive+0x74/0xa0) from 
[<c02d5f50>] (fec_enet_rx_napi+0x304/0x704)
[   41.462037] [<c02d5f50>] (fec_enet_rx_napi+0x304/0x704) from 
[<c038918c>] (net_rx_action+0xc0/0x20c)
[   41.471235] [<c038918c>] (net_rx_action+0xc0/0x20c) from [<c001a0ac>] 
(__do_softirq+0xec/0x2c4)
[   41.479987] [<c001a0ac>] (__do_softirq+0xec/0x2c4) from [<c001a640>] 
(irq_exit+0xa4/0xf8)
[   41.488208] [<c001a640>] (irq_exit+0xa4/0xf8) from [<c0009e44>] 
(handle_IRQ+0x34/0x84)
[   41.496172] [<c0009e44>] (handle_IRQ+0x34/0x84) from [<c000c9c4>] 
(__irq_usr+0x44/0x60)

^ permalink raw reply	[flat|nested] 13+ messages in thread
* Lockdep warning
@ 2011-08-26 17:29 Larry Finger
  2011-08-26 20:18 ` Shaun Ruffell
  0 siblings, 1 reply; 13+ messages in thread
From: Larry Finger @ 2011-08-26 17:29 UTC (permalink / raw)
  To: LKML

With a new version of the staging driver rtl8192e, I'm getting the lockdep 
warning posted below. The lock in question is for a timer that uses init_timer() 
for initialization. From the definition of that macro, I thought this was 
initialized with a lock_class_key that should prevent this warning. Obviously, 
I'm missing something.

Any pointers would be appreciated.

Thanks,

Larry


[   88.048077] =============================================
[   88.048086] [ INFO: possible recursive locking detected ]
[   88.048093] 3.1.0-rc3-staging+ #5
[   88.048097] ---------------------------------------------
[   88.048102] kmemleak/631 is trying to acquire lock:
[   88.048108]  (ptimer){+.-...}, at: [<ffffffff81059370>] del_timer_sync+0x0/0xc0
[   88.048124]
[   88.048125] but task is already holding lock:
[   88.048131]  (ptimer){+.-...}, at: [<ffffffff81058e54>] 
run_timer_softirq+0x124/0x400
[   88.048142]
[   88.048143] other info that might help us debug this:
[   88.048149]  Possible unsafe locking scenario:
[   88.048150]
[   88.048156]        CPU0
[   88.048159]        ----
[   88.048162]   lock(ptimer);
[   88.048167]   lock(ptimer);
[   88.048172]
[   88.048173]  *** DEADLOCK ***
[   88.048174]
[   88.048179]  May be due to missing lock nesting notation
[   88.048180]
[   88.048187] 2 locks held by kmemleak/631:
[   88.048191]  #0:  (scan_mutex){+.+...}, at: [<ffffffff81122e76>] 
kmemleak_scan_thread+0x56/0xd0
[   88.048206]  #1:  (ptimer){+.-...}, at: [<ffffffff81058e54>] 
run_timer_softirq+0x124/0x400
[   88.048218]
[   88.048219] stack backtrace:
[   88.048225] Pid: 631, comm: kmemleak Tainted: G         C  3.1.0-rc3-staging+ #5
[   88.048232] Call Trace:
[   88.048236]  <IRQ>  [<ffffffff81083cbb>] __lock_acquire+0x119b/0x1ea0
[   88.048254]  [<ffffffff81084fa5>] lock_acquire+0x95/0x120
[   88.048263]  [<ffffffff81059370>] ? process_timeout+0x10/0x10
[   88.048272]  [<ffffffff810593ac>] del_timer_sync+0x3c/0xc0
[   88.048280]  [<ffffffff81059370>] ? process_timeout+0x10/0x10
[   88.048289]  [<ffffffff81058e54>] ? run_timer_softirq+0x124/0x400
[   88.048316]  [<ffffffffa008d1ee>] TsInitAddBA+0x6e/0x170 [r8192e_pci]
[   88.048332]  [<ffffffffa008b4b3>] TsAddBaProcess+0x33/0x50 [r8192e_pci]
[   88.048341]  [<ffffffff81058edb>] run_timer_softirq+0x1ab/0x400
[   88.048350]  [<ffffffff81058e54>] ? run_timer_softirq+0x124/0x400
[   88.048364]  [<ffffffffa008b480>] ? RxPktPendingTimeout+0x2d0/0x2d0 [r8192e_pci]
[   88.048377]  [<ffffffff810502ad>] __do_softirq+0xbd/0x210
[   88.048386]  [<ffffffff810714d7>] ? hrtimer_interrupt+0x137/0x240
[   88.048396]  [<ffffffff8137176c>] call_softirq+0x1c/0x30
[   88.048406]  [<ffffffff810048c5>] do_softirq+0x85/0xc0
[   88.048414]  [<ffffffff81050686>] irq_exit+0x96/0xc0
[   88.048422]  [<ffffffff8101e4e9>] smp_apic_timer_interrupt+0x69/0xa0
[   88.048431]  [<ffffffff8136fff0>] apic_timer_interrupt+0x70/0x80
[   88.048438]  <EOI>  [<ffffffff8136ea4d>] ? _raw_spin_unlock_irqrestore+0x3d/0x70
[   88.048452]  [<ffffffff81122315>] scan_gray_list+0x155/0x170
[   88.048460]  [<ffffffff8112262b>] kmemleak_scan+0x2fb/0x6e0
[   88.048468]  [<ffffffff81122330>] ? scan_gray_list+0x170/0x170
[   88.048477]  [<ffffffff81122e20>] ? kmemleak_write+0x390/0x390
[   88.048485]  [<ffffffff81122e20>] ? kmemleak_write+0x390/0x390
[   88.048494]  [<ffffffff81122e7b>] kmemleak_scan_thread+0x5b/0xd0
[   88.048502]  [<ffffffff81122e20>] ? kmemleak_write+0x390/0x390
[   88.048510]  [<ffffffff8106c8e6>] kthread+0x96/0xa0
[   88.048519]  [<ffffffff81371674>] kernel_thread_helper+0x4/0x10
[   88.048527]  [<ffffffff8136ed9d>] ? retint_restore_args+0xe/0xe
[   88.048536]  [<ffffffff8106c850>] ? __init_kthread_worker+0x70/0x70
[   88.048544]  [<ffffffff81371670>] ? gs_change+0xb/0xb

^ permalink raw reply	[flat|nested] 13+ messages in thread
* Lockdep warning
@ 2008-03-06 12:14 Szekeres István
  0 siblings, 0 replies; 13+ messages in thread
From: Szekeres István @ 2008-03-06 12:14 UTC (permalink / raw)
  To: linux-kernel; +Cc: a.p.zijlstra, mingo

Found this on my computer after an uptime of 7 days. I don't know if
it is harmless or not. "dirty" is only because of an uncommitted HID
input quirk entry.
Config is available if needed.


------------[ cut here ]------------
WARNING: at kernel/lockdep.c:2662 check_flags+0x13b/0x160()
Modules linked in: tsl2550 pcf8591 pcf8575 pcf8574 max6875 eeprom
ds1682 i2c_via i2c_algo_bit i2c_dev nls_iso8859_1 nls_cp437 vfat fat
nls_base sg sd_mod usb_storage libusual usbhid rfcomm l2cap bluetooth
video output sbs sbshc container dock backlight ac battery joydev
evdev 8250_pnp 8250 serial_core psmouse rtc serio_raw pcspkr
snd_via82xx snd_ac97_codec ac97_bus snd_pcm snd_page_alloc
snd_mpu401_uart snd_seq_midi snd_rawmidi snd_seq_midi_event snd_seq
snd_timer snd_seq_device snd soundcore i2c_viapro i2c_core hid button
floppy ehci_hcd uhci_hcd usbcore dm_mirror dm_snapshot dm_mod unix
thermal processor fan fuse [last unloaded: usbhid]
Pid: 24638, comm: totem Not tainted 2.6.25-rc3pista-00081-g7704a8b-dirty #14
 [warn_on_slowpath+84/112] warn_on_slowpath+0x54/0x70
 [native_calculate_cpu_khz+240/352] ? native_calculate_cpu_khz+0xf0/0x160
 [unqueue_me+63/128] ? unqueue_me+0x3f/0x80
 [_spin_unlock+39/80] ? _spin_unlock+0x27/0x50
 [unqueue_me+71/128] ? unqueue_me+0x47/0x80
 [futex_wait+566/768] ? futex_wait+0x236/0x300
 [check_flags+315/352] check_flags+0x13b/0x160
 [lock_acquire+65/160] lock_acquire+0x41/0xa0
 [down_read+61/128] down_read+0x3d/0x80
 [futex_wake+46/240] ? futex_wake+0x2e/0xf0
 [futex_wake+46/240] futex_wake+0x2e/0xf0
 [do_futex+163/2688] do_futex+0xa3/0xa80
 [do_notify_resume+97/1968] ? do_notify_resume+0x61/0x7b0
 [sysenter_past_esp+157/165] ? sysenter_past_esp+0x9d/0xa5
 [search_exception_tables+23/48] ? search_exception_tables+0x17/0x30
 [fixup_exception+14/48] ? fixup_exception+0xe/0x30
 [do_general_protection+343/656] ? do_general_protection+0x157/0x290
 [ktime_get_ts+59/64] ? ktime_get_ts+0x3b/0x40
 [ktime_get+17/48] ? ktime_get+0x11/0x30
 [sys_futex+138/240] sys_futex+0x8a/0xf0
 [sysenter_past_esp+95/165] sysenter_past_esp+0x5f/0xa5
 =======================
---[ end trace cf60772f91bc8ecf ]---
possible reason: unannotated irqs-on.
irq event stamp: 21512
hardirqs last  enabled at (21511): [sysenter_past_esp+154/165]
sysenter_past_esp+0x9a/0xa5

^ permalink raw reply	[flat|nested] 13+ messages in thread
* lockdep warning
@ 2008-02-22 10:40 Anders Eriksson
  2008-02-22 11:16 ` Jiri Kosina
  0 siblings, 1 reply; 13+ messages in thread
From: Anders Eriksson @ 2008-02-22 10:40 UTC (permalink / raw)
  To: linux-kernel


I found this is a newly booted 2.6.25-rc2's syslog.

Feb 21 20:46:33 tippex BUG: rwlock wrong owner on CPU#0, runscript.sh/2633, d2c04084
Feb 21 20:46:33 tippex Pid: 2633, comm: runscript.sh Not tainted 2.6.25-rc2 #3
Feb 21 20:46:33 tippex [<c02342d0>] rwlock_bug+0x50/0x60
Feb 21 20:46:33 tippex [<c0234356>] _raw_write_unlock+0x56/0x60
Feb 21 20:46:33 tippex [<c040365d>] _write_unlock+0x1d/0x50
Feb 21 20:46:33 tippex [<c03289be>] neigh_timer_handler+0x18e/0x2d0
Feb 21 20:46:33 tippex [<c0125449>] run_timer_softirq+0x119/0x180
Feb 21 20:46:33 tippex [<c013856d>] ? lock_release_holdtime+0x5d/0x80
Feb 21 20:46:33 tippex [<c0328830>] ? neigh_timer_handler+0x0/0x2d0
Feb 21 20:46:33 tippex [<c0121a64>] __do_softirq+0x54/0xb0
Feb 21 20:46:33 tippex [<c0121af5>] do_softirq+0x35/0x40
Feb 21 20:46:33 tippex [<c0121cb4>] irq_exit+0x44/0x50
Feb 21 20:46:33 tippex [<c0105757>] do_IRQ+0x47/0x80
Feb 21 20:46:33 tippex [<c01039c3>] common_interrupt+0x23/0x28
Feb 21 20:46:33 tippex =======================


It doesn't make any sens to me but I guess it does to others.

The other bad thing is that the machine hangs shortly after boot bitching 
about 'hdb: lost interrupt' on the console. Kown problem?

/A


^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2013-12-19 14:14 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-12-19 13:36 Lockdep warning Jonas Bonn
2013-12-19 14:02 ` Borislav Petkov
2013-12-19 14:04   ` Jonas Bonn
2013-12-19 14:14     ` Borislav Petkov
  -- strict thread matches above, loose matches on Subject: below --
2011-08-26 17:29 Larry Finger
2011-08-26 20:18 ` Shaun Ruffell
2008-03-06 12:14 Szekeres István
2008-02-22 10:40 lockdep warning Anders Eriksson
2008-02-22 11:16 ` Jiri Kosina
2008-02-22 13:16   ` Anders Eriksson
2008-02-22 13:20     ` Jiri Kosina
2008-02-22 16:32       ` Anders Eriksson
2008-02-22 17:01         ` Jiri Kosina

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox