netlink: rename ssk to sk in struct netlink_skb_params
authorPatrick McHardy <kaber@trash.net>
Wed, 17 Apr 2013 06:46:57 +0000 (06:46 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 19 Apr 2013 18:57:56 +0000 (14:57 -0400)
Memory mapped netlink needs to store the receiving userspace socket
when sending from the kernel to userspace. Rename 'ssk' to 'sk' to
avoid confusion.

Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/netlink.h
net/ipv4/inet_diag.c
net/ipv4/udp_diag.c
net/netfilter/nfnetlink_log.c
net/netlink/af_netlink.c
net/sched/cls_flow.c

index e0f746b7b95c5292b03ca073b02ee2aa905de21a..d8e9264ae04a99272b1192a58b1153f6a4268a85 100644 (file)
@@ -19,7 +19,7 @@ struct netlink_skb_parms {
        struct scm_creds        creds;          /* Skb credentials      */
        __u32                   portid;
        __u32                   dst_group;
-       struct sock             *ssk;
+       struct sock             *sk;
 };
 
 #define NETLINK_CB(skb)                (*(struct netlink_skb_parms*)&((skb)->cb))
index 8620408af5744cc785c01fad9c6bb0f1f4870c8c..5f648751fce2d03418f4a6425c7ba0dbfb3ddfc0 100644 (file)
@@ -324,7 +324,7 @@ int inet_diag_dump_one_icsk(struct inet_hashinfo *hashinfo, struct sk_buff *in_s
        }
 
        err = sk_diag_fill(sk, rep, req,
-                          sk_user_ns(NETLINK_CB(in_skb).ssk),
+                          sk_user_ns(NETLINK_CB(in_skb).sk),
                           NETLINK_CB(in_skb).portid,
                           nlh->nlmsg_seq, 0, nlh);
        if (err < 0) {
@@ -630,7 +630,7 @@ static int inet_csk_diag_dump(struct sock *sk,
                return 0;
 
        return inet_csk_diag_fill(sk, skb, r,
-                                 sk_user_ns(NETLINK_CB(cb->skb).ssk),
+                                 sk_user_ns(NETLINK_CB(cb->skb).sk),
                                  NETLINK_CB(cb->skb).portid,
                                  cb->nlh->nlmsg_seq, NLM_F_MULTI, cb->nlh);
 }
@@ -805,7 +805,7 @@ static int inet_diag_dump_reqs(struct sk_buff *skb, struct sock *sk,
                        }
 
                        err = inet_diag_fill_req(skb, sk, req,
-                                              sk_user_ns(NETLINK_CB(cb->skb).ssk),
+                                              sk_user_ns(NETLINK_CB(cb->skb).sk),
                                               NETLINK_CB(cb->skb).portid,
                                               cb->nlh->nlmsg_seq, cb->nlh);
                        if (err < 0) {
index 369a781851ad91373da7803112783caf22dbaded..7927db0a927951a20b4502d38fca0bba9e94862c 100644 (file)
@@ -25,7 +25,7 @@ static int sk_diag_dump(struct sock *sk, struct sk_buff *skb,
                return 0;
 
        return inet_sk_diag_fill(sk, NULL, skb, req,
-                       sk_user_ns(NETLINK_CB(cb->skb).ssk),
+                       sk_user_ns(NETLINK_CB(cb->skb).sk),
                        NETLINK_CB(cb->skb).portid,
                        cb->nlh->nlmsg_seq, NLM_F_MULTI, cb->nlh);
 }
@@ -71,7 +71,7 @@ static int udp_dump_one(struct udp_table *tbl, struct sk_buff *in_skb,
                goto out;
 
        err = inet_sk_diag_fill(sk, NULL, rep, req,
-                          sk_user_ns(NETLINK_CB(in_skb).ssk),
+                          sk_user_ns(NETLINK_CB(in_skb).sk),
                           NETLINK_CB(in_skb).portid,
                           nlh->nlmsg_seq, 0, nlh);
        if (err < 0) {
index 1a0be2af1dd8dd92e86fbca2e32338043e308fcc..50aaf716cd68ed2acc787fe20b74f9b826a97872 100644 (file)
@@ -824,7 +824,7 @@ nfulnl_recv_config(struct sock *ctnl, struct sk_buff *skb,
 
                        inst = instance_create(net, group_num,
                                               NETLINK_CB(skb).portid,
-                                              sk_user_ns(NETLINK_CB(skb).ssk));
+                                              sk_user_ns(NETLINK_CB(skb).sk));
                        if (IS_ERR(inst)) {
                                ret = PTR_ERR(inst);
                                goto out;
index f20a810051779f243da8a1822f9b7be1c256a4f9..978a61f7c87f19ec6f6e50ae8c75ecd83f114d4b 100644 (file)
@@ -891,7 +891,7 @@ static int netlink_unicast_kernel(struct sock *sk, struct sk_buff *skb,
        if (nlk->netlink_rcv != NULL) {
                ret = skb->len;
                skb_set_owner_r(skb, sk);
-               NETLINK_CB(skb).ssk = ssk;
+               NETLINK_CB(skb).sk = ssk;
                nlk->netlink_rcv(skb);
                consume_skb(skb);
        } else {
index aa36a8c8b33bf27e286443f23ba27393e7156cda..7881e2fccbc2ea1b7cd0eaf98ac3f0675836e150 100644 (file)
@@ -393,7 +393,7 @@ static int flow_change(struct net *net, struct sk_buff *in_skb,
                        return -EOPNOTSUPP;
 
                if ((keymask & (FLOW_KEY_SKUID|FLOW_KEY_SKGID)) &&
-                   sk_user_ns(NETLINK_CB(in_skb).ssk) != &init_user_ns)
+                   sk_user_ns(NETLINK_CB(in_skb).sk) != &init_user_ns)
                        return -EOPNOTSUPP;
        }