Lines Matching refs:clcsock
113 smc->clcsock->sk->sk_prot->keepalive(smc->clcsock->sk, val); in smc_set_keepalive()
248 struct sock *clcsk = smc->clcsock->sk; in smc_fback_restore_callbacks()
263 if (smc->clcsock->file) { /* non-accepted sockets have no file yet */ in smc_restore_fallback_changes()
264 smc->clcsock->file->private_data = smc->sk.sk_socket; in smc_restore_fallback_changes()
265 smc->clcsock->file = NULL; in smc_restore_fallback_changes()
286 rc = kernel_sock_shutdown(smc->clcsock, in __smc_release()
298 if (smc->clcsock) { in __smc_release()
326 tcp_abort(smc->clcsock->sk, ECONNABORTED); in smc_release()
429 smc->clcsock->sk->sk_reuse = sk->sk_reuse; in smc_bind()
430 rc = kernel_bind(smc->clcsock, uaddr, addr_len); in smc_bind()
477 smc_copy_sock_settings(smc->clcsock->sk, &smc->sk, SK_FLAGS_SMC_TO_CLC); in smc_copy_sock_settings_to_clc()
487 smc_copy_sock_settings(&smc->sk, smc->clcsock->sk, SK_FLAGS_CLC_TO_SMC); in smc_copy_sock_settings_to_smc()
812 struct sock *clcsk = smc->clcsock->sk; in smc_fback_replace_callbacks()
834 if (!smc->clcsock) { in smc_switch_to_fallback()
844 smc->clcsock->file = smc->sk.sk_socket->file; in smc_switch_to_fallback()
845 smc->clcsock->file->private_data = smc->clcsock; in smc_switch_to_fallback()
846 smc->clcsock->wq.fasync_list = in smc_switch_to_fallback()
927 smc_pnet_find_roce_resource(smc->clcsock->sk, ini); in smc_find_rdma_device()
940 smc_pnet_find_ism_resource(smc->clcsock->sk, ini); in smc_find_ism_device()
1037 ini->smcrv2.saddr = smc->clcsock->sk->sk_rcv_saddr; in smc_find_proposal_devices()
1039 smc->clcsock->sk->sk_family != AF_INET || in smc_find_proposal_devices()
1134 if (smc_ib_find_route(smc->clcsock->sk->sk_rcv_saddr, in smc_connect_rdma_v2_prepare()
1398 if (!tcp_sk(smc->clcsock->sk)->syn_smc) in __smc_connect()
1417 if (smc_vlan_by_tcpsk(smc->clcsock, ini)) { in __smc_connect()
1467 SMC_STAT_CLNT_SUCC_INC(sock_net(smc->clcsock->sk), aclc); in __smc_connect()
1490 lock_sock(smc->clcsock->sk); in smc_connect_work()
1491 if (smc->clcsock->sk->sk_err) { in smc_connect_work()
1492 smc->sk.sk_err = smc->clcsock->sk->sk_err; in smc_connect_work()
1493 } else if ((1 << smc->clcsock->sk->sk_state) & in smc_connect_work()
1495 rc = sk_stream_wait_connect(smc->clcsock->sk, &timeo); in smc_connect_work()
1497 ((1 << smc->clcsock->sk->sk_state) & in smc_connect_work()
1501 release_sock(smc->clcsock->sk); in smc_connect_work()
1524 smc->clcsock->sk->sk_write_space(smc->clcsock->sk); in smc_connect_work()
1578 tcp_sk(smc->clcsock->sk)->syn_smc = 1; in smc_connect()
1583 rc = kernel_connect(smc->clcsock, addr, alen, flags); in smc_connect()
1631 if (lsmc->clcsock) in smc_clcsock_accept()
1632 rc = kernel_accept(lsmc->clcsock, &new_clcsock, SOCK_NONBLOCK); in smc_clcsock_accept()
1665 (*new_smc)->clcsock = new_clcsock; in smc_clcsock_accept()
1711 if (isk->clcsock) { in smc_accept_dequeue()
1712 sock_release(isk->clcsock); in smc_accept_dequeue()
1713 isk->clcsock = NULL; in smc_accept_dequeue()
1722 smc_sk(new_sk)->clcsock->file = new_sock->file; in smc_accept_dequeue()
1723 isk->clcsock->file->private_data = isk->clcsock; in smc_accept_dequeue()
1794 if (tcp_sk(new_smc->clcsock->sk)->syn_smc) in smc_listen_out()
1919 struct socket *newclcsock = new_smc->clcsock; in smc_listen_prfx_check()
2140 ini->smcrv2.clc_sk = new_smc->clcsock->sk; in smc_find_rdma_v2_device_serv()
2141 ini->smcrv2.saddr = new_smc->clcsock->sk->sk_rcv_saddr; in smc_find_rdma_v2_device_serv()
2209 if (smc_vlan_by_tcpsk(new_smc->clcsock, ini)) in smc_listen_find_device()
2270 struct socket *newclcsock = new_smc->clcsock; in smc_listen_work()
2402 if (tcp_sk(new_smc->clcsock->sk)->syn_smc) in smc_tcp_listen_work()
2465 tcp_sk(smc->clcsock->sk)->syn_smc = 1; in smc_listen()
2470 write_lock_bh(&smc->clcsock->sk->sk_callback_lock); in smc_listen()
2471 smc->clcsock->sk->sk_user_data = in smc_listen()
2473 smc_clcsock_replace_cb(&smc->clcsock->sk->sk_data_ready, in smc_listen()
2475 write_unlock_bh(&smc->clcsock->sk->sk_callback_lock); in smc_listen()
2478 smc->ori_af_ops = inet_csk(smc->clcsock->sk)->icsk_af_ops; in smc_listen()
2483 inet_csk(smc->clcsock->sk)->icsk_af_ops = &smc->af_ops; in smc_listen()
2486 tcp_sk(smc->clcsock->sk)->smc_hs_congested = smc_hs_congested; in smc_listen()
2488 rc = kernel_listen(smc->clcsock, backlog); in smc_listen()
2490 write_lock_bh(&smc->clcsock->sk->sk_callback_lock); in smc_listen()
2491 smc_clcsock_restore_cb(&smc->clcsock->sk->sk_data_ready, in smc_listen()
2493 smc->clcsock->sk->sk_user_data = NULL; in smc_listen()
2494 write_unlock_bh(&smc->clcsock->sk->sk_callback_lock); in smc_listen()
2558 struct sock *clcsk = smc_sk(nsk)->clcsock->sk; in smc_accept()
2587 return smc->clcsock->ops->getname(smc->clcsock, addr, peer); in smc_getname()
2615 rc = smc->clcsock->ops->sendmsg(smc->clcsock, msg, len); in smc_sendmsg()
2650 rc = smc->clcsock->ops->recvmsg(smc->clcsock, msg, len, flags); in smc_recvmsg()
2688 mask = smc->clcsock->ops->poll(file, smc->clcsock, wait); in smc_poll()
2689 sk->sk_err = smc->clcsock->sk->sk_err; in smc_poll()
2702 mask |= smc->clcsock->ops->poll(file, smc->clcsock, in smc_poll()
2704 sk->sk_err = smc->clcsock->sk->sk_err; in smc_poll()
2764 rc = kernel_sock_shutdown(smc->clcsock, how); in smc_shutdown()
2765 sk->sk_shutdown = smc->clcsock->sk->sk_shutdown; in smc_shutdown()
2789 if (do_shutdown && smc->clcsock) in smc_shutdown()
2790 rc1 = kernel_sock_shutdown(smc->clcsock, how); in smc_shutdown()
2886 if (!smc->clcsock) { in smc_setsockopt()
2890 if (unlikely(!smc->clcsock->ops->setsockopt)) in smc_setsockopt()
2893 rc = smc->clcsock->ops->setsockopt(smc->clcsock, level, optname, in smc_setsockopt()
2895 if (smc->clcsock->sk->sk_err) { in smc_setsockopt()
2896 sk->sk_err = smc->clcsock->sk->sk_err; in smc_setsockopt()
2966 if (!smc->clcsock) { in smc_getsockopt()
2971 if (unlikely(!smc->clcsock->ops->getsockopt)) { in smc_getsockopt()
2975 rc = smc->clcsock->ops->getsockopt(smc->clcsock, level, optname, in smc_getsockopt()
2993 if (!smc->clcsock) { in smc_ioctl()
2997 answ = smc->clcsock->ops->ioctl(smc->clcsock, cmd, arg); in smc_ioctl()
3077 rc = kernel_sendpage(smc->clcsock, page, offset, in smc_sendpage()
3122 rc = smc->clcsock->ops->splice_read(smc->clcsock, ppos, in smc_splice_read()
3166 int kern, struct socket *clcsock) in __smc_create() argument
3197 if (!clcsock) { in __smc_create()
3199 &smc->clcsock); in __smc_create()
3205 smc->clcsock = clcsock; in __smc_create()
3208 smc->sk.sk_sndbuf = max(smc->clcsock->sk->sk_sndbuf, SMC_BUF_MIN_SIZE); in __smc_create()
3209 smc->sk.sk_rcvbuf = max(smc->clcsock->sk->sk_rcvbuf, SMC_BUF_MIN_SIZE); in __smc_create()