summaryrefslogtreecommitdiff
path: root/include/net
diff options
context:
space:
mode:
authorColin Cross <ccross@android.com>2011-01-07 17:20:53 -0800
committerColin Cross <ccross@android.com>2011-01-07 17:20:53 -0800
commit351516118103c6c7bb5321aa9d5866eb3dc0d5ca (patch)
treebf8ecc55d77847ec8299bcf964352bef38121cc5 /include/net
parentc37bff78783d40d6e604129135c207e279de902f (diff)
parentbd842b53fada517017d192c8a12fc9a38e6250e1 (diff)
Merge branch 'linux-tegra-2.6.36' into android-tegra-2.6.36
Conflicts: arch/arm/mm/cache-v6.S Change-Id: I1a2063218dd705a762a40f4a9dfe504ce1a1d491
Diffstat (limited to 'include/net')
-rw-r--r--include/net/af_unix.h2
-rw-r--r--include/net/sock.h4
2 files changed, 5 insertions, 1 deletions
diff --git a/include/net/af_unix.h b/include/net/af_unix.h
index 90c9e2872f27..18e5c3f67580 100644
--- a/include/net/af_unix.h
+++ b/include/net/af_unix.h
@@ -10,6 +10,7 @@ extern void unix_inflight(struct file *fp);
extern void unix_notinflight(struct file *fp);
extern void unix_gc(void);
extern void wait_for_unix_gc(void);
+extern struct sock *unix_get_socket(struct file *filp);
#define UNIX_HASH_SIZE 256
@@ -56,6 +57,7 @@ struct unix_sock {
spinlock_t lock;
unsigned int gc_candidate : 1;
unsigned int gc_maybe_cycle : 1;
+ unsigned char recursion_level;
struct socket_wq peer_wq;
};
#define unix_sk(__sk) ((struct unix_sock *)__sk)
diff --git a/include/net/sock.h b/include/net/sock.h
index adab9dc58183..6892a5e89c23 100644
--- a/include/net/sock.h
+++ b/include/net/sock.h
@@ -1155,6 +1155,8 @@ extern void sk_common_release(struct sock *sk);
/* Initialise core socket variables */
extern void sock_init_data(struct socket *sock, struct sock *sk);
+extern void sk_filter_release_rcu(struct rcu_head *rcu);
+
/**
* sk_filter_release - release a socket filter
* @fp: filter to remove
@@ -1165,7 +1167,7 @@ extern void sock_init_data(struct socket *sock, struct sock *sk);
static inline void sk_filter_release(struct sk_filter *fp)
{
if (atomic_dec_and_test(&fp->refcnt))
- kfree(fp);
+ call_rcu_bh(&fp->rcu, sk_filter_release_rcu);
}
static inline void sk_filter_uncharge(struct sock *sk, struct sk_filter *fp)