[tulip] Compiling in the tulip driver

David Shochat shochat@acm.org
Fri, 24 Nov 2000 12:27:52 -0500


I should be careful to make it clear what I personally have done. I have 
done this successfully with:
2.2.14-5
2.2.16-3
2.2.16-21
(all from RedHat)
In the last case, I had to take special measures (which have turned into 
a raging controversy) to make sure that the compile could see the 2.2.16 
kernel headers.
I guess I'm stepping into a hornet's nest now, but here goes...

Let me try to choose my words very carefully to avoid being flamed.

I suspect that your problem is that the compiler in your case is picking 
up kernel headers which are other than are needed for this particular 
kernel module to compile correctly. This is because of the nature of the 
error you say you are getting. If that is true, I think the solution for 
you is to use a -I switch in your compile command which points to a 
place that contains the 2.2 kernel headers. That is not exactly how I 
did it (I am now ashamed to admit even to my friends and family how I 
actually did it), but I believe it will work.

For example, if you have a RedHat 2.2 kernel-source RPM installed, 
(please note ****source****), then since that puts it in /usr/src/linux 
(against the advice of certain respected people), the switch:

  -I/usr/src/linux/include

would do it. Othewise, I'll bet you could just get a 2.2 kernel source 
tarfile installed anywhere at all (no need to actually compile the 
kernel) and have your -I point to its include directory.

james hill wrote:

>  >David Shochat (/shochat@acm.org/ 
> <mailto:shochat@acm.org?Subject=Re:%20[tulip]%20Compiling%20in%20the%20tulip%20driver&amp;In-Reply-To=&lt;3A1C4422.5020202@acm.org&gt;>)
> *>Date:* Wed Nov 22 2000 - 17:09:38 EST  wrote:
> 
>  >That's a novel approach and maybe there's a way  to make it work. 
> But if
>  >you just want to get things working, here is how  I did it:
>  >1. With the kernel built and running normally (using only  drivers that
>  >came with it), copy those 4 files into some random  directory.
>  >2. compile them using the compile commands that you will find  in 
> the .c
>  >source files.
>  >3. (as root) Copy pci-scan.o and tulip.o  into /lib/modules/`uname
>  >-r`/net [you may want to rename the tulip.o  that may have been built
>  >with your kernel first if you don't want to  clobber it, but that 
> tulip.o
>  >has never worked for me]
>  >4. depmod  -a
>  >5. modprobe tulip
>  >6. If all goes well you can try bringing up  the interface.
>  >7. And put alias eth<n> tulip in /etc/modules.conf  for automation.
> 
> In item 1 are you talking about  installation/distribution? If so 
> which one and what kernel version?
> 
> Because, if a try using that I get 'member not  found tbusy, start, 
> interrupt' when I go to compile.
>