<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 12 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.MsoAcetate, li.MsoAcetate, div.MsoAcetate
        {mso-style-priority:99;
        mso-style-link:"Balloon Text Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:8.0pt;
        font-family:"Tahoma","sans-serif";}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
        {mso-style-priority:34;
        margin-top:0in;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:.5in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
span.EmailStyle18
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle19
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle20
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.BalloonTextChar
        {mso-style-name:"Balloon Text Char";
        mso-style-priority:99;
        mso-style-link:"Balloon Text";
        font-family:"Tahoma","sans-serif";}
span.EmailStyle23
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="color:#1F497D">Hi Ilan,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">My comments are below:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Sandeep D.S<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif""> Peer, Ilan [mailto:ilan.peer@intel.com]
<br>
<b>Sent:</b> Sunday, September 20, 2015 12:35 PM<br>
<b>To:</b> Shanbhag, Sandeep; hostap@lists.shmoo.com; j@w1.fi<br>
<b>Subject:</b> RE: wpa_supplicant support multiple WiFi Direct Groups [GO (2.4 GHz) + GO (5 GHz)]<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span style="color:#1F497D">Hi, <o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Tried to answer some of the questions below.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Ilan.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<div style="border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt">
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif"">
<a href="mailto:hostap-bounces@lists.shmoo.com">hostap-bounces@lists.shmoo.com</a> [<a href="mailto:hostap-bounces@lists.shmoo.com">mailto:hostap-bounces@lists.shmoo.com</a>]
<b>On Behalf Of </b>Shanbhag, Sandeep<br>
<b>Sent:</b> Saturday, September 19, 2015 07:43<br>
<b>To:</b> <a href="mailto:hostap@lists.shmoo.com">hostap@lists.shmoo.com</a>; <a href="mailto:j@w1.fi">
j@w1.fi</a><br>
<b>Subject:</b> wpa_supplicant support multiple WiFi Direct Groups [GO (2.4 GHz) + GO (5 GHz)]<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Hello,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">We have a requirement to support 2 P2P Autonomous Group Owner instances: GO (2.4 GHz) + GO (5 GHz) with a single chip.<o:p></o:p></p>
<p class="MsoNormal">So we were considering using a single wpa_supplicant instance running on the 2 P2P interfaces and while analyzing this option we found the below limitation in supplicant:<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">The P2P data structure sits inside the global data structure and not directly inside the wpa_s structure which is per interface.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">wpas_p2p_init()<o:p></o:p></p>
<p class="MsoNormal">{<o:p></o:p></p>
<p class="MsoNormal"><b><span style="color:#0070C0">                if (global->p2p)<o:p></o:p></span></b></p>
<p class="MsoNormal"><b><span style="color:#0070C0">                                return 0;<o:p></o:p></span></b></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">                global->p2p = p2p_init(&p2p);<o:p></o:p></p>
<p class="MsoNormal">}<o:p></o:p></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:yellow;mso-highlight:yellow">P2P architecture defines a single P2P Device entity that is responsible for managing the P2P Device operations/flows, and one or more entities that can be used to manage
 P2P GOs and/or P2P clients. The above function is used to initialize a P2P Device context and not the P2P GOs/Clients, i.e., if you have a HW that can support several P2P GOs then the wpa_supplicant is already designed to support operating several P2P groups,
 each managed by its own wpa_supplicant interface instance.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">Understand this part, that was exactly my understanding of the supplicant design, that of a single P2P Device entity which can support multiple P2P-Groups with their own interfaces
 of course.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal">Due to this if we want to add multiple p2p<span style="color:#1F497D">
</span>interfaces representing multiple P2P Device Discovery Interface then it does not become possible as it gets returned from this function.<o:p></o:p></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:yellow;mso-highlight:yellow">Adding a P2P group interface should not call this function.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">This was more from the perspective that if each GO is supposed to have an associated unique Device entity.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">Say if this single P2P Device entity does not suit the case of hosting multiple groups then there must be a way to add multiple P2P Device entity each being able to host its
 own group.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">Below I will bring out the reason for such a need.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Is there any particular reason why p2p structure was part of global structure and not part of interface specific wpa_s structure?<span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal">Do you have any plans to extend this to move inside wpa_s structure in order to support multiple P2P interfaces?<o:p></o:p></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:yellow;mso-highlight:yellow">As explain above, multiple P2P Group interfaces are already supported.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal">Our requirement is to start 2 Autonomous Group Owners and on analysis we find that the P2P Device Address is not of much relevance once a P2P Device assumes the role of P2P-Group Owner as all frames use P2P-Interface Address for communication.<o:p></o:p></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:yellow;mso-highlight:yellow">P2P Device does not assume the role of a P2P GO. However, it is possible that the same wpa_supplicant interface that is used to managed the P2P Device operations is also
 used for managing the P2P GO operations.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">Yes, what I meant was that P2P Device starts a new GO on a new interface.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">WFD Spec also says that the P2P Device Address itself can be used as Interface Address provided it is either universally unique MAC or universally unique MAC with its locally
 administered bit set.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">But I think with this design it is not possible as a separate Interface needs to be created for the GO which should have a different MAC address than the P2P Device Address.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal">Is the rationale behind having p2p structure inside global is thinking that a single unique P2P Device Address is sufficient to create multiple groups with their own unique interface addresses?<span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal">Please let us know if our understanding matches with yours and if this is the reason why a single instance of p2p structure is allowed by making it part of the global structure.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">If this was indeed the reason then we have one issue that the peer devices (based on wpa_supplicant) keeps overwriting the this device during discovery as the Supplicant’s logic to add a peer is based on device address from within the P2P-IE
 and not based on Interface Address. So the peer devices will either see the 2.4 GHz GO or 5 GHz GO and not both.<o:p></o:p></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:yellow;mso-highlight:yellow">Not sure I fully understand, but this is the expected behavior, as the both P2P GOs are tied to the same P2P Device context, so eventually in the P2P Device list you should
 have only a single entry representing the remote P2P Device. There might be an issue with the P2P Device structure that does not handle the possibility that that a single P2P Device can be a client in several P2P groups, but this can clearly be extended if
 needed.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">IMHO, this behavior beats the whole purpose of somebody trying to create multiple groups using a single supplicant. The reason somebody wants to create more than one group is
 so that the remote device sees these multiple groups as different groups and should be able to connect to whichever it chooses to connect. But with this single device entity it does not become possible due to the reasons mentioned above.<o:p></o:p></span></p>
<p class="MsoNormal"><b><u><span style="color:#1F497D;background:aqua;mso-highlight:aqua">For Ex:
</span></u></b><span style="color:#1F497D;background:aqua;mso-highlight:aqua">If there are 2 groups created using a single supplicant say: Group-A (on 2.4 GHz Channel) and Group-B (on 5 GHz Channel).<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">Now a dual band mobile phone should be able to see both the groups in its WiFi Direct Discovery Screen and then should be able to make a choice of whether to connect to Group-A
 or Group-B.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">But due to the same P2P-Device Address used by both the groups the remote device can at a time either see Group-A or Group-B.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">Also consider a case when there are 2 WiFi chips and a single supplicant needs to create one group on each of the chip then at least 2 P2P Device Entities are required.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D;background:aqua;mso-highlight:aqua">So this problem can be solved by either bringing P2P structure out of global and making it part of wpa_s structure or by changing the logic of peer addition based not only on
 Device Address but some also may be the group’s interface address.</span><span style="color:#1F497D"><o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal">I know that the device address stays same across multiple persistency sessions but the interface addresses of devices can change, this could be one of the reasons to base peer entry on device address.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">If you think that it makes sense for a single device to host 2 groups with a single device address and if this was one of the reasons to have a single P2P Discovery Interface then please consider also changing the logic of peer entry to
 also consider Interface address and not only device address.<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Regards,<o:p></o:p></p>
<p class="MsoNormal">Sandeep D.S<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</div>
</body>
</html>