unsigned int __nocast gfp) 
gfp_t gfp) 
struct sctp_ulpevent *sctp_ulpevent_make_rcvmsg(struct sctp_association *asoc,						struct sctp_chunk *chunk,						unsigned int __nocast gfp){	struct sctp_ulpevent *event = NULL;	struct sk_buff *skb;	size_t padding, len;	/* Clone the original skb, sharing the data.  */	skb = skb_clone(chunk->skb, gfp);	if (!skb)		goto fail;	/* First calculate the padding, so we don't inadvertently	 * pass up the wrong length to the user.	 *	 * RFC 2960 - Section 3.2  Chunk Field Descriptions	 *	 * The total length of a chunk(including Type, Length and Value fields)	 * MUST be a multiple of 4 bytes.  If the length of the chunk is not a	 * multiple of 4 bytes, the sender MUST pad the chunk with all zero	 * bytes and this padding is not included in the chunk length field.	 * The sender should never pad with more than 3 bytes.  The receiver	 * MUST ignore the padding bytes.	 */	len = ntohs(chunk->chunk_hdr->length);	padding = WORD_ROUND(len) - len;	/* Fixup cloned skb with just this chunks data.  */	skb_trim(skb, chunk->chunk_end - padding - skb->data);	/* Embed the event fields inside the cloned skb.  */	event = sctp_skb2event(skb);	/* Initialize event with flags 0.  */	sctp_ulpevent_init(event, 0);	sctp_ulpevent_receive_data(event, asoc);	event->stream = ntohs(chunk->subh.data_hdr->stream);	event->ssn = ntohs(chunk->subh.data_hdr->ssn);	event->ppid = chunk->subh.data_hdr->ppid;	if (chunk->chunk_hdr->flags & SCTP_DATA_UNORDERED) {		event->flags |= MSG_UNORDERED;		event->cumtsn = sctp_tsnmap_get_ctsn(&asoc->peer.tsn_map);	}	event->tsn = ntohl(chunk->subh.data_hdr->tsn);	event->msg_flags |= chunk->chunk_hdr->flags;	event->iif = sctp_chunk_iif(chunk);fail:	return event;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/dd0fc66fb33cd610bc1a5db8a5e232d34879b4d7/ulpevent.c/buggy/net/sctp/ulpevent.c