LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   3com 3c940 Nic (https://www.linuxquestions.org/questions/linux-newbie-8/3com-3c940-nic-113426/)

andrewl41 11-07-2003 10:17 AM

3com 3c940 Nic
 
Hi,

I've recently installed RH9 on a new PC and I'm having a few problems. The worst of which is that I can't get my NIC working. My system is as follows:

P4 3.0GHz 800FSB (HT turned off)
Asus P4C800 Deluxe
On-board 3COM 3C940 NIC Gigabit LAN

People on this site have had and solved problems with this NIC but mine I feel are some what simpler than these others have faced.

I've downloaded the drivers from the Asus site for this and extracted them. There are or appear to be source files which I need to compile. The instructions said I need to ensure I have the kernel source in /usr/src/linux so I trawled the CD's, found the kernel rpm's, installed them and moved the relevant files to that folder. I then as instructed ran "make load" which I believe is meant to compile and somehow install the drivers, after which the card is meant to come up on it's own. Unfortunately this make command spews out a number of errors which for the life of me I cannot resolve. The exact output goes on for ever and would take months to type out but I believe the problem lies in the first line of the output which is:

usr/src/linux/include/linux/autoconf.h:1:2: #error Invalid kernel header included in userspace

If anyone has any ideas of what is causing this or advice on what to look into I would be extremely grateful.

Thanks,

Andrew

evil_Tak 11-07-2003 10:34 AM

Hmm, that header obviously isn't meant to be used in programs other than the kernel. However, the fact that you're building a kernel driver should nullify that. When you run `make load` , do the commands run look something like the following?
Code:

gcc -c -D__KERNEL__ -o blah.o blah.c

andrewl41 11-07-2003 10:40 AM

Thanks for replying,

The line directly below the one I posted is:

gcc -D_KERNEL__ -Wall -Wstrict-prototypes -O2 -DMODULE -I. -DSK_USE_CSUM -I /usr/src/linux/include -c -o skge.o skge.c

sbcdivision63 11-07-2003 10:44 AM

what was the file name for the kernel source you installed? i had the same problem and you have to install the actual kernel source which should be something like kerner-source-.....rpm. after that you should follow the advice of someone in another post which ill find for you that helped me get mine working

andrewl41 11-07-2003 10:50 AM

sbcdivision63,

I Looked through the source CD's and found kernel-2.4.20-8.src.rpm and installed it. That put all the files into /usr/src/redhat/SOURCES. In there I found linux-2.4.20.tar.bz2 and extracted that into the usr/src/linux folder which is where the read me told me it wanted the kernel source to be. It then complained on make that version.h and autoconf.h was missing, which it was. I eventually found these in glibc-kernheaders.tar.bz. I put them in the appropriate places and that has left me where I am now.

I had a feeling it may be to do with incorrect source files. Is there a *better* way of getting these files in place?

sbcdivision63 11-07-2003 10:53 AM

doh...that just installed the kernel...you need the kernel SOURCE...you can get it from ftp.redhat.com....after that go to this post: http://www.linuxquestions.org/questi...highlight=3com
and follow akje's advice...worked for me

ok im trying to find where you can find the kernel-source file...if you have an ftp client you can simply log onto ftp.redhat.com as anonymous and find it...let me log on xp so i can ftp and find it...after you install it it will automatically create those folders and everything so you can then just compile the driver

sbcdivision63 11-07-2003 12:02 PM

ok i uploaded the kernel source for you, you can download it here:
http://www.idlepress.com/nepr/kernel....20-8.i386.rpm

im assuming your on windows now so download it and burn it to a cd (hopefully you got a cd burner). then from there just copy onto linux and type rpm -i kernel-source-2.4.20-8.i386.rpm
that should work then follow the adive from my last post that links to the other post

andrewl41 11-10-2003 02:41 AM

sbcdivision63,

Thanks for all your help. I'm going to give that a go later today.

andrewl41 11-10-2003 03:34 AM

Thanks for all your help. With the correct source installed I got the card working effortlessly. No doubt I will be back in about 5 minutes with further problems but as time goes on they should get fewer and further between.

Thanks again.

andrewl41 11-10-2003 04:33 AM

Hi,

I've had another problem, just the next step on I'm affraid :)

I've followed all the steps in the link you suggested and my device has been recognised correctly. However, when I restart Linux I find an anoying failed message stating that eth0 '3c2000' does not seem to be present. This is obvisouly not the case and if I run "insmod 3c2000.o" the device comes up correctly. I have edited the 'hwconf' and 'modules.conf' files as suggested in the above thread.

If anyone has any advice I would apreciate it.

Thanks,

Andrew


All times are GMT -5. The time now is 01:30 AM.