<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:x="urn:schemas-microsoft-com:office:excel" xmlns:p="urn:schemas-microsoft-com:office:powerpoint" xmlns:a="urn:schemas-microsoft-com:office:access" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema" xmlns:b="urn:schemas-microsoft-com:office:publisher" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:oa="urn:schemas-microsoft-com:office:activation" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:q="http://schemas.xmlsoap.org/soap/envelope/" xmlns:D="DAV:" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ois="http://schemas.microsoft.com/sharepoint/soap/ois/" xmlns:dir="http://schemas.microsoft.com/sharepoint/soap/directory/" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" xmlns:udc="http://schemas.microsoft.com/data/udc" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sps="http://schemas.microsoft.com/sharepoint/soap/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:udcxf="http://schemas.microsoft.com/data/udc/xmlfile" xmlns:wf="http://schemas.microsoft.com/sharepoint/soap/workflow/" xmlns:mver="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:ex12t="http://schemas.microsoft.com/exchange/services/2006/types" 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)">
<!--[if !mso]>
<style>
v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style>
<![endif]-->
<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:12.0pt;
        font-family:"Times New Roman","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;}
span.EmailStyle17
        {mso-style-type:personal;
        font-family:"Arial","sans-serif";
        color:windowtext;}
span.EmailStyle18
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle19
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.Section1
        {page:Section1;}
-->
</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=Section1>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>I mean the draft.  I guess if the OFA members decide that
the IPoIB draft is useless and do something else for DHCP, that’s fine. 
The IPoIB draft can serve as a starting point, though.<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>The current code does have problems, and as far as I know it
only works if the DHCP server is serving addresses directly on the IB subnet,
and is running on Windows (that’s the only configuration I ever tested it
in).<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>I agree the goals should be proper interop with DHCP servers, no
matter what OS the DHCP server runs on or whether the DHCP requests are being
served across a IB to Eth router/gateway.<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p> </o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>-Fab<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
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"'> Tzachi Dar
[mailto:tzachid@mellanox.co.il] <br>
<b>Sent:</b> Monday, January 22, 2007 10:43 AM<br>
<b>To:</b> Fab Tillier; Anatoly Lisenko; Yossi Leybovich;
openib-windows@openib.org<br>
<b>Cc:</b> Tzahi Oved<br>
<b>Subject:</b> RE: [Openib-windows] ipoib dhcp patch<o:p></o:p></span></p>

</div>

</div>

<p class=MsoNormal><o:p> </o:p></p>

<div>

<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:blue'>Hi Fab,</span><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal> <o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:blue'>Can you point us to the ipoib dhcp spec? I thought there was only a
draft that no one was using.</span><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal> <o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:blue'>I guess that a full solution will also have to work with the Linux
implementation.</span><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal> <o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:blue'>In any case the current code changes has some problems: 1) It
changes the size of the packet but doesn't change the size in the ip header.
(this can be easily fixed) 2) it bases the request identifier on the
guid + qp_num. As we don't have a mechanism for keeping the same QP number one
might get a different ip after restarting the driver. This one is harder to
resolve.</span><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal> <o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:blue'>Thanks</span><o:p></o:p></p>

</div>

<div>

<p class=MsoNormal><span style='font-size:10.0pt;font-family:"Arial","sans-serif";
color:blue'>Tzachi</span><o:p></o:p></p>

</div>

<blockquote style='border:none;border-left:solid blue 1.5pt;padding:0in 0in 0in 4.0pt;
margin-left:3.75pt;margin-top:5.0pt;margin-right:0in;margin-bottom:5.0pt'>

<p class=MsoNormal><o:p> </o:p></p>

<div class=MsoNormal align=center style='text-align:center'>

<hr size=2 width="100%" align=center>

</div>

<p class=MsoNormal style='margin-bottom:12.0pt'><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"'> Fab Tillier
[mailto:ftillier@windows.microsoft.com] <br>
<b>Sent:</b> Monday, January 22, 2007 7:27 PM<br>
<b>To:</b> Anatoly Lisenko; Tzachi Dar; Yossi Leybovich;
openib-windows@openib.org<br>
<b>Cc:</b> Tzahi Oved<br>
<b>Subject:</b> RE: [Openib-windows] ipoib dhcp patch</span><o:p></o:p></p>

