Porting pch_pcieqos to 3.2 for Intel EG20T with no MAC

From: Darren Hart
Date: Tue Jan 10 2012 - 20:58:53 EST


This is a multi-part message in MIME format.I find myself with a development board with no MAC address for the pch_gbe in
the Platform Controller Hub EG20T. I've dusted off an old patch and am trying
to get it working so it can be included upstream.

I found the phub_util_mac utility on sourceforge which appears to require the
following patch:

http://git.yoctoproject.org/cgit/cgit.cgi/meta-extras/plain/recipes-kernel/linux/linux-netbook-2.6.33.2/linux-2.6.34-pch-pcieqos.patch

I've made the obvious changes to the driver to use unlocked_ioctl as ioctl has
been removed upstream. With this driver built and installed, the
topcliff_mac_util command reports no errors and reads the MAC address as:

00:00:00:00:00:00

Trying to set it reports no errors either, and the instrumentation suggests it
is at least trying to write the correct data. Reading back still results in all
zeros.

During boot, the pch_gbe driver reports:
[ 2.211233] pch_gbe 0000:02:00.1: enabling device (0000 -> 0003)
[ 2.217271] pch_gbe 0000:02:00.1: PCI INT A -> GSI 16 (level, low) -> IRQ 16
[ 2.224349] pch_gbe 0000:02:00.1: setting latency timer to 64
[ 2.233388] pch_gbe 0000:02:00.1: Invalid MAC Address
[ 2.238821] pch_gbe 0000:02:00.1: PCI INT A disabled
[ 2.243809] pch_gbe: probe of 0000:02:00.1 failed with error -5

The patch itself follows, I have attached a rather lengthy log which includes a
read/write/read cycle demonstrating the write not taking effect.

Can you shed some light on why this might be the case?

Thanks,

Darren Hart