Jump to content

IntelE1000e kext (82566MM, 82577LM, etc)


  • Please log in to reply
50 replies to this topic

#1
ktbos

ktbos

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts
Attached is a new kext I created for the latest round of Intel E1000e wired network cards. This is primarily based on dingguijin's Intel82566MM kext. I got the latest Intel Linux driver code and put that into dingguijin's framework. This kext works well for me on my Dell Latitude E6410 which has a 82577LM card but should work with other new Intel network cards. Note that Intel branched the code a while back after the Intel82566MM which means that my new kext may not cover all the cards that the Intel82566MM kext does so this is not a supercede although it will overlap with some cards. See below for the list of cards that it should work with.

Now the caveats: I've compiled the kext to work with Leopard and Snow Leopard and for 32-bit Intel, 64-bit Intel, and for PPC. And I'm pleased to say that it was able to get a Gigabit connection. However, with only the one test computer, I've only been able to test it on 32-bit Intel and on Snow Leopard so let me know if there are problems with other versions or platforms. Also note, in particlar, that some of the theoretically supported cards are "special case" cards as defined by Intel (82571, 82572, 82573, 82574, 82583, and 80003ES2LAN) that use alternate driver logic that I was not able to test. And then there's the big caveat that this is my first kext so in addition to the usual disclaimers about not blaming me for anything going wrong, add in a novice rider!

Here's the kext for 32-bit 10.5 or 10.6: Attached File  IntelE1000e.kext.zip   119.14KB   2372 downloads
And here's the kext for 32- or 64-bit 10.6: Attached File  IntelE1000e.kext.zip   165.85KB   5763 downloads

And here's the list of cards this driver is intended to work with:
Intel Internal name                   DevID     Intel Product name------------------------------------  --------  -------------------------------------------------E1000_DEV_ID_82571EB_COPPER           0x105E	82571EB Gigabit Ethernet ControllerE1000_DEV_ID_82571EB_FIBER            0x105F	82571EB Gigabit Ethernet ControllerE1000_DEV_ID_82571EB_SERDES           0x1060	82571EB Gigabit Ethernet ControllerE1000_DEV_ID_82571EB_SERDES_DUAL      0x10D9	82571EB Dual Port Gigabit Mezzanine AdapterE1000_DEV_ID_82571EB_SERDES_QUAD      0x10DA	82571EB Quad Port Gigabit Mezzanine AdapterE1000_DEV_ID_82571EB_QUAD_COPPER      0x10A4	82571EB Gigabit Ethernet ControllerE1000_DEV_ID_82571PT_QUAD_COPPER      0x10D5	82571PT Gigabit PT Quad Port Server ExpressModuleE1000_DEV_ID_82571EB_QUAD_FIBER       0x10A5	82571EB Gigabit Ethernet Controller (Fiber)E1000_DEV_ID_82571EB_QUAD_COPPER_LP   0x10BC	82571EB Gigabit Ethernet Controller (Copper)E1000_DEV_ID_82572EI_COPPER           0x107D	82572EI Gigabit Ethernet Controller (Copper)E1000_DEV_ID_82572EI_FIBER            0x107E	82572EI Gigabit Ethernet Controller (Fiber)E1000_DEV_ID_82572EI_SERDES           0x107F	82572EI Gigabit Ethernet ControllerE1000_DEV_ID_82572EI                  0x10B9	82572EI Gigabit Ethernet Controller (Copper)E1000_DEV_ID_82573E                   0x108B	82573V Gigabit Ethernet Controller (Copper)E1000_DEV_ID_82573E_IAMT              0x108C	82573E Gigabit Ethernet Controller (Copper)E1000_DEV_ID_82573L                   0x109A	82573L Gigabit Ethernet ControllerE1000_DEV_ID_82574L                   0x10D3	82574L Gigabit Network ConnectionE1000_DEV_ID_82574LA                  0x10F6	82574L Gigabit Network ConnectionE1000_DEV_ID_82583V                   0x150C	82583V Gigabit Network ConnectionE1000_DEV_ID_80003ES2LAN_COPPER_DPT   0x1096	80003ES2LAN Gigabit Ethernet Controller (Copper)E1000_DEV_ID_80003ES2LAN_SERDES_DPT   0x1098	80003ES2LAN Gigabit Ethernet Controller (Serdes)E1000_DEV_ID_80003ES2LAN_COPPER_SPT   0x10BA	80003ES2LAN Gigabit Ethernet Controller (Copper)E1000_DEV_ID_80003ES2LAN_SERDES_SPT   0x10BB	80003ES2LAN Gigabit Ethernet Controller (Serdes)E1000_DEV_ID_ICH8_82567V_3            0x1501	82567V-3 Gigabit Network ConnectionE1000_DEV_ID_ICH8_IGP_M_AMT           0x1049	82566MM Gigabit Network ConnectionE1000_DEV_ID_ICH8_IGP_AMT             0x104A	82566DM Gigabit Network ConnectionE1000_DEV_ID_ICH8_IGP_C               0x104B	82566DC Gigabit Network ConnectionE1000_DEV_ID_ICH8_IFE                 0x104C	82562V 10/100 Network ConnectionE1000_DEV_ID_ICH8_IFE_GT              0x10C4	82562GT 10/100 Network ConnectionE1000_DEV_ID_ICH8_IFE_G               0x10C5	82562G 10/100 Network ConnectionE1000_DEV_ID_ICH8_IGP_M               0x104D	82566MC Gigabit Network ConnectionE1000_DEV_ID_ICH9_IGP_M               0x10BF	82567LF Gigabit Network ConnectionE1000_DEV_ID_ICH9_IGP_M_AMT           0x10F5	82567LM Gigabit Network ConnectionE1000_DEV_ID_ICH9_IGP_M_V             0x10CB	82567V Gigabit Network ConnectionE1000_DEV_ID_ICH9_IGP_AMT             0x10BD	82566DM-2 Gigabit Network ConnectionE1000_DEV_ID_ICH9_BM                  0x10E5	82567LM-4 Gigabit Network ConnectionE1000_DEV_ID_ICH9_IGP_C               0x294C	82566DC-2 Gigabit Network ConnectionE1000_DEV_ID_ICH9_IFE                 0x10C0	82562V-2 10/100 Network ConnectionE1000_DEV_ID_ICH9_IFE_GT              0x10C3	82562GT-2 10/100 Network ConnectionE1000_DEV_ID_ICH9_IFE_G               0x10C2	82562G-2 10/100 Network ConnectionE1000_DEV_ID_ICH10_R_BM_LM            0x10CC	82567LM-2 Gigabit Network ConnectionE1000_DEV_ID_ICH10_R_BM_LF            0x10CD	82567LF-2 Gigabit Network ConnectionE1000_DEV_ID_ICH10_R_BM_V             0x10CE	82567V-2 Gigabit Network ConnectionE1000_DEV_ID_ICH10_D_BM_LM            0x10DE	82567LM-3 Gigabit Network ConnectionE1000_DEV_ID_ICH10_D_BM_LF            0x10DF	82567LF-3 Gigabit Network ConnectionE1000_DEV_ID_PCH_M_HV_LM              0x10EA	82577LM Gigabit Network ConnectionE1000_DEV_ID_PCH_M_HV_LC              0x10EB	82577LC Gigabit Network ConnectionE1000_DEV_ID_PCH_D_HV_DM              0x10EF	82578DM Gigabit Network ConnectionE1000_DEV_ID_PCH_D_HV_DC              0x10F0	82578DC Gigabit Network Connection


