diff options
Diffstat (limited to 'include/net/sctp/ulpevent.h')
-rw-r--r-- | include/net/sctp/ulpevent.h | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/include/net/sctp/ulpevent.h b/include/net/sctp/ulpevent.h index 231dc42f1da6..51b4e0626c34 100644 --- a/include/net/sctp/ulpevent.h +++ b/include/net/sctp/ulpevent.h | |||
@@ -45,19 +45,29 @@ | |||
45 | /* A structure to carry information to the ULP (e.g. Sockets API) */ | 45 | /* A structure to carry information to the ULP (e.g. Sockets API) */ |
46 | /* Warning: This sits inside an skb.cb[] area. Be very careful of | 46 | /* Warning: This sits inside an skb.cb[] area. Be very careful of |
47 | * growing this structure as it is at the maximum limit now. | 47 | * growing this structure as it is at the maximum limit now. |
48 | * | ||
49 | * sctp_ulpevent is saved in sk->cb(48 bytes), whose last 4 bytes | ||
50 | * have been taken by sock_skb_cb, So here it has to use 'packed' | ||
51 | * to make sctp_ulpevent fit into the rest 44 bytes. | ||
48 | */ | 52 | */ |
49 | struct sctp_ulpevent { | 53 | struct sctp_ulpevent { |
50 | struct sctp_association *asoc; | 54 | struct sctp_association *asoc; |
51 | struct sctp_chunk *chunk; | 55 | struct sctp_chunk *chunk; |
52 | unsigned int rmem_len; | 56 | unsigned int rmem_len; |
53 | __u32 ppid; | 57 | union { |
58 | __u32 mid; | ||
59 | __u16 ssn; | ||
60 | }; | ||
61 | union { | ||
62 | __u32 ppid; | ||
63 | __u32 fsn; | ||
64 | }; | ||
54 | __u32 tsn; | 65 | __u32 tsn; |
55 | __u32 cumtsn; | 66 | __u32 cumtsn; |
56 | __u16 stream; | 67 | __u16 stream; |
57 | __u16 ssn; | ||
58 | __u16 flags; | 68 | __u16 flags; |
59 | __u16 msg_flags; | 69 | __u16 msg_flags; |
60 | }; | 70 | } __packed; |
61 | 71 | ||
62 | /* Retrieve the skb this event sits inside of. */ | 72 | /* Retrieve the skb this event sits inside of. */ |
63 | static inline struct sk_buff *sctp_event2skb(const struct sctp_ulpevent *ev) | 73 | static inline struct sk_buff *sctp_event2skb(const struct sctp_ulpevent *ev) |
@@ -112,7 +122,8 @@ struct sctp_ulpevent *sctp_ulpevent_make_shutdown_event( | |||
112 | 122 | ||
113 | struct sctp_ulpevent *sctp_ulpevent_make_pdapi( | 123 | struct sctp_ulpevent *sctp_ulpevent_make_pdapi( |
114 | const struct sctp_association *asoc, | 124 | const struct sctp_association *asoc, |
115 | __u32 indication, gfp_t gfp); | 125 | __u32 indication, __u32 sid, __u32 seq, |
126 | __u32 flags, gfp_t gfp); | ||
116 | 127 | ||
117 | struct sctp_ulpevent *sctp_ulpevent_make_adaptation_indication( | 128 | struct sctp_ulpevent *sctp_ulpevent_make_adaptation_indication( |
118 | const struct sctp_association *asoc, gfp_t gfp); | 129 | const struct sctp_association *asoc, gfp_t gfp); |
@@ -140,6 +151,10 @@ struct sctp_ulpevent *sctp_ulpevent_make_stream_change_event( | |||
140 | const struct sctp_association *asoc, __u16 flags, | 151 | const struct sctp_association *asoc, __u16 flags, |
141 | __u32 strchange_instrms, __u32 strchange_outstrms, gfp_t gfp); | 152 | __u32 strchange_instrms, __u32 strchange_outstrms, gfp_t gfp); |
142 | 153 | ||
154 | struct sctp_ulpevent *sctp_make_reassembled_event( | ||
155 | struct net *net, struct sk_buff_head *queue, | ||
156 | struct sk_buff *f_frag, struct sk_buff *l_frag); | ||
157 | |||
143 | void sctp_ulpevent_read_sndrcvinfo(const struct sctp_ulpevent *event, | 158 | void sctp_ulpevent_read_sndrcvinfo(const struct sctp_ulpevent *event, |
144 | struct msghdr *); | 159 | struct msghdr *); |
145 | void sctp_ulpevent_read_rcvinfo(const struct sctp_ulpevent *event, | 160 | void sctp_ulpevent_read_rcvinfo(const struct sctp_ulpevent *event, |