From: Ingo Molnar <mingo@elte.hu>
To: Herbert Xu <herbert@gondor.apana.org.au>
Cc: davem@redhat.com, linux-kernel@vger.kernel.org
Subject: Re: [lock validator] inet6_destroy_sock(): soft-safe -> soft-unsafe lock dependency
Date: Tue, 31 Jan 2006 22:24:32 +0100 [thread overview]
Message-ID: <20060131212432.GA18812@elte.hu> (raw)
In-Reply-To: <20060131102758.GA31460@gondor.apana.org.au>
* Herbert Xu <herbert@gondor.apana.org.au> wrote:
> This inference is where the validator errs. sk_dst_lock is never (or
> should never be, and as far as I can see none of the traces show it to
> do so) obtained in a real softirq context.
just to make sure - is the trace below a safe use of sk_dst_lock too?
Here sk_dst_lock seems to be taken in real softirq context.
Ingo
============================
[ BUG: illegal lock usage! ]
----------------------------
illegal {softirq-on} -> {in-softirq} usage.
sshd/2476 [HC0[0]:SC1[2]:HE1:SE0] takes:
(&sk->sk_dst_lock){-+}, at: [<c0499015>] inet6_destroy_sock+0x25/0x100
{softirq-on} state was registered at:
[<c04a1bd8>] ipv6_dev_get_saddr+0x138/0x640
hardirqs last enabled at: [<c04dea45>] _spin_unlock_irqrestore+0x25/0x30
softirqs last enabled at: [<c01231e5>] irq_exit+0x45/0x50
other info that might help us debug this:
3 locks held by sshd/2476:
#0: (&p->proc_lock){--}, at: [<c011f1a3>] release_task+0x23/0x150
#1: (&tp->rx_lock){-+}, at: [<c0342a15>] rtl8139_poll+0x45/0x4c0
#2: (&sk->sk_lock.slock/1){-+}, at: [<c047e8f6>] tcp_v4_rcv+0x726/0x9d0
stack backtrace:
[<c010437d>] show_trace+0xd/0x10
[<c0104397>] dump_stack+0x17/0x20
[<c0139538>] print_usage_bug+0x1d8/0x230
[<c01398a8>] mark_lock+0x318/0x350
[<c0139d73>] debug_lock_chain+0x493/0x1090
[<c013a9ad>] debug_lock_chain_spin+0x3d/0x60
[<c0269272>] _raw_write_lock+0x32/0x1a0
[<c04de9e8>] _write_lock+0x8/0x10
[<c0499015>] inet6_destroy_sock+0x25/0x100
[<c04b8672>] tcp_v6_destroy_sock+0x12/0x20
[<c046bbda>] inet_csk_destroy_sock+0x4a/0x150
[<c047625c>] tcp_rcv_state_process+0xd4c/0xdd0
[<c047d8e9>] tcp_v4_do_rcv+0xa9/0x340
[<c047eabb>] tcp_v4_rcv+0x8eb/0x9d0
[<c0462c76>] ip_local_deliver+0xa6/0x190
[<c04629f8>] ip_rcv+0x2f8/0x4d0
[<c044bcb6>] netif_receive_skb+0x1b6/0x2a0
[<c0342d3a>] rtl8139_poll+0x36a/0x4c0
[<c044a682>] net_rx_action+0xd2/0x1f0
[<c0123527>] __do_softirq+0x97/0x130
[<c01054d9>] do_softirq+0x69/0x100
=======================
[<c01231e5>] irq_exit+0x45/0x50
[<c01055c4>] do_IRQ+0x54/0x70
[<c01038a9>] common_interrupt+0x25/0x2c
[<c0120990>] do_wait+0x7d0/0xad0
[<c0120cc2>] sys_wait4+0x32/0x40
[<c0120cf5>] sys_waitpid+0x25/0x30
[<c0102e17>] sysenter_past_esp+0x54/0x8d
next prev parent reply other threads:[~2006-01-31 21:26 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-27 0:18 [lock validator] net/ipv4/fib_hash.c: illegal {enabled-softirqs} -> {used-in-softirq} usage? Ingo Molnar
2006-01-27 1:41 ` Herbert Xu
2006-01-28 15:22 ` [lock validator] inet6_destroy_sock(): soft-safe -> soft-unsafe lock dependency Ingo Molnar
2006-01-28 15:44 ` Ingo Molnar
2006-01-31 10:27 ` Herbert Xu
2006-01-31 10:43 ` David S. Miller
2006-01-31 11:21 ` Ingo Molnar
2006-02-01 13:32 ` Ingo Molnar
2006-02-01 20:26 ` Herbert Xu
2006-02-02 7:46 ` Ingo Molnar
2006-02-02 8:48 ` Herbert Xu
2006-02-02 9:04 ` David S. Miller
2006-02-02 10:54 ` Ingo Molnar
2006-02-02 11:27 ` Ingo Molnar
2006-02-02 12:19 ` Herbert Xu
2006-02-02 12:17 ` Herbert Xu
2006-02-02 13:54 ` Ingo Molnar
2006-01-31 21:24 ` Ingo Molnar [this message]
2006-01-31 22:06 ` Herbert Xu
2006-02-01 10:42 ` Herbert Xu
2006-02-01 11:13 ` Ingo Molnar
2006-02-03 1:01 ` David S. Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060131212432.GA18812@elte.hu \
--to=mingo@elte.hu \
--cc=davem@redhat.com \
--cc=herbert@gondor.apana.org.au \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).