#2
Tristan.

Tristan.

    InsanelyMac Protégé

  • Members
  • Pip
  • 22 posts
Hi, I'm having problems getting my pc to load these drivers.
I have an 82578DM (0x10ef8086)
I'm currently using dingguijin's 1.0.3 drivers, which load fine. I'm hoping to get yours going as I have an issue with dingguijin's where when put under stress (e.g. multiple scp file transfers at the same time) either the card will simply stop responding (it stays green in the network settings but no network traffic works) or it grinds all the apps doing network stuff and in turn my system to a halt.

I've tried putting the drivers in S/L/E and in E/E with the IONetworkingFamily kext and neither way works. checking the /var/log/system.log i found this:
com.apple.kextd[12]: Can't load /System/Library/Extensions/IntelE1000e.kext - no code for running kernel's architecture.

perhaps it hasn't compiled for everything as you thought? Is there any chance you can provide the source code, and maybe I can try compile it myself? This would also be handy as I've been adding debug statements to the code provided by dingguijin's to try figure out where the code freezes/crashes/whatever-it-does, and it would be awesome to have the most recent version of the E1000 code to do this with.

I'm also interested in the process you went through to get the E1000 linux code into this, I should probably do some research on it myself, but if you have any pointers on where to start, etc this would be much appreciated :)

cheers
.tristan

#3
ktbos

ktbos

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts
I had the best luck putting it in S/L/E - don't know why that was better than E/E but it worked out better for me. Of course, you'll also need to make sure that the Intel82566MM kext isn't loading too - I would say the behavior for having them both loaded would be unpredictable.

As far as the arch, I just checked build settings and it does say it is compiled for 64-bit and 32-bit and PPC. Can you do me a favor and fire this command in Terminal and tell me what happens?
sudo kextutil -n -t /path/to/IntelE1000e.kext

