summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/linux/ipv6.h15
-rw-r--r--include/net/af_unix.h7
-rw-r--r--include/net/sock.h3
3 files changed, 12 insertions, 13 deletions
diff --git a/include/linux/ipv6.h b/include/linux/ipv6.h
index 55aba976aba6..d7d1673880d5 100644
--- a/include/linux/ipv6.h
+++ b/include/linux/ipv6.h
@@ -182,8 +182,7 @@ enum {
as offsets from skb->nh.
*/
-struct inet6_skb_parm
-{
+struct inet6_skb_parm {
int iif;
__u16 ra;
__u16 hop;
@@ -194,6 +193,14 @@ struct inet6_skb_parm
#define IP6CB(skb) ((struct inet6_skb_parm*)((skb)->cb))
+/**
+ * struct ipv6_pinfo - ipv6 private area
+ *
+ * In the struct sock hierarchy (tcp6_sock, upd6_sock, etc)
+ * this _must_ be the last member, so that inet6_sk_generic
+ * is able to calculate its offset from the base struct sock
+ * by using the struct proto->slab_obj_size member. -acme
+ */
struct ipv6_pinfo {
struct in6_addr saddr;
struct in6_addr rcv_saddr;
@@ -282,10 +289,6 @@ static inline struct raw6_opt * raw6_sk(const struct sock *__sk)
return &((struct raw6_sock *)__sk)->raw6;
}
-struct ipv6_sk_offset {
- int offset;
-};
-
#if defined(CONFIG_IPV6) || defined(CONFIG_IPV6_MODULE)
#define __ipv6_only_sock(sk) (inet6_sk(sk)->ipv6only)
#define ipv6_only_sock(sk) ((sk)->sk_family == PF_INET6 && __ipv6_only_sock(sk))
diff --git a/include/net/af_unix.h b/include/net/af_unix.h
index be877d75cfeb..b60b3846b9d1 100644
--- a/include/net/af_unix.h
+++ b/include/net/af_unix.h
@@ -37,16 +37,14 @@ static inline struct sock *next_unix_socket(int *i, struct sock *s)
#define forall_unix_sockets(i, s) \
for (s = first_unix_socket(&(i)); s; s = next_unix_socket(&(i),(s)))
-struct unix_address
-{
+struct unix_address {
atomic_t refcnt;
int len;
unsigned hash;
struct sockaddr_un name[0];
};
-struct unix_skb_parms
-{
+struct unix_skb_parms {
struct ucred creds; /* Skb credentials */
struct scm_fp_list *fp; /* Passed files */
};
@@ -68,6 +66,7 @@ struct unix_sock {
struct dentry *dentry;
struct vfsmount *mnt;
struct semaphore readsem;
+ struct sock *peer;
struct sock *other;
struct sock *gc_tree;
atomic_t inflight;
diff --git a/include/net/sock.h b/include/net/sock.h
index e9a5eb5d1840..0666e2edd3c7 100644
--- a/include/net/sock.h
+++ b/include/net/sock.h
@@ -142,7 +142,6 @@ struct sock_common {
* @sk_route_caps - route capabilities (e.g. %NETIF_F_TSO)
* @sk_lingertime - %SO_LINGER l_linger setting
* @sk_hashent - hash entry in several tables (e.g. tcp_ehash)
- * @sk_pair - socket pair (e.g. AF_UNIX/unix_peer)
* @sk_backlog - always used with the per-socket spinlock held
* @sk_callback_lock - used with the callbacks in the end of this struct
* @sk_error_queue - rarely used
@@ -219,7 +218,6 @@ struct sock {
int sk_route_caps;
unsigned long sk_lingertime;
int sk_hashent;
- struct sock *sk_pair;
/*
* The backlog queue is special, it is always used with
* the per-socket spinlock held and requires low latency
@@ -557,7 +555,6 @@ struct proto {
kmem_cache_t *slab;
int slab_obj_size;
- void *af_specific;
char name[32];