diff --git a/IntelMausiEthernet.xcodeproj/project.xcworkspace/xcuserdata/dany.xcuserdatad/UserInterfaceState.xcuserstate b/IntelMausiEthernet.xcodeproj/project.xcworkspace/xcuserdata/dany.xcuserdatad/UserInterfaceState.xcuserstate index 71c0bad..620fd26 100644 Binary files a/IntelMausiEthernet.xcodeproj/project.xcworkspace/xcuserdata/dany.xcuserdatad/UserInterfaceState.xcuserstate and b/IntelMausiEthernet.xcodeproj/project.xcworkspace/xcuserdata/dany.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/IntelMausiEthernet/IntelMausiEthernet.cpp b/IntelMausiEthernet/IntelMausiEthernet.cpp index e268cd6..07d949f 100755 --- a/IntelMausiEthernet/IntelMausiEthernet.cpp +++ b/IntelMausiEthernet/IntelMausiEthernet.cpp @@ -22,6 +22,14 @@ #include #include "IntelMausiEthernet.h" + +//#define ETHERMTU 1500 +#define ETHERHDRSIZE 14 +#define ETHERCRC 4 +#define KDP_MAXPACKET (ETHERHDRSIZE + ETHERMTU + ETHERCRC) + + + #pragma mark --- function prototypes --- static inline void prepareTSO4(mbuf_t m, UInt32 *mssHeaderSize, UInt32 *payloadSize); @@ -602,7 +610,7 @@ void IntelMausi::receivePacket(void * pkt, UInt32 * pktSizeOUt, UInt32 timeout) //interface->enqueueInputPacket(rxPacketHead, pollQueue); - if( rxPacketSize < 1454) + if( rxPacketSize <= KDP_MAXPACKET) { isReceived = true; * pktSizeOUt =rxPacketSize; @@ -674,7 +682,7 @@ void IntelMausi::sendPacket(void * pkt, UInt32 pktSize) struct e1000_data_desc *desc; struct e1000_context_desc *contDesc; mbuf_t m; - IOReturn result = kIOReturnNoResources; + // IOReturn result = kIOReturnNoResources; UInt32 numDescs; UInt32 cmd; UInt32 opts; @@ -701,7 +709,7 @@ void IntelMausi::sendPacket(void * pkt, UInt32 pktSize) } - if(pktSize > 1454) + if(pktSize > KDP_MAXPACKET) { DebugLog("Ethernet [IntelMausi]:sendPacket pktSize is too big.\n"); goto done; diff --git a/build/Products/.DS_Store b/build/Products/.DS_Store index bcda7df..4df8f5e 100644 Binary files a/build/Products/.DS_Store and b/build/Products/.DS_Store differ diff --git a/build/Products/Debug/IntelMausiEthernet.kext/Contents/MacOS/IntelMausiEthernet b/build/Products/Debug/IntelMausiEthernet.kext/Contents/MacOS/IntelMausiEthernet index e3abc83..1dbc04c 100755 Binary files a/build/Products/Debug/IntelMausiEthernet.kext/Contents/MacOS/IntelMausiEthernet and b/build/Products/Debug/IntelMausiEthernet.kext/Contents/MacOS/IntelMausiEthernet differ diff --git a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.dia b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.dia index 42d44ef..a1db667 100644 Binary files a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.dia and b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.dia differ diff --git a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.o b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.o index 4be72e6..304336e 100644 Binary files a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.o and b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/Objects-normal/x86_64/IntelMausiEthernet.o differ diff --git a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph index 1da6f89..b341e07 100644 Binary files a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph and b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph differ diff --git a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph~ b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph~ index f2618ef..ec72ee6 100644 Binary files a/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph~ and b/build/Products/IntelMausiEthernet.build/Debug/IntelMausiEthernet.build/dgph~ differ