And let me know your OS version (10.6.3?) and which arch you are running.

Oh, and if you really want to know all the detail for how I got the kext updated, here's my blog post describing the process: Deep Task Queueing for Hac Laptop Networking

#4
iPoco

iPoco

    InsanelyMac Plumber

  • Supervisors
  • 1,470 posts
  • Gender:Male
  • Location:Canada
In support of the GPL (http://creativecommo...censes/GPL/2.0/) can you please release the source code by attaching it here, or providing a way to get to it.
Thanks :angry2:,

iPoco

#5
Tristan.

Tristan.

    InsanelyMac Protégé

  • Members
  • Pip
  • 22 posts
tristan$ sudo kextutil -n -t  /Extra/Extensions/IntelE1000e.kext
Password:
No kernel file specified; using running kernel for linking.
Warnings: 
	Executable does not contain code for architecture: 
		x86_64

/Extra/Extensions/IntelE1000e.kext does not contain code for architecture x86_64.

i am running 10.6.3, and I have removed all other sources for ethernet drivers, the system don't have any ethernet controllers when i boot. (I use ##### to rebuild caches and repair permissions)

again, if you provide the source code I can try to compile it myself :angry2:

#6
ktbos

ktbos

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts
Tristan, thanks for the debugging help. I guess I hadn't figured out how to compile for 10.5 and for 10.6 64-bit at the same time. So I'm stuck with the two different versions. I've updated the original post to include a second compiled kext. Let me know if this works for you.

#7
ktbos

ktbos

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts

In support of the GPL (http://creativecommo...censes/GPL/2.0/) can you please release the source code by attaching it here, or providing a way to get to it.
Thanks :thumbsup_anim:,

iPoco


I'd been hoping to hear back from dingguijin so I could just add my code to his project but I haven't heard back from him. And with 2 requests for source already, apparently I shouldn't wait any longer. So instead, I've just created a new GoogleCode project: Google Code for IntelE1000e.kext

#8
iPoco

iPoco

    InsanelyMac Plumber

  • Supervisors
  • 1,470 posts
  • Gender:Male
  • Location:Canada
Perfect!

#9
Tristan.

Tristan.

    InsanelyMac Protégé

  • Members
  • Pip
  • 22 posts
OK, that one works. Thanks

Unfortunately it does not fix my problem. If i start 2 scp's from the computer, after a while the transfers stall and the network on the mac becomes non responsive until I unplug the cable and plug it back it (which, assuming the system hasn't locked up due to the network stall returns things to normal).

I guess it's back to adding debug statements to the code for me!

#10
hnak

hnak

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 294 posts
  • Gender:Male
Hi, I took a look at the source code.

I basically did the same thing when I wrote AppleIntelE1000e.kext based on e1000e linux driver.

I guess that VMWare bridge mode doesn't work with this driver, as setPromiscuousMode() is not implemented correctly.
Furthermore, IOMallocContiguous() is deprecated and IOBufferMemoryDescriptor() should be used instead.
You can freely use my code.

#11
User_01

User_01

    InsanelyMac Sage

  • Members
  • PipPipPipPipPip
  • 264 posts
Works here. Thanks. Loaded from - correct - S/L/E (not E/E (Extra/Extensions)). 64-bit mode

0x10CC 82567LM-2 Gigabit Network Connection

Previous kext used - Intel82566MM.kext.

#12
wayover

wayover

    InsanelyMac Protégé

  • Members
  • Pip
  • 49 posts
I use 1.0.3 version from hnak with 82566DM controllers, works fine (PromiscuousMode with bridge adapter settings and sleep) with Snow 64bit and leopard 10.5. What distinguishes the version submitted? 82575EB is not supported?

#13
stevenvmc

stevenvmc

    InsanelyMac Protégé

  • Just Joined
  • Pip
  • 1 posts
It works!!! Thanks a lot.

My system: 10.6.2. Acer Veriton Q45 chipset. I just copied it to Extensions and boot with -v -f option. Then go to Network preferences, renew DHCP.

#14
TennisGeek

TennisGeek

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 127 posts
  • Gender:Male
  • Location:Boston 'burb, born in Japan
  • Interests:Tennis, Computer, Mac
It works on my 64bit 10.6.3. Thanks!

One problem is that, I cannot pick the jumbo frame in the control panel.

Even if I choose "Manual" MTU, it's capped at 1500. I believe the card does the jumbo frame.
My card is [8083:1083], Intel Pro/1000 PT Desktop Adapter.
The chipset is 82572, and the source code suggests it does jumbo frame.

10b9  82572EI Gigabit Ethernet Controller (Copper)
		8086 1083  PRO/1000 PT Desktop Adapter
		8086 1093  PRO/1000 PT Desktop Adapter

-- TG

#15
TennisGeek

TennisGeek

    InsanelyMac Geek

  • Members
  • PipPipPip
  • 127 posts
  • Gender:Male
  • Location:Boston 'burb, born in Japan
  • Interests:Tennis, Computer, Mac

I'd been hoping to hear back from dingguijin so I could just add my code to his project but I haven't heard back from him. And with 2 requests for source already, apparently I shouldn't wait any longer. So instead, I've just created a new GoogleCode project: Google Code for IntelE1000e.kext


I figured out the jumbo frame enabled in the control panel.
The real question is whether or not the driver actually does anything good or bad when I use the jumbo frame.
Do you have any idea?

-- TG

bash-3.2$ svn diff IntelE1000e.xcodeproj/project.pbxproj IntelE1000e.cpp IntelE1000e.h
Index: IntelE1000e.xcodeproj/project.pbxproj
===================================================================
--- IntelE1000e.xcodeproj/project.pbxproj	(revision 2)
+++ IntelE1000e.xcodeproj/project.pbxproj	(working copy)
@@ -290,7 +290,7 @@
 			buildSettings = {
 				ALWAYS_SEARCH_USER_PATHS = NO;
 				ARCHS = "$(ARCHS_STANDARD_32_64_BIT)";
-				CURRENT_PROJECT_VERSION = 1.1.2;
+				CURRENT_PROJECT_VERSION = 1.1.3;
 				DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
 				GCC_CW_ASM_SYNTAX = YES;
 				GCC_C_LANGUAGE_STANDARD = c99;
Index: IntelE1000e.cpp
===================================================================
--- IntelE1000e.cpp	(revision 2)
+++ IntelE1000e.cpp	(working copy)
@@ -1087,6 +1087,18 @@
 	}
 }
 
