Lines Matching refs:srx
77 struct sockaddr_rxrpc *srx, in rxrpc_validate_address() argument
85 if (srx->srx_family != AF_RXRPC) in rxrpc_validate_address()
88 if (srx->transport_type != SOCK_DGRAM) in rxrpc_validate_address()
92 if (srx->transport_len < sizeof(sa_family_t) || in rxrpc_validate_address()
93 srx->transport_len > len) in rxrpc_validate_address()
96 if (srx->transport.family != rx->family && in rxrpc_validate_address()
97 srx->transport.family == AF_INET && rx->family != AF_INET6) in rxrpc_validate_address()
100 switch (srx->transport.family) { in rxrpc_validate_address()
102 if (srx->transport_len < sizeof(struct sockaddr_in)) in rxrpc_validate_address()
109 if (srx->transport_len < sizeof(struct sockaddr_in6)) in rxrpc_validate_address()
121 memset((void *)srx + tail, 0, len - tail); in rxrpc_validate_address()
122 _debug("INET: %pISp", &srx->transport); in rxrpc_validate_address()
131 struct sockaddr_rxrpc *srx = (struct sockaddr_rxrpc *)saddr; in rxrpc_bind() local
139 ret = rxrpc_validate_address(rx, srx, len); in rxrpc_bind()
142 service_id = srx->srx_service; in rxrpc_bind()
148 rx->srx = *srx; in rxrpc_bind()
149 local = rxrpc_lookup_local(sock_net(&rx->sk), &rx->srx); in rxrpc_bind()
175 if (service_id == rx->srx.srx_service) in rxrpc_bind()
178 srx->srx_service = rx->srx.srx_service; in rxrpc_bind()
179 if (memcmp(srx, &rx->srx, sizeof(*srx)) != 0) in rxrpc_bind()
281 struct sockaddr_rxrpc *srx, in rxrpc_kernel_begin_call() argument
299 ret = rxrpc_validate_address(rx, srx, sizeof(*srx)); in rxrpc_kernel_begin_call()
322 cp.service_id = srx->srx_service; in rxrpc_kernel_begin_call()
323 call = rxrpc_new_client_call(rx, &cp, srx, &p, gfp, debug_id); in rxrpc_kernel_begin_call()
453 struct sockaddr_rxrpc *srx = (struct sockaddr_rxrpc *)addr; in rxrpc_connect() local
459 ret = rxrpc_validate_address(rx, srx, addr_len); in rxrpc_connect()
483 rx->connect_srx = *srx; in rxrpc_connect()
525 rx->srx.srx_family = AF_RXRPC; in rxrpc_sendmsg()
526 rx->srx.srx_service = 0; in rxrpc_sendmsg()
527 rx->srx.transport_type = SOCK_DGRAM; in rxrpc_sendmsg()
528 rx->srx.transport.family = rx->family; in rxrpc_sendmsg()
531 rx->srx.transport_len = sizeof(struct sockaddr_in); in rxrpc_sendmsg()
535 rx->srx.transport_len = sizeof(struct sockaddr_in6); in rxrpc_sendmsg()
542 local = rxrpc_lookup_local(sock_net(sock->sk), &rx->srx); in rxrpc_sendmsg()
667 if ((service_upgrade[0] != rx->srx.srx_service || in rxrpc_setsockopt()
670 service_upgrade[1] != rx->srx.srx_service)) in rxrpc_setsockopt()
787 memset(&rx->srx, 0, sizeof(rx->srx)); in rxrpc_create()