aboutsummaryrefslogtreecommitdiffstats
path: root/net/sctp/associola.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sctp/associola.c')
-rw-r--r--net/sctp/associola.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/net/sctp/associola.c b/net/sctp/associola.c
index 746b0b0f5ace..83318e727905 100644
--- a/net/sctp/associola.c
+++ b/net/sctp/associola.c
@@ -442,7 +442,7 @@ void sctp_assoc_set_primary(struct sctp_association *asoc,
442 asoc->peer.primary_path = transport; 442 asoc->peer.primary_path = transport;
443 443
444 /* Set a default msg_name for events. */ 444 /* Set a default msg_name for events. */
445 memcpy(&asoc->peer.primary_addr, &transport->ipaddr, 445 memcpy(&asoc->peer.primary_addr, &transport->ipaddr_h,
446 sizeof(union sctp_addr)); 446 sizeof(union sctp_addr));
447 447
448 /* If the primary path is changing, assume that the 448 /* If the primary path is changing, assume that the
@@ -487,8 +487,8 @@ void sctp_assoc_rm_peer(struct sctp_association *asoc,
487 SCTP_DEBUG_PRINTK_IPADDR("sctp_assoc_rm_peer:association %p addr: ", 487 SCTP_DEBUG_PRINTK_IPADDR("sctp_assoc_rm_peer:association %p addr: ",
488 " port: %d\n", 488 " port: %d\n",
489 asoc, 489 asoc,
490 (&peer->ipaddr), 490 (&peer->ipaddr_h),
491 peer->ipaddr.v4.sin_port); 491 peer->ipaddr_h.v4.sin_port);
492 492
493 /* If we are to remove the current retran_path, update it 493 /* If we are to remove the current retran_path, update it
494 * to the next peer before removing this peer from the list. 494 * to the next peer before removing this peer from the list.
@@ -669,7 +669,7 @@ void sctp_assoc_del_peer(struct sctp_association *asoc,
669 669
670 list_for_each_safe(pos, temp, &asoc->peer.transport_addr_list) { 670 list_for_each_safe(pos, temp, &asoc->peer.transport_addr_list) {
671 transport = list_entry(pos, struct sctp_transport, transports); 671 transport = list_entry(pos, struct sctp_transport, transports);
672 if (sctp_cmp_addr_exact(addr, &transport->ipaddr)) { 672 if (sctp_cmp_addr_exact(addr, &transport->ipaddr_h)) {
673 /* Do book keeping for removing the peer and free it. */ 673 /* Do book keeping for removing the peer and free it. */
674 sctp_assoc_rm_peer(asoc, transport); 674 sctp_assoc_rm_peer(asoc, transport);
675 break; 675 break;
@@ -689,7 +689,7 @@ struct sctp_transport *sctp_assoc_lookup_paddr(
689 689
690 list_for_each(pos, &asoc->peer.transport_addr_list) { 690 list_for_each(pos, &asoc->peer.transport_addr_list) {
691 t = list_entry(pos, struct sctp_transport, transports); 691 t = list_entry(pos, struct sctp_transport, transports);
692 if (sctp_cmp_addr_exact(address, &t->ipaddr)) 692 if (sctp_cmp_addr_exact(address, &t->ipaddr_h))
693 return t; 693 return t;
694 } 694 }
695 695
@@ -733,7 +733,7 @@ void sctp_assoc_control_transport(struct sctp_association *asoc,
733 * user. 733 * user.
734 */ 734 */
735 memset(&addr, 0, sizeof(struct sockaddr_storage)); 735 memset(&addr, 0, sizeof(struct sockaddr_storage));
736 flip_to_n((union sctp_addr *)&addr, &transport->ipaddr); 736 flip_to_n((union sctp_addr *)&addr, &transport->ipaddr_h);
737 event = sctp_ulpevent_make_peer_addr_change(asoc, &addr, 737 event = sctp_ulpevent_make_peer_addr_change(asoc, &addr,
738 0, spc_state, error, GFP_ATOMIC); 738 0, spc_state, error, GFP_ATOMIC);
739 if (event) 739 if (event)
@@ -1043,8 +1043,8 @@ void sctp_assoc_update(struct sctp_association *asoc,
1043 /* Remove any peer addresses not present in the new association. */ 1043 /* Remove any peer addresses not present in the new association. */
1044 list_for_each_safe(pos, temp, &asoc->peer.transport_addr_list) { 1044 list_for_each_safe(pos, temp, &asoc->peer.transport_addr_list) {
1045 trans = list_entry(pos, struct sctp_transport, transports); 1045 trans = list_entry(pos, struct sctp_transport, transports);
1046 if (!sctp_assoc_lookup_paddr(new, &trans->ipaddr)) 1046 if (!sctp_assoc_lookup_paddr(new, &trans->ipaddr_h))
1047 sctp_assoc_del_peer(asoc, &trans->ipaddr); 1047 sctp_assoc_del_peer(asoc, &trans->ipaddr_h);
1048 } 1048 }
1049 1049
1050 /* If the case is A (association restart), use 1050 /* If the case is A (association restart), use
@@ -1067,8 +1067,8 @@ void sctp_assoc_update(struct sctp_association *asoc,
1067 list_for_each(pos, &new->peer.transport_addr_list) { 1067 list_for_each(pos, &new->peer.transport_addr_list) {
1068 trans = list_entry(pos, struct sctp_transport, 1068 trans = list_entry(pos, struct sctp_transport,
1069 transports); 1069 transports);
1070 if (!sctp_assoc_lookup_paddr(asoc, &trans->ipaddr)) 1070 if (!sctp_assoc_lookup_paddr(asoc, &trans->ipaddr_h))
1071 sctp_assoc_add_peer(asoc, &trans->ipaddr, 1071 sctp_assoc_add_peer(asoc, &trans->ipaddr_h,
1072 GFP_ATOMIC, trans->state); 1072 GFP_ATOMIC, trans->state);
1073 } 1073 }
1074 1074
@@ -1136,8 +1136,8 @@ void sctp_assoc_update_retran_path(struct sctp_association *asoc)
1136 " %p addr: ", 1136 " %p addr: ",
1137 " port: %d\n", 1137 " port: %d\n",
1138 asoc, 1138 asoc,
1139 (&t->ipaddr), 1139 (&t->ipaddr_h),
1140 t->ipaddr.v4.sin_port); 1140 t->ipaddr_h.v4.sin_port);
1141} 1141}
1142 1142
1143/* Choose the transport for sending a INIT packet. */ 1143/* Choose the transport for sending a INIT packet. */
@@ -1161,8 +1161,8 @@ struct sctp_transport *sctp_assoc_choose_init_transport(
1161 " %p addr: ", 1161 " %p addr: ",
1162 " port: %d\n", 1162 " port: %d\n",
1163 asoc, 1163 asoc,
1164 (&t->ipaddr), 1164 (&t->ipaddr_h),
1165 t->ipaddr.v4.sin_port); 1165 t->ipaddr_h.v4.sin_port);
1166 1166
1167 return t; 1167 return t;
1168} 1168}
@@ -1307,7 +1307,7 @@ int sctp_assoc_set_bind_addr_from_ep(struct sctp_association *asoc,
1307 /* Use scoping rules to determine the subset of addresses from 1307 /* Use scoping rules to determine the subset of addresses from
1308 * the endpoint. 1308 * the endpoint.
1309 */ 1309 */
1310 scope = sctp_scope(&asoc->peer.active_path->ipaddr); 1310 scope = sctp_scope(&asoc->peer.active_path->ipaddr_h);
1311 flags = (PF_INET6 == asoc->base.sk->sk_family) ? SCTP_ADDR6_ALLOWED : 0; 1311 flags = (PF_INET6 == asoc->base.sk->sk_family) ? SCTP_ADDR6_ALLOWED : 0;
1312 if (asoc->peer.ipv4_address) 1312 if (asoc->peer.ipv4_address)
1313 flags |= SCTP_ADDR4_PEERSUPP; 1313 flags |= SCTP_ADDR4_PEERSUPP;