{
/* If we have a known transport, use that. */
if (chunk->transport) {
- return &chunk->transport->ipaddr_h;
+ return &chunk->transport->ipaddr;
} else {
/* Otherwise, extract it from the IP header. */
- return &chunk->source_h;
+ return &chunk->source;
}
}
struct sctp_transport *transport;
struct list_head *pos, *temp;
char *cookie;
- union sctp_addr tmp;
/* We must include the address that the INIT packet came from.
* This is the only address that matters for an INIT packet.
* be a a better choice than any of the embedded addresses.
*/
if (peer_addr) {
- flip_to_n(&tmp, peer_addr);
- if(!sctp_assoc_add_peer(asoc, &tmp, gfp, SCTP_ACTIVE))
+ if(!sctp_assoc_add_peer(asoc, peer_addr, gfp, SCTP_ACTIVE))
goto nomem;
}
union sctp_addr addr;
struct list_head *pos;
union sctp_addr_param *addr_param;
- union sctp_addr tmp;
addr_param = (union sctp_addr_param *)
((void *)asconf_param + sizeof(sctp_addip_param_t));
* an Error Cause TLV set to the new error code 'Request to
* Delete Source IP Address'
*/
- flip_to_n(&tmp, sctp_source(asconf));
- if (sctp_cmp_addr_exact(&tmp, &addr))
+ if (sctp_cmp_addr_exact(sctp_source(asconf), &addr))
return SCTP_ERROR_DEL_SRC_IP;
sctp_assoc_del_peer(asoc, &addr);
struct sctp_ulpevent *ev, *ai_ev = NULL;
int error = 0;
struct sctp_chunk *err_chk_p;
- union sctp_addr tmp;
/* If the packet is an OOTB packet which is temporarily on the
* control endpoint, respond with an ABORT.
*/
peer_init = &chunk->subh.cookie_hdr->c.peer_init[0];
- flip_to_h(&tmp, &chunk->subh.cookie_hdr->c.peer_addr);
if (!sctp_process_init(new_asoc, chunk->chunk_hdr->type,
- &tmp,
+ &chunk->subh.cookie_hdr->c.peer_addr,
peer_init, GFP_ATOMIC))
goto nomem_init;
__u16 sport;
__u16 dport;
__u32 vtag;
- union sctp_addr tmp;
/* Get the source and destination port from the inbound packet. */
sport = ntohs(chunk->sctp_hdr->dest);
}
/* Make a transport for the bucket, Eliza... */
- flip_to_n(&tmp, sctp_source(chunk));
- transport = sctp_transport_new(&tmp, GFP_ATOMIC);
+ transport = sctp_transport_new(sctp_source(chunk), GFP_ATOMIC);
if (!transport)
goto nomem;