From mboxrd@z Thu Jan 1 00:00:00 1970 From: Santosh Shilimkar Subject: Re: [PATCH net-next 2/3] rds: Enable RDS IPv6 support Date: Mon, 25 Jun 2018 11:44:15 -0700 Message-ID: <5231a07e-0181-41c6-99ba-4dc7fbe6afad@oracle.com> References: <7f4f460079d3d78a18f7d759488048798e99c4db.1529922794.git.ka-cheong.poon@oracle.com> <20180625170317.GA28578@oracle.com> <25e1afda-7497-7f08-815a-286cf775bc09@oracle.com> <20180625175006.GI14823@oracle.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, davem@davemloft.net, rds-devel@oss.oracle.com To: Sowmini Varadhan , Ka-Cheong Poon Return-path: Received: from userp2130.oracle.com ([156.151.31.86]:36128 "EHLO userp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964860AbeFYSoX (ORCPT ); Mon, 25 Jun 2018 14:44:23 -0400 In-Reply-To: <20180625175006.GI14823@oracle.com> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: On 6/25/2018 10:50 AM, Sowmini Varadhan wrote: > On (06/26/18 01:43), Ka-Cheong Poon wrote: >> >> Yes, I think if the socket is bound, it should check the scope_id >> in msg_name (if not NULL) to make sure that they match. A bound >> RDS socket can send to multiple peers. But if the bound local >> address is link local, it should only be allowed to send to peers >> on the same link. > > agree. Yep. Its inline with RDS bind behavior. > > >> If a socket is bound, I guess the scope_id should be used. So >> if a socket is not bound to a link local address and the socket >> is used to sent to a link local peer, it should fail. > > PF_RDS sockets *MUST* alwasy be bound. See > Documentation/networking/rds.txt: > " Sockets must be bound before you can send or receive data. > This is needed because binding also selects a transport and > attaches it to the socket. Once bound, the transport assignment > does not change." > In any case link local or not, the socket needs to be bound before any data can be sent as documented. Send path already enforces it. >>> Also, why is there no IPv6 support in rds_connect? >> >> >> Oops, I missed this when I ported the internal version to the >> net-next version. Will add it back. > So the net-next wasn't tested? IPv6 connections itself wouldn't be formed with this missing. As mentioned already, please test v2 before posting on list. Regards, Santosh