<p class=MsoNormal>Hi Anatoly,<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>When you have the DHCP server on the eth side, I assume it
is communicating with the IB hosts through your IB to Ethernet gateway. 
Your gateway should perform conversion of DHCP packets to/from the IPoIB DHCP
format, and can’t just forward the Ethernet DHCP packets unchanged. 
See the IPoIB spec for what things need to work on DHCP.<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>Also, instead of disabling DHCP support, how about fixing it
so that it send properly formed packets (as per IPoIB spec) and then convert
them to the OS so that the OS is happy with them.  You can use netmon on
the host to snoop the network traffic and look at the DHCP packet as it’s
given from the OS to the IPoIB driver and from the IPoIB driver to the OS.<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>Disabling the DHCP packet conversion makes the DHCP packets
on the wire not compliant to the IPoIB spec.<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>-Fab<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<div>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p class=MsoNormal><b>From:</b> openib-windows-bounces@openib.org
[mailto:openib-windows-bounces@openib.org] <b>On Behalf Of </b>Anatoly Lisenko<br>
<b>Sent:</b> Monday, January 22, 2007 3:53 AM<br>
<b>To:</b> Tzachi Dar; Yossi Leybovich; openib-windows@openib.org<br>
<b>Cc:</b> Tzahi Oved<br>
<b>Subject:</b> [Openib-windows] ipoib dhcp patch<o:p></o:p></p>

</div>

</div>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>Hi,<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>I saw that ipoib interface fail to get automatic ip address
when DHCP server run on eth side.<o:p></o:p></p>

<p class=MsoNormal>This caused by changing DHCP packet fields at
__send_mgr_filter_dhcp().<o:p></o:p></p>

<p class=MsoNormal>I run ethereal on eth side and it show that the DHCP packet
from ipoib arrive damaged.<o:p></o:p></p>

<p class=MsoNormal>I think this cause DHCP server to ignore this packet.<o:p></o:p></p>

<p class=MsoNormal>But if DHCP server run on IB side than ipoib then interface
success to get automatic ip.<o:p></o:p></p>

<p class=MsoNormal>This work because in __recv_dhcp() ipoib change all DHCP
packet fields like in the DHCP packet arrived from ETH side.<o:p></o:p></p>

<p class=MsoNormal>I attach patch that disable all changes to DHCP packets:<o:p></o:p></p>

<p class=MsoNormal>1. All changed related to DHCP placed into #ifdef
IPOIB_DHCP_HACK … #endif<o:p></o:p></p>

<p class=MsoNormal>2. IPOIB_DHCP_HACK isn’t defined.<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal>Index: ulp/ipoib/kernel/ipoib_port.c<o:p></o:p></p>

<p class=MsoNormal>===================================================================<o:p></o:p></p>

<p class=MsoNormal>--- ulp/ipoib/kernel/ipoib_port.c   (revision 570)<o:p></o:p></p>

<p class=MsoNormal>+++ ulp/ipoib/kernel/ipoib_port.c   (working copy)<o:p></o:p></p>

<p class=MsoNormal>@@ -2089,7 +2089,9 @@<o:p></o:p></p>

<p class=MsoNormal>     
dhcp_pkt_t             
*p_dhcp;<o:p></o:p></p>

<p class=MsoNormal>     
uint8_t                      
*p_option;<o:p></o:p></p>

<p class=MsoNormal>     
uint8_t                      
*p_cid = NULL;<o:p></o:p></p>

<p class=MsoNormal>+#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal>     
ib_gid_t               
gid;<o:p></o:p></p>

<p class=MsoNormal>+#endif<o:p></o:p></p>

<p class=MsoNormal>     
uint8_t                      
msg = 0;<o:p></o:p></p>

<p class=MsoNormal> <o:p></o:p></p>

<p class=MsoNormal>      IPOIB_ENTER( IPOIB_DBG_RECV
);<o:p></o:p></p>

<p class=MsoNormal>@@ -2168,12 +2170,15 @@<o:p></o:p></p>

<p class=MsoNormal>                       
("Failed to find required Client-identifier option.\n") );<o:p></o:p></p>

<p class=MsoNormal>                 
return IB_INVALID_SETTING;<o:p></o:p></p>

<p class=MsoNormal>           
}<o:p></o:p></p>

<p class=MsoNormal>+#ifdef IPOIB_DHCP_HACK       <o:p></o:p></p>

<p class=MsoNormal>           
if( p_dhcp->htype != DHCP_HW_TYPE_IB )<o:p></o:p></p>

<p class=MsoNormal>           
{<o:p></o:p></p>

<p class=MsoNormal>                 
IPOIB_PRINT_EXIT( TRACE_LEVEL_ERROR, IPOIB_DBG_ERROR,<o:p></o:p></p>

<p class=MsoNormal>                       
("Invalid hardware address type.\n") );<o:p></o:p></p>

<p class=MsoNormal>                 
return IB_INVALID_SETTING;<o:p></o:p></p>

<p class=MsoNormal>           
}<o:p></o:p></p>

