netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jarek Poplawski <jarkao2@gmail.com>
To: James Chapman <jchapman@katalix.com>
Cc: David Miller <davem@davemloft.net>, netdev@vger.kernel.org
Subject: Re: [PATCH][PPPOL2TP]: Fix SMP oops in pppol2tp driver
Date: Tue, 12 Feb 2008 13:24:50 +0000	[thread overview]
Message-ID: <20080212132450.GA11561@ff.dom.local> (raw)
In-Reply-To: <47B17BCD.2070903@katalix.com>

On Tue, Feb 12, 2008 at 10:58:21AM +0000, James Chapman wrote:
...
> Here is a trace from when we had _bh locks.

Very nice...

...But since it's quite long, and if you don't know all these paths
this could take some time, maybe one question: so if lockdep got these
locks right (sometimes it can be wrong when the same structures are
nested), then it seems some problem is with this place below. This
lock is taken for writing with softirqs enabled here, and IMHO it
would be interesting to test if changing this is enough for lockdep.
It seems this is in ip4_datagram_connect() during sk_dst_reset() or
sk_dst_set(). So maybe you could try with local_bh_disable/enable()
around them (or maybe some better idea)? Anyway, I'll try to learn
this more in the meantime.

Jarek P.

> Feb  5 16:26:32  to a soft-irq-unsafe lock:
> Feb  5 16:26:32  (&sk->sk_dst_lock){----}
> Feb  5 16:26:32  ... which became soft-irq-unsafe at:
> Feb  5 16:26:32  ...  [<c014e02e>] mark_held_locks+0x5e/0x80
> Feb  5 16:26:32  [<c014ed92>] __lock_acquire+0x6a2/0x10a0
> Feb  5 16:26:32  [<c010f5b0>] save_stack_trace+0x20/0x40
> Feb  5 16:26:32  [<c014c524>] add_lock_to_list+0x44/0xb0
> Feb  5 16:26:32  [<c03dea29>] __udp_lib_get_port+0x19/0x200
> Feb  5 16:26:32  [<c014f735>] __lock_acquire+0x1045/0x10a0
> Feb  5 16:26:32  [<c014f804>] lock_acquire+0x74/0xa0
> Feb  5 16:26:32  [<c03db0a3>] ip4_datagram_connect+0x53/0x380
> Feb  5 16:26:32  [<c040418a>] _write_lock+0x2a/0x40
> Feb  5 16:26:32  [<c03db0a3>] ip4_datagram_connect+0x53/0x380
> Feb  5 16:26:32  [<c03db0a3>] ip4_datagram_connect+0x53/0x380
> Feb  5 16:26:32  [<c014e1c5>] trace_hardirqs_on+0xc5/0x170
> Feb  5 16:26:32  [<c0132317>] local_bh_enable_ip+0xa7/0x120
> Feb  5 16:26:32  [<c014e1c5>] trace_hardirqs_on+0xc5/0x170
> Feb  5 16:26:32  [<c040414f>] _spin_lock_bh+0x2f/0x40
> Feb  5 16:26:32  [<c03e4d55>] inet_dgram_connect+0x35/0x80
> Feb  5 16:26:32  [<c038ec52>] sys_connect+0x82/0xd0
> Feb  5 16:26:32  [<c01455df>] down_read_trylock+0x4f/0x60
> Feb  5 16:26:32  [<c011fe9c>] do_page_fault+0xfc/0x940
> Feb  5 16:26:32  [<c0404024>] _spin_unlock+0x14/0x20
> Feb  5 16:26:32  [<c03905f8>] sys_socketcall+0x98/0x280
> Feb  5 16:26:32  [<c014e1c5>] trace_hardirqs_on+0xc5/0x170
> Feb  5 16:26:32  [<c02a86ba>] copy_to_user+0x3a/0x70
> Feb  5 16:26:32  [<c0108417>] restore_nocheck+0x12/0x15
> Feb  5 16:26:32  [<c01083aa>] syscall_call+0x7/0xb
> Feb  5 16:26:32  [<ffffffff>] 0xffffffff

  reply	other threads:[~2008-02-12 13:17 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-11  9:22 [PATCH][PPPOL2TP]: Fix SMP oops in pppol2tp driver James Chapman
2008-02-11 18:57 ` Jarek Poplawski
2008-02-11 22:19   ` James Chapman
2008-02-11 22:49     ` Jarek Poplawski
2008-02-11 22:55       ` Jarek Poplawski
2008-02-11 23:42         ` James Chapman
2008-02-12 10:42           ` Jarek Poplawski
2008-02-11 23:41       ` James Chapman
2008-02-12  5:30         ` David Miller
2008-02-12 10:58           ` James Chapman
2008-02-12 13:24             ` Jarek Poplawski [this message]
2008-02-13  6:00             ` David Miller
2008-02-13  7:29               ` Jarek Poplawski
2008-02-14 13:00             ` Jarek Poplawski
2008-02-18 22:09               ` James Chapman
2008-02-18 23:01                 ` Jarek Poplawski
2008-02-19  9:09                   ` James Chapman
2008-02-19  4:29                 ` David Miller
2008-02-19  9:03                   ` James Chapman
2008-02-19 10:30                     ` Jarek Poplawski
2008-02-19 10:36                       ` Jarek Poplawski
2008-02-19 14:37                       ` James Chapman
2008-02-19 23:06                 ` Jarek Poplawski
2008-02-19 23:28                   ` Jarek Poplawski
2008-02-20 16:02                   ` James Chapman
2008-02-20 18:38                     ` Jarek Poplawski
2008-02-20 22:37                       ` James Chapman
2008-02-21  8:59                         ` Jarek Poplawski
2008-02-21  9:53                           ` James Chapman
2008-02-21 12:08                             ` Jarek Poplawski
2008-02-21 17:09                               ` Jarek Poplawski
2008-02-25 12:19                                 ` James Chapman
2008-02-25 13:05                                   ` Jarek Poplawski
2008-02-25 13:39                                     ` Jarek Poplawski
2008-02-25 14:02                                       ` Jarek Poplawski
2008-02-25 21:58                                       ` Jarek Poplawski
2008-02-26 12:14                                         ` James Chapman
2008-02-26 13:03                                           ` Jarek Poplawski
2008-02-26 13:18                                             ` Jarek Poplawski
2008-02-26 20:00                                           ` Jarek Poplawski
2008-03-02 20:29                                             ` James Chapman
2008-03-03  8:22                                               ` Jarek Poplawski
2008-03-03  9:35                                                 ` Jarek Poplawski
2008-02-27 10:54                                           ` [PATCH][PPPOL2TP] add missing sock_put() in pppol2tp_recv_dequeue() Jarek Poplawski
2008-03-02 20:31                                             ` James Chapman
2008-03-04  4:49                                               ` David Miller
2008-02-27 11:48                                           ` [PATCH][PPPOL2TP] add missing sock_put() in pppol2tp_tunnel_closeall() Jarek Poplawski
2008-03-02 20:32                                             ` James Chapman
2008-03-04  4:49                                               ` David Miller
2008-02-22 14:16                             ` [PATCH][NET] sock.c: sk_dst_lock lockdep keys and names per af_family Jarek Poplawski
2008-02-12  7:19         ` [PATCH][PPPOL2TP]: Fix SMP oops in pppol2tp driver Jarek Poplawski

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=20080212132450.GA11561@ff.dom.local \
    --to=jarkao2@gmail.com \
    --cc=davem@davemloft.net \
    --cc=jchapman@katalix.com \
    --cc=netdev@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).