+IOReturn IntelE1000e::getMaxPacketSize(UInt32 * maxSize) const
+{
+  if (adapter.ei) {
+	if ((adapter.ei->flags & FLAG_HAS_JUMBO_FRAMES) != 0) {
+	  *maxSize = adapter.ei->max_hw_frame_size;
+	  return kIOReturnSuccess;
+	}
+  }
+  return super::getMaxPacketSize(maxSize);
+}
+
+
 //-----------------------------------------------------------------------
 // e1000e private functions
 //-----------------------------------------------------------------------
Index: IntelE1000e.h
===================================================================
--- IntelE1000e.h	(revision 2)
+++ IntelE1000e.h	(working copy)
@@ -93,6 +93,7 @@
 	virtual IOReturn setMulticastMode(bool active);
 	virtual IOReturn setMulticastList(IOEthernetAddress * addrs, UInt32 count);
 	virtual IOReturn getChecksumSupport(UInt32 *checksumMask, UInt32 checksumFamily, bool isOutput);
+	virtual IOReturn getMaxPacketSize(UInt32 * maxSize) const;
 	
 private:
 	IOWorkLoop * workLoop;


#16
iTAG

iTAG

    InsanelyMac Protégé

  • Members
  • Pip
  • 10 posts
think u can thworw one for intel pro ve

#17
ktbos

ktbos

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts

think u can thworw one for intel pro ve


Nope, totally different card would require totally different driver. Check around, though, because it's pretty likely that you'll find a ProVE kext somewhere. Just not here.

#18
kizwan

kizwan

    InsanelyMac Legend

  • Members
  • PipPipPipPipPipPipPipPipPip
  • 1,422 posts
Hi ktbos,

I really enjoy reading your blogs. I'm very interested learning on this subject, particularly porting linux driver to OS X. It is not easy to learn about OS X driver development but your blog may help me to understand it better. :superman: Thank you for sharing the source code.

#19
ktbos

ktbos

    InsanelyMac Protégé

  • Members
  • PipPip
  • 54 posts
Great, glad I could be of help. It'd be interesting to hear how dingguijin first started his Intel82566MM work and that might help people like you and me learn where to start on some other driver.

#20
scalar

scalar

    InsanelyMac Protégé

  • Members
  • PipPip
  • 92 posts
I thought this supported my 82575's as well (had fiddled a while ago with integrating some of this code but am not fluent on OSX/Xcode) but it only set something improperly in my network cards requiring a 30 second time off cold boot for any other OS to be able to see them again.





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users

© 2014 InsanelyMac  |   News  |   Forum  |   Downloads  |   OSx86 Wiki  |   Mac Netbook  |   PHP hosting by CatN  |   Designed by Ed Gain  |   Logo by irfan  |   Privacy Policy