diff options
Diffstat (limited to 'net/sctp')
-rw-r--r-- | net/sctp/associola.c | 2 | ||||
-rw-r--r-- | net/sctp/input.c | 3 | ||||
-rw-r--r-- | net/sctp/outqueue.c | 2 | ||||
-rw-r--r-- | net/sctp/sm_make_chunk.c | 3 | ||||
-rw-r--r-- | net/sctp/socket.c | 2 | ||||
-rw-r--r-- | net/sctp/ulpqueue.c | 7 |
6 files changed, 1 insertions, 18 deletions
diff --git a/net/sctp/associola.c b/net/sctp/associola.c index 5f1fb8bd862d..6b04287913cd 100644 --- a/net/sctp/associola.c +++ b/net/sctp/associola.c | |||
@@ -1089,7 +1089,6 @@ static void sctp_assoc_bh_rcv(struct work_struct *work) | |||
1089 | base.inqueue.immediate); | 1089 | base.inqueue.immediate); |
1090 | struct sctp_endpoint *ep; | 1090 | struct sctp_endpoint *ep; |
1091 | struct sctp_chunk *chunk; | 1091 | struct sctp_chunk *chunk; |
1092 | struct sock *sk; | ||
1093 | struct sctp_inq *inqueue; | 1092 | struct sctp_inq *inqueue; |
1094 | int state; | 1093 | int state; |
1095 | sctp_subtype_t subtype; | 1094 | sctp_subtype_t subtype; |
@@ -1097,7 +1096,6 @@ static void sctp_assoc_bh_rcv(struct work_struct *work) | |||
1097 | 1096 | ||
1098 | /* The association should be held so we should be safe. */ | 1097 | /* The association should be held so we should be safe. */ |
1099 | ep = asoc->ep; | 1098 | ep = asoc->ep; |
1100 | sk = asoc->base.sk; | ||
1101 | 1099 | ||
1102 | inqueue = &asoc->base.inqueue; | 1100 | inqueue = &asoc->base.inqueue; |
1103 | sctp_association_hold(asoc); | 1101 | sctp_association_hold(asoc); |
diff --git a/net/sctp/input.c b/net/sctp/input.c index ea2192444ce6..826661be73e7 100644 --- a/net/sctp/input.c +++ b/net/sctp/input.c | |||
@@ -948,14 +948,11 @@ static struct sctp_association *__sctp_rcv_init_lookup(struct sk_buff *skb, | |||
948 | union sctp_addr addr; | 948 | union sctp_addr addr; |
949 | union sctp_addr *paddr = &addr; | 949 | union sctp_addr *paddr = &addr; |
950 | struct sctphdr *sh = sctp_hdr(skb); | 950 | struct sctphdr *sh = sctp_hdr(skb); |
951 | sctp_chunkhdr_t *ch; | ||
952 | union sctp_params params; | 951 | union sctp_params params; |
953 | sctp_init_chunk_t *init; | 952 | sctp_init_chunk_t *init; |
954 | struct sctp_transport *transport; | 953 | struct sctp_transport *transport; |
955 | struct sctp_af *af; | 954 | struct sctp_af *af; |
956 | 955 | ||
957 | ch = (sctp_chunkhdr_t *) skb->data; | ||
958 | |||
959 | /* | 956 | /* |
960 | * This code will NOT touch anything inside the chunk--it is | 957 | * This code will NOT touch anything inside the chunk--it is |
961 | * strictly READ-ONLY. | 958 | * strictly READ-ONLY. |
diff --git a/net/sctp/outqueue.c b/net/sctp/outqueue.c index 8c6d379b4bb6..26dc005113a0 100644 --- a/net/sctp/outqueue.c +++ b/net/sctp/outqueue.c | |||
@@ -545,13 +545,11 @@ static int sctp_outq_flush_rtx(struct sctp_outq *q, struct sctp_packet *pkt, | |||
545 | struct sctp_transport *transport = pkt->transport; | 545 | struct sctp_transport *transport = pkt->transport; |
546 | sctp_xmit_t status; | 546 | sctp_xmit_t status; |
547 | struct sctp_chunk *chunk, *chunk1; | 547 | struct sctp_chunk *chunk, *chunk1; |
548 | struct sctp_association *asoc; | ||
549 | int fast_rtx; | 548 | int fast_rtx; |
550 | int error = 0; | 549 | int error = 0; |
551 | int timer = 0; | 550 | int timer = 0; |
552 | int done = 0; | 551 | int done = 0; |
553 | 552 | ||
554 | asoc = q->asoc; | ||
555 | lqueue = &q->retransmit; | 553 | lqueue = &q->retransmit; |
556 | fast_rtx = q->fast_rtx; | 554 | fast_rtx = q->fast_rtx; |
557 | 555 | ||
diff --git a/net/sctp/sm_make_chunk.c b/net/sctp/sm_make_chunk.c index b23428f3c0dd..de98665db524 100644 --- a/net/sctp/sm_make_chunk.c +++ b/net/sctp/sm_make_chunk.c | |||
@@ -3375,7 +3375,6 @@ struct sctp_chunk *sctp_make_fwdtsn(const struct sctp_association *asoc, | |||
3375 | struct sctp_fwdtsn_skip *skiplist) | 3375 | struct sctp_fwdtsn_skip *skiplist) |
3376 | { | 3376 | { |
3377 | struct sctp_chunk *retval = NULL; | 3377 | struct sctp_chunk *retval = NULL; |
3378 | struct sctp_fwdtsn_chunk *ftsn_chunk; | ||
3379 | struct sctp_fwdtsn_hdr ftsn_hdr; | 3378 | struct sctp_fwdtsn_hdr ftsn_hdr; |
3380 | struct sctp_fwdtsn_skip skip; | 3379 | struct sctp_fwdtsn_skip skip; |
3381 | size_t hint; | 3380 | size_t hint; |
@@ -3388,8 +3387,6 @@ struct sctp_chunk *sctp_make_fwdtsn(const struct sctp_association *asoc, | |||
3388 | if (!retval) | 3387 | if (!retval) |
3389 | return NULL; | 3388 | return NULL; |
3390 | 3389 | ||
3391 | ftsn_chunk = (struct sctp_fwdtsn_chunk *)retval->subh.fwdtsn_hdr; | ||
3392 | |||
3393 | ftsn_hdr.new_cum_tsn = htonl(new_cum_tsn); | 3390 | ftsn_hdr.new_cum_tsn = htonl(new_cum_tsn); |
3394 | retval->subh.fwdtsn_hdr = | 3391 | retval->subh.fwdtsn_hdr = |
3395 | sctp_addto_chunk(retval, sizeof(ftsn_hdr), &ftsn_hdr); | 3392 | sctp_addto_chunk(retval, sizeof(ftsn_hdr), &ftsn_hdr); |
diff --git a/net/sctp/socket.c b/net/sctp/socket.c index b53b2ebbb198..3951a10605bc 100644 --- a/net/sctp/socket.c +++ b/net/sctp/socket.c | |||
@@ -2928,7 +2928,6 @@ static int sctp_setsockopt_peer_primary_addr(struct sock *sk, char __user *optva | |||
2928 | unsigned int optlen) | 2928 | unsigned int optlen) |
2929 | { | 2929 | { |
2930 | struct sctp_sock *sp; | 2930 | struct sctp_sock *sp; |
2931 | struct sctp_endpoint *ep; | ||
2932 | struct sctp_association *asoc = NULL; | 2931 | struct sctp_association *asoc = NULL; |
2933 | struct sctp_setpeerprim prim; | 2932 | struct sctp_setpeerprim prim; |
2934 | struct sctp_chunk *chunk; | 2933 | struct sctp_chunk *chunk; |
@@ -2936,7 +2935,6 @@ static int sctp_setsockopt_peer_primary_addr(struct sock *sk, char __user *optva | |||
2936 | int err; | 2935 | int err; |
2937 | 2936 | ||
2938 | sp = sctp_sk(sk); | 2937 | sp = sctp_sk(sk); |
2939 | ep = sp->ep; | ||
2940 | 2938 | ||
2941 | if (!sctp_addip_enable) | 2939 | if (!sctp_addip_enable) |
2942 | return -EPERM; | 2940 | return -EPERM; |
diff --git a/net/sctp/ulpqueue.c b/net/sctp/ulpqueue.c index c7f7e49609cb..17678189d054 100644 --- a/net/sctp/ulpqueue.c +++ b/net/sctp/ulpqueue.c | |||
@@ -105,11 +105,8 @@ int sctp_ulpq_tail_data(struct sctp_ulpq *ulpq, struct sctp_chunk *chunk, | |||
105 | gfp_t gfp) | 105 | gfp_t gfp) |
106 | { | 106 | { |
107 | struct sk_buff_head temp; | 107 | struct sk_buff_head temp; |
108 | sctp_data_chunk_t *hdr; | ||
109 | struct sctp_ulpevent *event; | 108 | struct sctp_ulpevent *event; |
110 | 109 | ||
111 | hdr = (sctp_data_chunk_t *) chunk->chunk_hdr; | ||
112 | |||
113 | /* Create an event from the incoming chunk. */ | 110 | /* Create an event from the incoming chunk. */ |
114 | event = sctp_ulpevent_make_rcvmsg(chunk->asoc, chunk, gfp); | 111 | event = sctp_ulpevent_make_rcvmsg(chunk->asoc, chunk, gfp); |
115 | if (!event) | 112 | if (!event) |
@@ -743,11 +740,9 @@ static void sctp_ulpq_retrieve_ordered(struct sctp_ulpq *ulpq, | |||
743 | struct sk_buff *pos, *tmp; | 740 | struct sk_buff *pos, *tmp; |
744 | struct sctp_ulpevent *cevent; | 741 | struct sctp_ulpevent *cevent; |
745 | struct sctp_stream *in; | 742 | struct sctp_stream *in; |
746 | __u16 sid, csid; | 743 | __u16 sid, csid, cssn; |
747 | __u16 ssn, cssn; | ||
748 | 744 | ||
749 | sid = event->stream; | 745 | sid = event->stream; |
750 | ssn = event->ssn; | ||
751 | in = &ulpq->asoc->ssnmap->in; | 746 | in = &ulpq->asoc->ssnmap->in; |
752 | 747 | ||
753 | event_list = (struct sk_buff_head *) sctp_event2skb(event)->prev; | 748 | event_list = (struct sk_buff_head *) sctp_event2skb(event)->prev; |