X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=net%2Fsctp%2Fulpqueue.c;h=d5dd2cf7ac4a01a6b7a13cfb417c32d5ca8bd3cb;hb=6a77f38946aaee1cd85eeec6cf4229b204c15071;hp=350a97ec7c622de056749073d6ebbb9f9c6fa7fa;hpb=87fc8d1bb10cd459024a742c6a10961fefcef18f;p=linux-2.6.git diff --git a/net/sctp/ulpqueue.c b/net/sctp/ulpqueue.c index 350a97ec7..d5dd2cf7a 100644 --- a/net/sctp/ulpqueue.c +++ b/net/sctp/ulpqueue.c @@ -56,25 +56,6 @@ static struct sctp_ulpevent * sctp_ulpq_order(struct sctp_ulpq *, /* 1st Level Abstractions */ -/* Create a new ULP queue. */ -struct sctp_ulpq *sctp_ulpq_new(struct sctp_association *asoc, int gfp) -{ - struct sctp_ulpq *ulpq; - - ulpq = kmalloc(sizeof(struct sctp_ulpq), gfp); - if (!ulpq) - goto fail; - if (!sctp_ulpq_init(ulpq, asoc)) - goto fail_init; - ulpq->malloced = 1; - return ulpq; - -fail_init: - kfree(ulpq); -fail: - return NULL; -} - /* Initialize a ULP queue from a block of memory. */ struct sctp_ulpq *sctp_ulpq_init(struct sctp_ulpq *ulpq, struct sctp_association *asoc) @@ -92,7 +73,7 @@ struct sctp_ulpq *sctp_ulpq_init(struct sctp_ulpq *ulpq, /* Flush the reassembly and ordering queues. */ -void sctp_ulpq_flush(struct sctp_ulpq *ulpq) +static void sctp_ulpq_flush(struct sctp_ulpq *ulpq) { struct sk_buff *skb; struct sctp_ulpevent *event; @@ -157,8 +138,7 @@ int sctp_ulpq_tail_data(struct sctp_ulpq *ulpq, struct sctp_chunk *chunk, */ int sctp_clear_pd(struct sock *sk) { - struct sctp_opt *sp; - sp = sctp_sk(sk); + struct sctp_sock *sp = sctp_sk(sk); sp->pd_mode = 0; if (!skb_queue_empty(&sp->pd_lobby)) {