Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
b1b87255
Commit
b1b87255
authored
Mar 10, 2005
by
Ralf Bächle
Committed by
David S. Miller
Mar 10, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[NETROM]: Fix deadlock due to double locking.
Signed-off-by:
David S. Miller
<
davem@davemloft.net
>
parent
e0698e4f
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
10 deletions
+1
-10
net/netrom/nr_in.c
net/netrom/nr_in.c
+1
-10
No files found.
net/netrom/nr_in.c
View file @
b1b87255
...
@@ -74,7 +74,6 @@ static int nr_queue_rx_frame(struct sock *sk, struct sk_buff *skb, int more)
...
@@ -74,7 +74,6 @@ static int nr_queue_rx_frame(struct sock *sk, struct sk_buff *skb, int more)
static
int
nr_state1_machine
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
,
static
int
nr_state1_machine
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
,
int
frametype
)
int
frametype
)
{
{
bh_lock_sock
(
sk
);
switch
(
frametype
)
{
switch
(
frametype
)
{
case
NR_CONNACK
:
{
case
NR_CONNACK
:
{
nr_cb
*
nr
=
nr_sk
(
sk
);
nr_cb
*
nr
=
nr_sk
(
sk
);
...
@@ -103,8 +102,6 @@ static int nr_state1_machine(struct sock *sk, struct sk_buff *skb,
...
@@ -103,8 +102,6 @@ static int nr_state1_machine(struct sock *sk, struct sk_buff *skb,
default:
default:
break
;
break
;
}
}
bh_unlock_sock
(
sk
);
return
0
;
return
0
;
}
}
...
@@ -116,7 +113,6 @@ static int nr_state1_machine(struct sock *sk, struct sk_buff *skb,
...
@@ -116,7 +113,6 @@ static int nr_state1_machine(struct sock *sk, struct sk_buff *skb,
static
int
nr_state2_machine
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
,
static
int
nr_state2_machine
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
,
int
frametype
)
int
frametype
)
{
{
bh_lock_sock
(
sk
);
switch
(
frametype
)
{
switch
(
frametype
)
{
case
NR_CONNACK
|
NR_CHOKE_FLAG
:
case
NR_CONNACK
|
NR_CHOKE_FLAG
:
nr_disconnect
(
sk
,
ECONNRESET
);
nr_disconnect
(
sk
,
ECONNRESET
);
...
@@ -132,8 +128,6 @@ static int nr_state2_machine(struct sock *sk, struct sk_buff *skb,
...
@@ -132,8 +128,6 @@ static int nr_state2_machine(struct sock *sk, struct sk_buff *skb,
default:
default:
break
;
break
;
}
}
bh_unlock_sock
(
sk
);
return
0
;
return
0
;
}
}
...
@@ -154,7 +148,6 @@ static int nr_state3_machine(struct sock *sk, struct sk_buff *skb, int frametype
...
@@ -154,7 +148,6 @@ static int nr_state3_machine(struct sock *sk, struct sk_buff *skb, int frametype
nr
=
skb
->
data
[
18
];
nr
=
skb
->
data
[
18
];
ns
=
skb
->
data
[
17
];
ns
=
skb
->
data
[
17
];
bh_lock_sock
(
sk
);
switch
(
frametype
)
{
switch
(
frametype
)
{
case
NR_CONNREQ
:
case
NR_CONNREQ
:
nr_write_internal
(
sk
,
NR_CONNACK
);
nr_write_internal
(
sk
,
NR_CONNACK
);
...
@@ -265,12 +258,10 @@ static int nr_state3_machine(struct sock *sk, struct sk_buff *skb, int frametype
...
@@ -265,12 +258,10 @@ static int nr_state3_machine(struct sock *sk, struct sk_buff *skb, int frametype
default:
default:
break
;
break
;
}
}
bh_unlock_sock
(
sk
);
return
queued
;
return
queued
;
}
}
/* Higher level upcall for a LAPB frame */
/* Higher level upcall for a LAPB frame
- called with sk locked
*/
int
nr_process_rx_frame
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
)
int
nr_process_rx_frame
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
)
{
{
nr_cb
*
nr
=
nr_sk
(
sk
);
nr_cb
*
nr
=
nr_sk
(
sk
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment