<div dir="ltr"><div>Hi,</div><div><br></div><div>










<p style="margin:0in 0in 0in 0.375in;font-family:-apple-system-font;font-size:9pt">Scenario:</p>

<ol style="direction:ltr;unicode-bidi:embed;margin-top:0in;margin-bottom:0in;font-family:Calibri;font-size:9pt;font-weight:normal;font-style:normal" type="1"><li style="margin-top:0px;margin-bottom:0px;vertical-align:middle;color:black" value="1"><span style="font-weight:normal;font-style:normal;font-family:-apple-system-font;font-size:9pt">If our device configures netdev->mtu as 1500  and
     netdev->max_pkt_len is 9128(above 9k).</span></li><li style="margin-top:0px;margin-bottom:0px;vertical-align:middle;color:black"><span style="font-family:-apple-system-font;font-size:9pt">If the DHCP server
     sends MTU size as 9K.   </span></li></ol>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt" lang="en-US"> </p>

<p style="margin:0in 0in 0in 0.375in;font-size:9pt"><span style="font-family:-apple-system-font" lang="en-GB">As per the code walk-through,
I understand that this api "</span><span style="font-family:-apple-system-font" lang="en-US">static</span><span style="font-family:-webkit-standard" lang="en-GB"> </span><span style="font-family:-apple-system-font" lang="en-GB">int</span><span style="font-family:-webkit-standard" lang="en-GB"> </span><span style="font-family:-apple-system-font" lang="en-GB">apply_netdev_settings” get
invoke and call the below part of code to handle the above scenario: In this
case, as part of netdev_close , it gets called the intf_close and it didn’t
call the intf_init/open<span>  </span>as part of netdev_open
api.</span></p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt" lang="en-US"> </p>

<p style="margin:0in 0in 0in 0.375in"><span style="font-family:-apple-system-font;font-size:9pt;color:black" lang="en-GB"> </span><span style="font-family:Calibri;font-size:11pt" lang="en-US">/*</span><span style="font-family:Calibri;font-size:11pt" lang="en-GB"> Close and reopen network device if MTU has
increased </span><span style="font-family:Calibri;font-size:11pt" lang="en-US">*/</span></p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt"><span lang="en-GB">if ( </span><span lang="en-US">netdev_is_open</span><span lang="en-GB"> ( netdev ) && ( mtu > old_mtu ) ) {</span></p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt">netdev_close (
netdev );</p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt"><span lang="en-GB">if ( ( rc = </span><span lang="en-US">netdev_open</span><span lang="en-GB"> ( netdev ) ) != </span><span lang="en-US">0</span><span lang="en-GB"> ) {</span></p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt"><span lang="en-GB">DBGC ( netdev, </span><span lang="en-US">"NETDEV %s could
not reopen: "</span></p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt"><span lang="en-US">"</span><span lang="en-GB">%s\n", netdev-></span><span lang="en-US">name</span><span lang="en-GB">, </span><span lang="en-US">strerror</span><span lang="en-GB"> ( rc ) );</span></p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt">return rc;</p>

<p style="margin:0in 0in 0in 0.375in;font-family:Calibri;font-size:11pt">}</p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black">}</p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black"> </p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black">Intf_init api gets called from the below flow which
is invoked as part of device probe api.</p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black">alloc_etherdev()---> alloc_netdev()----->
intf_init gets called based on the number of entries in the configuration.</p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black"> </p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black">Could you please let me know if the intf_close
gets called as part of netdev_close api , what is the flow to create the intf/
re-init the intf<span>  </span>again for the above
scenario. <br><br></p><p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black">Regards</p><p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black">Mohamed Shah R<br></p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black"> </p>

<p style="margin:0in 0in 0in 0.375in;font-family:-webkit-standard;font-size:9pt;color:black"> </p>





</div></div>