
9512 doc: http://www.smsc.com/Downloads/SMSC/Down ... s/9512.pdf
GPIO 0 to 2 are used for LEDs:
GPIO0 is FDX, pin 20
GPIO1 is LNK, pin 21
GPIO2 is SPD, pin 22
GPIO3 pin 35
GPIO4 pin 36
GPIO5 pin 37
GPIO6 pin 42
GPIO7 pin 43
It's obvious to me that GPIO3-5 are unrouted on the rPi board; i am not 100% sure about 6-7
I had a glance at the driver source code,
/usr/src/linux/drivers/net/usb/smsc95xx.h
/usr/src/linux/drivers/net/usb/smsc95xx.c
and it does not seem complicated to me.
But I am not a kernel hacker, and going any further is not possible to me (really manipulating the pins from soft-land).
I am not asking for mapping the IOs in /sys; this sounds complicated to me. But, at least a short C code to put pins up and down. This should be easy and portable, because all rPi users will have a SMSC9512 mapped at the same addresse. It should allow for an easily portable code.
My problem, about not being a kernel hacker, is that the memory range of the chip may be protected, and writable only by kernel-land code. Making the use of root-land code impossible.
Ideally, I would like to have a root-land binary. Because it would be usable by 100% community, without having to recompile the kernel.
If some-one could work on this, it would adorable.
If some hacker can work on the code, I would be happy to solder a few LEDs on my board.
Althought, GPIO0-2 may be re-mapable; it would nice to also gain those three pins, but this would require, for sure, to recompile the kernel, and modify the driver to stop using the 3 LEDs. Probably the most easy part for the dev; but would require every one to rebuild the kernel; I dislike this approach.
I don't feel in mood for kernel hacking myself. But I hope some one lese will be kind to have a look at it.
Thanks.