Re: [PATCH net-next v12 11/22] ovpn: implement TCP transport

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 04/12/2024 12:15, Antonio Quartulli wrote:
[...]
+static void ovpn_tcp_close(struct sock *sk, long timeout)
+{
+    struct ovpn_socket *sock;
+
+    rcu_read_lock();
+    sock = rcu_dereference_sk_user_data(sk);
+
+    strp_stop(&sock->peer->tcp.strp);
+    barrier();

Again, is not clear to me the role of the above barrier, please document it.

Also taken from espintcp_close(), with the idea to avoid reordering during the shut down sequence.

Will add a comment here too.

Actually, after checking this specific barrier(), I realized this is not needed, because we are doing the socket detach later, after calling the ovpn_peer_del() (which is different from what is happening in espintcp).

So I'll just drop this barrier here.

Regards,

--
Antonio Quartulli
OpenVPN Inc.





[Index of Archives]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]

  Powered by Linux