<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -138,15 +138,21 @@ void com_triton_forcedeth::setBufSize() {
 	UInt32 mtu;
 	
 	mtu = interface-&gt;getMaxTransferUnit();
+	IOLog(&quot;forcedeth: setBufSize/Apple wants %d bytes\n&quot;, mtu);
 	
 	if(mtu &gt; NV_PKTLIMIT_2) {
 		mtu = NV_PKTLIMIT_2;
 	}
 	
-	if( mtu &lt;= kIOEthernetMaxPacketSize )
+	IOLog(&quot;forcedeth: setBufSize/We can give them %d bytes\n&quot;, mtu);
+	
+	if( mtu &lt;= kIOEthernetMaxPacketSize  &amp;&amp; kIOEthernetMaxPacketSize &lt;= NV_PKTLIMIT_2 ) {
 		rxBufSz = kIOEthernetMaxPacketSize + NV_RX_HEADERS;
-	else
+		IOLog(&quot;forcedeth: setBufSize/Setting with regards to kIOEthernetMaxPacketSize(%d) -- %d bytes\n&quot;, kIOEthernetMaxPacketSize, rxBufSz);
+	} else {
 		rxBufSz = mtu + NV_RX_HEADERS;
+		IOLog(&quot;forcedeth: setBufSize/Setting with regards to mtu(%d) -- %d bytes\n&quot;, mtu, rxBufSz);
+	}
 }
 
 bool com_triton_forcedeth::updateLinkSpeed() {</diff>
      <filename>forcedeth-helper.cpp</filename>
    </modified>
    <modified>
      <diff>@@ -531,9 +531,16 @@ IOReturn com_triton_forcedeth::enable(IOService *provider)
 	bool ret;
 	UInt32 i;
 	
+	nicTx = 0;
+	curRx = 0;
+	linkspeed = 0;
+		
+	setBufSize();
+	
 	IOLog(&quot;forcedeth: Enabling... &quot;);
 	
-	do {	
+	do {
+			
 		// 1) erase previous misconfiguration
 		// 4.1-1: stop adapter: ignored, 4.3 seems to be overkill
 		promiscuousMode = false;
@@ -549,11 +556,7 @@ IOReturn com_triton_forcedeth::enable(IOService *provider)
 		IOLog(&quot;1&quot;);
 
 		// 2) initialize descriptor rings
-		nicTx = 0;
-		curRx = 0;
-		linkspeed = 0;
 		
-		setBufSize();
 		if( !initRing() )
 			break;
 </diff>
      <filename>forcedeth.cpp</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>b12944008b0e69f76e19d8a1f8e3a57bdd610a93</id>
    </parent>
  </parents>
  <author>
    <name>planetbeing</name>
    <email>planetbeing@gmail.com</email>
  </author>
  <url>http://github.com/planetbeing/forcedeth-osx/commit/8480b5687069b596a6667732315c0fda201d24fa</url>
  <id>8480b5687069b596a6667732315c0fda201d24fa</id>
  <committed-date>2008-04-25T12:46:28-07:00</committed-date>
  <authored-date>2008-04-25T12:46:28-07:00</authored-date>
  <message>Added buffer size diagnostic messages</message>
  <tree>3d83c4b856a41b9959fe434017bbfd66058c7c96</tree>
  <committer>
    <name>planetbeing</name>
    <email>planetbeing@gmail.com</email>
  </committer>
</commit>
