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
5597ba1e
Commit
5597ba1e
authored
Jan 14, 2004
by
Andrew Morton
Committed by
David S. Miller
Jan 14, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[NET]: Fix uninlinable __sock_put call in net/sock.h
parent
73cb93a3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
20 deletions
+18
-20
include/net/sock.h
include/net/sock.h
+18
-20
No files found.
include/net/sock.h
View file @
5597ba1e
...
@@ -304,7 +304,24 @@ static __inline__ int __sk_del_node_init(struct sock *sk)
...
@@ -304,7 +304,24 @@ static __inline__ int __sk_del_node_init(struct sock *sk)
return
0
;
return
0
;
}
}
static
inline
void
__sock_put
(
struct
sock
*
sk
);
/* Grab socket reference count. This operation is valid only
when sk is ALREADY grabbed f.e. it is found in hash table
or a list and the lookup is made under lock preventing hash table
modifications.
*/
static
inline
void
sock_hold
(
struct
sock
*
sk
)
{
atomic_inc
(
&
sk
->
sk_refcnt
);
}
/* Ungrab socket in the context, which assumes that socket refcnt
cannot hit zero, f.e. it is true in context of any socketcall.
*/
static
inline
void
__sock_put
(
struct
sock
*
sk
)
{
atomic_dec
(
&
sk
->
sk_refcnt
);
}
static
__inline__
int
sk_del_node_init
(
struct
sock
*
sk
)
static
__inline__
int
sk_del_node_init
(
struct
sock
*
sk
)
{
{
...
@@ -722,25 +739,6 @@ static inline void sk_filter_charge(struct sock *sk, struct sk_filter *fp)
...
@@ -722,25 +739,6 @@ static inline void sk_filter_charge(struct sock *sk, struct sk_filter *fp)
* use separate SMP lock, so that they are prone too.
* use separate SMP lock, so that they are prone too.
*/
*/
/* Grab socket reference count. This operation is valid only
when sk is ALREADY grabbed f.e. it is found in hash table
or a list and the lookup is made under lock preventing hash table
modifications.
*/
static
inline
void
sock_hold
(
struct
sock
*
sk
)
{
atomic_inc
(
&
sk
->
sk_refcnt
);
}
/* Ungrab socket in the context, which assumes that socket refcnt
cannot hit zero, f.e. it is true in context of any socketcall.
*/
static
inline
void
__sock_put
(
struct
sock
*
sk
)
{
atomic_dec
(
&
sk
->
sk_refcnt
);
}
/* Ungrab socket and destroy it, if it was the last reference. */
/* Ungrab socket and destroy it, if it was the last reference. */
static
inline
void
sock_put
(
struct
sock
*
sk
)
static
inline
void
sock_put
(
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