Hi again everybody. After tinkering with updating the AtherosL1cEthernet drivers (http://www.insanelym...ver-for-107108/) I decided to try porting from scratch the newer ALX driver from here:
Much of what I said in the AtherosL1cEthernet thread also goes for this driver, so please browse over it quickly if you get a chance.
While the latest news update on the ALX page suggested they were stripping out support for the earlier drivers, the code for these seems to be still intact in the latest patches so it seemed worth trying to port, especially with many newer motherboard revisions apparently containing the AR8161 chip and causing people much frustration. Once again I've only been able to test this code on my AR8151. There are a lot of rough edges, but "release early, release often" as they say. There are essentially two low-level sections of code, one for the AR81(31/32/51/52) and another for the newer ones. I can't really vouch for the stability of the newer chipset code. Most of the low-level stuff is mostly portable and unmodified from the Linux code though.
Wake on LAN/demand works for me so far, but I haven't yet enabled TSO,
Use your favourite method of adding kexts to /System/Library/Extensions. Personally I prefer doing it manually from the terminal.
For testing or reporting bugs, please use the kext in the "Debug" subdirectory. This will output much more info to /var/log/system.log.
Remove any old version:
sudo rm -rf /System/Library/Extensions/ALXEthernet.kext
(Don't forget to also remove any potentially conflicting kexts from the Extensions directory, e.g. AtherosL1cEthernet.kext!)
Copy the new version from wherever you extracted it, such as Downloads:
sudo cp -r /Users/yourusername/Downloads/ALXEthernet/ALXEthernet.kext /System/Library/Extensions/
Update the kernel cache:
sudo touch /System/Library/Extensions
Then wait a couple of minutes or so before rebooting. This should trigger kextd to rebuild the cache.
(Alternatively you could completely remove the old cache first:
sudo rm -rf /System/Library/Caches/com.apple.kext.caches/*
But this is best ran from single user mode (-s) where kextd isn't active and watching for changes in the background.)
If you find your system becomes unbootable due to panics, the easiest way to fix this is to temporarily disable the ethernet card in the BIOS/UEFI, boot into Mac OS X and then perform the the first and last installation steps above.
Alternative (test) install:
To avoid breaking your system if the module is installed but panics every time, you can just test by installing to the temporary directory:
sudo cp -r /Users/yourusername/Downloads/ALXEthernet/ALXEthernet.ext /tmp/
Then load the module for testing:
sudo kextload /tmp/ALXEthernet.kext
The contents of /tmp will be automatically wiped upon reboot so you'll have to repeat these two steps each time.
1.0.2 - Bug fixes that should help clean up memory allocation problems at boot time (with a little luck). VLAN is now possible for anyone that needs it, but I've only tested it minimally.
1.0.1 - Bug fixes and refinements. Manually setting the link speed should work properly now and might be an option if autonegotiation is causing issues. The link watchdog timer should generally be working better now. Changed some Linux code that was automatically enabling MSI-X interrupts on newer chips. I have no idea if these are supported properly on Mac OS X, but to be safe I'd rather keep everything on plain old MSI for now.
1.0.0 - The initial release. Don't be fooled, it's likely very unstable!
The zip files are (hopefully) attached to this post. They contain the kext module and the GPL sourcecode. The kext in the "Debug" folder is mostly the same as the regular kext, but prints much more information to the system logs.
20121117 ALXEthernet-1.0.2.zip 319.41KB 4277 downloads
MD5 (ALXEthernet-1.0.2.zip) = dbdc587f2b4905515571a7ce2bd55c8f
20121106 ALXEthernet-1.0.1.zip 315.85KB 600 downloads
MD5 (ALXEthernet-1.0.1.zip) = ed621f34f91e60b5422734401b6bdb6e
20121103 ALXEthernet-1.0.0.zip 315.37KB 405 downloads
MD5 (ALXEthernet-1.0.0.zip) = 78c0d329237e1ac726bd737493b45724
Like I said in the other thread: I'm just throwing this driver/code out there and seeing what happens. I can't provide serious help or even guarantee a reply if things don't work for anyone. Enjoy and please tell me what card type you have for any feedback if possible!
While kernel panics should hopefully not happen if everything is installed correctly, if anybody gets a regular panic and feels up to it then it would be incredibly useful for me if you were to enable verbose mode at boot with the -v flag and snap me a (readable) photograph of the panic screen along with which Mac OS X version they're using (e.g. 10.8.2) along with the driver version used (e.g. 1.0.1). I can then hopefully trace exactly where in the code things are going wrong. Usually these things are from buffer allocations gone horribly wrong.