# Downport E1000E Kernel Module for Xen-Kernel

## sandro123

Hi

I got a rather new Dell Computer in my office.

Problem here is that the Onboard Ethernet Controller (E1000E ) is not supportet by Xen-kernel and older Gentoo-kernel <linux-2.6.23-gentoo-r3.

Even the latest 2007.0 Livecd does not support the Networkcard, which is really a shame !!!

But i got it working with the latest gentoo-sources  "linux-2.6.23-gentoo-r3" there it is included.

I tried to copy the E1000E directory in the sources from linux-2.6.23-gentoo-r3 and modified the Makefiles in the upper directory to include them. 

```

cp /usr/src/linux-2.6.23-gentoo-r3/drivers/net/e1000e /usr/src/linux-2.6.20-xen-r6/drivers/net/e1000e

```

Then i did search the tree where i have to add lines so that it get compiled

```
aoe@vie-aoe2 /usr/src/linux-2.6.23-gentoo-r3 $ fgrep -R E1000E *

drivers/net/Makefile:obj-$(CONFIG_E1000E) += e1000e/

drivers/net/Kconfig:config E1000E

drivers/net/e1000e/Makefile:obj-$(CONFIG_E1000E) += e1000e.o

```

and added this lines to the Files in /usr/src/linux-2.6.20-xen-r6

but when i them compile i get this errors:

  LD      drivers/net/e1000/built-in.o

  CC [M]  drivers/net/e1000/e1000_main.o

  CC [M]  drivers/net/e1000/e1000_hw.o

  CC [M]  drivers/net/e1000/e1000_ethtool.o

  CC [M]  drivers/net/e1000/e1000_param.o

  LD [M]  drivers/net/e1000/e1000.o

  LD      drivers/net/e1000e/built-in.o

  CC [M]  drivers/net/e1000e/82571.o

  CC [M]  drivers/net/e1000e/ich8lan.o

  CC [M]  drivers/net/e1000e/es2lan.o

  CC [M]  drivers/net/e1000e/lib.o

  CC [M]  drivers/net/e1000e/phy.o

  CC [M]  drivers/net/e1000e/param.o

drivers/net/e1000e/param.c: In function 'e1000_validate_option':

drivers/net/e1000e/param.c:155: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:158: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:164: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:177: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:188: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c: In function 'e1000e_check_options':

drivers/net/e1000e/param.c:210: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:212: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:313: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:317: error: 'struct net_device' has no member named 'dev'

drivers/net/e1000e/param.c:324: error: 'struct net_device' has no member named 'dev'

make[3]: *** [drivers/net/e1000e/param.o] Error 1

make[2]: *** [drivers/net/e1000e] Error 2

make[1]: *** [drivers/net] Error 2

make: *** [drivers] Error 2

So how can i downport this etherent driver to xen-sources 2.6.20-r6 ??

Or can someone tell me if this possible at all ??

Ciao

   Sandro

----------

## UgolinoII

Shiny new pcie intel card arrived this morning for my gentoo-xen box!

Imagine my delight when the e1000 module doesn't pick it up, and then i google to find this thread amongst others.

I'll post back once i get it working...

----------

## sandro123

Yes this would be great, good luck that you get it working.

Ciao

  Alessandro

----------

## UgolinoII

You can download Driver here from intel site....

http://downloadcenter.intel.com/filter_results.aspx?strTypes=all&ProductID=2247&OSFullName=Linux*&lang=eng&strOSs=39&submit=Go%21

```
xen ~ # tar -xvf e1000e-0.2.9.5.tar.gz 

e1000e-0.2.9.5/

e1000e-0.2.9.5/src/

e1000e-0.2.9.5/src/Makefile

e1000e-0.2.9.5/src/82571.c

e1000e-0.2.9.5/src/defines.h

e1000e-0.2.9.5/src/e1000.h

e1000e-0.2.9.5/src/es2lan.c

e1000e-0.2.9.5/src/ethtool.c

e1000e-0.2.9.5/src/hw.h

e1000e-0.2.9.5/src/ich8lan.c

e1000e-0.2.9.5/src/kcompat.c

e1000e-0.2.9.5/src/kcompat.h

e1000e-0.2.9.5/src/kcompat_ethtool.c

e1000e-0.2.9.5/src/lib.c

e1000e-0.2.9.5/src/netdev.c

e1000e-0.2.9.5/src/param.c

e1000e-0.2.9.5/src/phy.c

e1000e-0.2.9.5/COPYING

e1000e-0.2.9.5/README

e1000e-0.2.9.5/pci.updates

e1000e-0.2.9.5/e1000e.7

e1000e-0.2.9.5/e1000e.spec

e1000e-0.2.9.5/SUMS

xen ~ # cd e1000e-0.2.9.5/src

xen src # make install

make -C /lib/modules/2.6.21-xen/build SUBDIRS=/root/e1000e-0.2.9.5/src modules

make[1]: Entering directory `/usr/src/linux-2.6.21-xen'

  CC [M]  /root/e1000e-0.2.9.5/src/netdev.o

  CC [M]  /root/e1000e-0.2.9.5/src/ethtool.o

  CC [M]  /root/e1000e-0.2.9.5/src/param.o

  CC [M]  /root/e1000e-0.2.9.5/src/82571.o

  CC [M]  /root/e1000e-0.2.9.5/src/ich8lan.o

  CC [M]  /root/e1000e-0.2.9.5/src/es2lan.o

  CC [M]  /root/e1000e-0.2.9.5/src/phy.o

  CC [M]  /root/e1000e-0.2.9.5/src/lib.o

  CC [M]  /root/e1000e-0.2.9.5/src/kcompat.o

  LD [M]  /root/e1000e-0.2.9.5/src/e1000e.o

  Building modules, stage 2.

  MODPOST 1 modules

  CC      /root/e1000e-0.2.9.5/src/e1000e.mod.o

  LD [M]  /root/e1000e-0.2.9.5/src/e1000e.ko

make[1]: Leaving directory `/usr/src/linux-2.6.21-xen'

gzip -c ../e1000e.7 > e1000e.7.gz

# remove all old versions of the driver

find /lib/modules/2.6.21-xen -name e1000e.ko -exec rm -f {} \; || true

find /lib/modules/2.6.21-xen -name e1000e.ko.gz -exec rm -f {} \; || true

install -D -m 644 e1000e.ko /lib/modules/2.6.21-xen/kernel/drivers/net/e1000e/e1000e.ko

/sbin/depmod -a || true

install -D -m 644 e1000e.7.gz /usr/share/man/man7/e1000e.7.gz

man -c -P'cat > /dev/null' e1000e || true

No manual entry for e1000e

xen src # modprobe e1000e

xen src # lsmod

Module                  Size  Used by

e1000e                107940  0 

xen src # dmesg

...

e1000e: Intel(R) PRO/1000 Network Driver - 0.2.9.5

e1000e: Copyright (c) 1999-2008 Intel Corporation.
```

then configure networking as appropriate

hth

----------

