From: Ralf Baechle <ralf@linux-mips.org>
To: "David S. Miller" <davem@davemloft.net>,
netdev@vger.kernel.org, linux-hams@vger.kernel.org
Subject: [NETROM] adsf
Date: Tue, 11 Jul 2006 00:14:46 +0100 [thread overview]
Message-ID: <20060710231446.GA8579@linux-mips.org> (raw)
When establishing a new circuit in nr_rx_frame the locks are taken in a
different order than in the rest of the stack. This should be harmless
but triggers lockdep. Either way, reordering the code a little solves
the issue.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
diff --git a/net/netrom/af_netrom.c b/net/netrom/af_netrom.c
index ecc7968..672d5f8 100644
--- a/net/netrom/af_netrom.c
+++ b/net/netrom/af_netrom.c
@@ -986,18 +986,18 @@ int nr_rx_frame(struct sk_buff *skb, str
nr_make->vl = 0;
nr_make->state = NR_STATE_3;
sk_acceptq_added(sk);
-
- nr_insert_socket(make);
-
skb_queue_head(&sk->sk_receive_queue, skb);
- nr_start_heartbeat(make);
- nr_start_idletimer(make);
-
if (!sock_flag(sk, SOCK_DEAD))
sk->sk_data_ready(sk, skb->len);
bh_unlock_sock(sk);
+
+ nr_insert_socket(make);
+
+ nr_start_heartbeat(make);
+ nr_start_idletimer(make);
+
return 1;
}
next reply other threads:[~2006-07-10 23:14 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-10 23:14 Ralf Baechle [this message]
2006-07-10 23:22 ` [NETROM] adsf David 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=20060710231446.GA8579@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=davem@davemloft.net \
--cc=linux-hams@vger.kernel.org \
--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).