aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/net/sctp/ulpqueue.h1
-rw-r--r--net/sctp/associola.c6
-rw-r--r--net/sctp/ulpqueue.c2
3 files changed, 8 insertions, 1 deletions
diff --git a/include/net/sctp/ulpqueue.h b/include/net/sctp/ulpqueue.h
index a43c8788b650..ab26ab3adae1 100644
--- a/include/net/sctp/ulpqueue.h
+++ b/include/net/sctp/ulpqueue.h
@@ -59,6 +59,7 @@ struct sctp_ulpq {
59/* Prototypes. */ 59/* Prototypes. */
60struct sctp_ulpq *sctp_ulpq_init(struct sctp_ulpq *, 60struct sctp_ulpq *sctp_ulpq_init(struct sctp_ulpq *,
61 struct sctp_association *); 61 struct sctp_association *);
62void sctp_ulpq_flush(struct sctp_ulpq *ulpq);
62void sctp_ulpq_free(struct sctp_ulpq *); 63void sctp_ulpq_free(struct sctp_ulpq *);
63 64
64/* Add a new DATA chunk for processing. */ 65/* Add a new DATA chunk for processing. */
diff --git a/net/sctp/associola.c b/net/sctp/associola.c
index fa82b73c965b..2505cd3b8d29 100644
--- a/net/sctp/associola.c
+++ b/net/sctp/associola.c
@@ -1063,6 +1063,12 @@ void sctp_assoc_update(struct sctp_association *asoc,
1063 */ 1063 */
1064 sctp_ssnmap_clear(asoc->ssnmap); 1064 sctp_ssnmap_clear(asoc->ssnmap);
1065 1065
1066 /* Flush the ULP reassembly and ordered queue.
1067 * Any data there will now be stale and will
1068 * cause problems.
1069 */
1070 sctp_ulpq_flush(&asoc->ulpq);
1071
1066 } else { 1072 } else {
1067 /* Add any peer addresses from the new association. */ 1073 /* Add any peer addresses from the new association. */
1068 list_for_each(pos, &new->peer.transport_addr_list) { 1074 list_for_each(pos, &new->peer.transport_addr_list) {
diff --git a/net/sctp/ulpqueue.c b/net/sctp/ulpqueue.c
index f4759a9bdaee..bfb197e37da3 100644
--- a/net/sctp/ulpqueue.c
+++ b/net/sctp/ulpqueue.c
@@ -73,7 +73,7 @@ struct sctp_ulpq *sctp_ulpq_init(struct sctp_ulpq *ulpq,
73 73
74 74
75/* Flush the reassembly and ordering queues. */ 75/* Flush the reassembly and ordering queues. */
76static void sctp_ulpq_flush(struct sctp_ulpq *ulpq) 76void sctp_ulpq_flush(struct sctp_ulpq *ulpq)
77{ 77{
78 struct sk_buff *skb; 78 struct sk_buff *skb;
79 struct sctp_ulpevent *event; 79 struct sctp_ulpevent *event;