This can be done without kernel modifications. See:
Raspberry Pi • View topic - Controlling LAN LEDs individually
As compiling on LE is tricky, here is a build I did on raspbian that works fine on LE.Codewget -O llctl "https://drive.google.com/uc?id=0B-6zmEDJwxZEbmJkU3g2MlhMQWs&export=download" chmod +x llctl
You can now turn off LEDS with
and turn them on with
This is no longer working on the Raspberry Pi 3 Model B+
Controlling LAN LEDs individually - Page 2 - Raspberry Pi Forums