<p class=MsoNormal>+#endif //#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal>+<o:p></o:p></p>

<p class=MsoNormal>           
break;<o:p></o:p></p>

<p class=MsoNormal>      /* message from DHCP server
*/<o:p></o:p></p>

<p class=MsoNormal>      case DHCPOFFER:<o:p></o:p></p>

<p class=MsoNormal>@@ -2186,6 +2191,8 @@<o:p></o:p></p>

<p class=MsoNormal>                 
("Invalide message type.\n") );<o:p></o:p></p>

<p class=MsoNormal>           
return IB_INVALID_PARAMETER;<o:p></o:p></p>

<p class=MsoNormal>      }<o:p></o:p></p>

<p class=MsoNormal>+<o:p></o:p></p>

<p class=MsoNormal>+#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal>     
p_eth->type.ip.prot.udp.hdr.chksum = 0;<o:p></o:p></p>

<p class=MsoNormal>      p_dhcp->htype =
DHCP_HW_TYPE_ETH;<o:p></o:p></p>

<p class=MsoNormal>      p_dhcp->hlen =
HW_ADDR_LEN;<o:p></o:p></p>

<p class=MsoNormal>@@ -2216,6 +2223,8 @@<o:p></o:p></p>

<p class=MsoNormal>           
status = ipoib_mac_from_guid( gid.unicast.interface_id,
(mac_addr_t*)&p_cid[3] );<o:p></o:p></p>

<p class=MsoNormal>           
p_cid[HW_ADDR_LEN + 3] = DHCP_OPT_END; //terminate tag<o:p></o:p></p>

<p class=MsoNormal>      }<o:p></o:p></p>

<p class=MsoNormal>+#endif //#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal>+<o:p></o:p></p>

<p class=MsoNormal>      <span lang=PT-BR>IPOIB_EXIT(
IPOIB_DBG_RECV );<o:p></o:p></span></p>

<p class=MsoNormal><span lang=PT-BR>      </span>return
status;<o:p></o:p></p>

<p class=MsoNormal> }<o:p></o:p></p>

<p class=MsoNormal>@@ -3160,8 +3169,10 @@<o:p></o:p></p>

<p class=MsoNormal>     
dhcp_pkt_t             
*p_ib_dhcp;<o:p></o:p></p>

<p class=MsoNormal>     
uint8_t                      
*p_option, *p_cid = NULL;<o:p></o:p></p>

<p class=MsoNormal>     
uint8_t                      
msg = 0;<o:p></o:p></p>

<p class=MsoNormal>+#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal>     
size_t                       
len;<o:p></o:p></p>

<p class=MsoNormal>     
ib_gid_t               
gid;<o:p></o:p></p>

<p class=MsoNormal>+#endif //#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal> <o:p></o:p></p>

<p class=MsoNormal>      IPOIB_ENTER( IPOIB_DBG_SEND
);<o:p></o:p></p>

<p class=MsoNormal> <o:p></o:p></p>

<p class=MsoNormal>@@ -3236,6 +3247,7 @@<o:p></o:p></p>

<p class=MsoNormal>      case DHCPRELEASE:<o:p></o:p></p>

<p class=MsoNormal>      case DHCPINFORM:<o:p></o:p></p>

<p class=MsoNormal>           
/* Fix up the client identifier option */<o:p></o:p></p>

<p class=MsoNormal>+#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal>           
if( p_cid )<o:p></o:p></p>

<p class=MsoNormal>           
{<o:p></o:p></p>

<p class=MsoNormal>                 
/* do we need to replace it ?  len eq ETH MAC sz 'and' MAC is mine */<o:p></o:p></p>

<p class=MsoNormal>@@ -3295,6 +3307,8 @@<o:p></o:p></p>

<p class=MsoNormal>           
p_ib_dhcp->htype = DHCP_HW_TYPE_IB;<o:p></o:p></p>

<p class=MsoNormal>           
p_ib_dhcp->hlen = 0;<o:p></o:p></p>

<p class=MsoNormal>           
cl_memclr( p_ib_dhcp->chaddr, sizeof(p_ib_dhcp->chaddr) );<o:p></o:p></p>

<p class=MsoNormal>+#endif //#ifdef IPOIB_DHCP_HACK<o:p></o:p></p>

<p class=MsoNormal>+<o:p></o:p></p>

<p class=MsoNormal>           
break;<o:p></o:p></p>

<p class=MsoNormal> <o:p></o:p></p>

<p class=MsoNormal>      /* Server messages. */<o:p></o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

<p class=MsoNormal><o:p> </o:p></p>

</blockquote>

</div>

</body>

</html>