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
nexedi
linux
Commits
6ddc0485
Commit
6ddc0485
authored
Feb 04, 2011
by
Gustavo F. Padovan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bluetooth: move L2CAP sock timers function to l2cap_sock.c
Signed-off-by:
Gustavo F. Padovan
<
padovan@profusion.mobi
>
parent
fd83ccdb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
13 deletions
+13
-13
net/bluetooth/l2cap_core.c
net/bluetooth/l2cap_core.c
+0
-13
net/bluetooth/l2cap_sock.c
net/bluetooth/l2cap_sock.c
+13
-0
No files found.
net/bluetooth/l2cap_core.c
View file @
6ddc0485
...
...
@@ -77,19 +77,6 @@ static struct sk_buff *l2cap_build_cmd(struct l2cap_conn *conn,
static
int
l2cap_ertm_data_rcv
(
struct
sock
*
sk
,
struct
sk_buff
*
skb
);
/* ---- L2CAP timers ---- */
void
l2cap_sock_set_timer
(
struct
sock
*
sk
,
long
timeout
)
{
BT_DBG
(
"sk %p state %d timeout %ld"
,
sk
,
sk
->
sk_state
,
timeout
);
sk_reset_timer
(
sk
,
&
sk
->
sk_timer
,
jiffies
+
timeout
);
}
void
l2cap_sock_clear_timer
(
struct
sock
*
sk
)
{
BT_DBG
(
"sock %p state %d"
,
sk
,
sk
->
sk_state
);
sk_stop_timer
(
sk
,
&
sk
->
sk_timer
);
}
/* ---- L2CAP channels ---- */
static
struct
sock
*
__l2cap_get_chan_by_dcid
(
struct
l2cap_chan_list
*
l
,
u16
cid
)
{
...
...
net/bluetooth/l2cap_sock.c
View file @
6ddc0485
...
...
@@ -30,6 +30,7 @@
#include <net/bluetooth/hci_core.h>
#include <net/bluetooth/l2cap.h>
/* ---- L2CAP timers ---- */
static
void
l2cap_sock_timeout
(
unsigned
long
arg
)
{
struct
sock
*
sk
=
(
struct
sock
*
)
arg
;
...
...
@@ -63,6 +64,18 @@ static void l2cap_sock_timeout(unsigned long arg)
sock_put
(
sk
);
}
void
l2cap_sock_set_timer
(
struct
sock
*
sk
,
long
timeout
)
{
BT_DBG
(
"sk %p state %d timeout %ld"
,
sk
,
sk
->
sk_state
,
timeout
);
sk_reset_timer
(
sk
,
&
sk
->
sk_timer
,
jiffies
+
timeout
);
}
void
l2cap_sock_clear_timer
(
struct
sock
*
sk
)
{
BT_DBG
(
"sock %p state %d"
,
sk
,
sk
->
sk_state
);
sk_stop_timer
(
sk
,
&
sk
->
sk_timer
);
}
static
struct
sock
*
__l2cap_get_sock_by_addr
(
__le16
psm
,
bdaddr_t
*
src
)
{
struct
sock
*
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