Improve company productivity with a Business Account.Sign Up

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 345
  • Last Modified:

Editing the Kernel to make hardware work

Im haveing bother getting my modeom and sound to work in my new Mandrake installation. MY first time working with Linux so im not really sure what needs done. My modem is a Zyxel 630-11 and my soundcrad is an Audigy 2 ZS. I have found drivers for both but im just not sure how to get them installed.



Both talk about editing the Kernel and recompling it. The instructions say "type this or type that",but where should I be typing these commands? How can I open the Kernel to edit it and how do I compile it again?
  • 3
  • 3
1 Solution
Heres how to compile your kernel. If you havent got the kernel source on your pc get from the cd you installed mandrake from.

ok you have to be root, you then have to go to the directory where your source is. It is usually something like - /usr/src/linux-2.x.x etc when your in that directory you type make menuconfig this loads a console GUI that allows you to select options and modules. The site: shows a rudimentary version of the type of menu you'll see ie this bit

"Code maturity level options  --->
     [ * ] Prompt for development and/or incomplete code/drivers
 Loadable module support  --->
     [ * ] Enable loadable module support
     [ * ]   Module unloading
 Device Drivers  --->
     Networking support  --->
         Networking options  --->
             < M > Asynchronous Transfer Mode (ATM) (EXPERIMENTAL)
                 < M >   RFC1483/2684 Bridged protocols
             < M > PPP (point-to-point protocol) support
                 < M >   PPP support for async serial ports
                 < M >   PPP support for sync tty ports
                 < M >   PPP Deflate compression          
     USB support  --->
     < M > Support for USB
     [ * ]   USB device filesystem
     < M >   EHCI HCD (USB 2.0)
     < M >   OHCI HCD support
     < M >   UHCI HCD support
 Library routines  --->
     < M > CRC32 functions"

your menu should have the same options to these shown above, on your menu tick what is ticked above and then save your changes keep the default name which will be something like .config.

The you compile the kernel by doing the following commads

 make ; make modules ; make modules_install

once done you have to copy your new bzImage to the /boot I think from within your current directory assuming your in the source dir the path is arch/i386/boot

now cp bzImage /boot


Then edit your /etc/lilo.conf

and add the entry

image = /boot/bzImage
root = /dev/hda1 <- or whatever your /boot partition is on
label = "New Kernel"

save these changes then exit your editor and type lilo to update lilo

Then resume from step 4 at
I haven't looked at the sites, and I don't know this hardware, but dont do this unless you have to. Check:

1) What is the module (driver) called? i.e. what is it that you would either 'modprobe' or 'insmod'? does it already exist on you system?

2) If you're only compiling a new module, you dont have to recompile the whole kernel; just put the source files in place (if they aren't already), and 'make modules modules_install'

3) Most distros configure their kernel so that they have support for pretty much all recent hardware, even if they may not detect them automagically. Try to run adsl-setup first and see what happens.
me1191Author Commented:
If I run the adsl set up it only finds the nvidia LAN built into my motherboard. So im assuming that it has no idea the modem is connected (usb).

Im having problems acually finding the kernel source code. However I have found a website that allows you to download any kernel version (in my case 2.6.3). The trouble with this is that im not sure what to download as there are five files under this particular kernel version...

linux-2.6.3.tar.bz2        17-Feb-2004 20:35   33M  
linux-2.6.3.tar.bz2.sign   17-Feb-2004 20:35  248  
linux-2.6.3.tar.gz         17-Feb-2004 20:35   41M  
linux-2.6.3.tar.gz.sign    17-Feb-2004 20:35  248  
linux-2.6.3.tar.sign       17-Feb-2004 20:35  248

This is the URL:-

Also, through trying some screensavers I can see that my graphics card driver has either not been install, or not installed properly during setup. So ive found the driver on ATI's website and im stuck with it too.

How do I run Is there an easier way to find which Xfree86 version im running?

Thankyou for your time.

Build your data science skills into a career

Are you ready to take your data science career to the next step, or break into data science? With Springboard’s Data Science Career Track, you’ll master data science topics, have personalized career guidance, weekly calls with a data science expert, and a job guarantee.

me1191Author Commented:
I was looking under "Hardware" and I can see my modem listed under scanners. Its listed there along with my LCD screen (matrix orbital). For the modem it says "Port libusb:002:002". So I assume it knows my modem is there, so how can I make it work? If I click the "run config tool" button then it says "alcatel telecom dynamite modem is nt in the scanner database, configure it manually?" (then I will get a list of scanners).

There is no section for modems in Hardware. All I have in there is a section called "Ethernet Card".
Which distribution are you using? e.g. RedHat, SuSE, Lindows...?

Chances are your distro is using a kernel with patches that haven't made it into the official 'vanilla' kernel tree yet, so I wouldn't go messing about with that.

once I knows which distribution you're using, it becomes a lot easier to give specific directions.

me1191Author Commented:
I mentioned the distro in the first line of my original post. However, Mandrake 10. Kernel version 2.6.3
Right, sorry, I missed that. Don't use mandrake myself, so bear with me...

In that case, you should use their software installation tool (which I dont know what's called) install the package 'kernel-source-???' where ??? matched your kernel version (which you can find by typing 'uname -r' at a command prompt (you can get one by e.g. pressing Alt+F2 and typing 'konsole' there).

Now, still using the command prompt do, 'su - ' to become root (you'll need your root passwd there), then 'cd /usr/src/', then do a 'ls -l'. You should see at least a directory called 'linux-???', where ??? is,again, the kernel version. There should also be a symbolic link called just linux, which points to the linux-??? directory. E.g. on my suse box:
einarth@dude:~ > ls -l /usr/src
lrwxrwxrwx   1 root root  17 2004-09-02 11:09 linux -> linux-2.6.5-7.108
drwxr-xr-x  21 root root 800 2004-09-03 16:47 linux-2.6.5-7.108

if that link isn't there, create it with 'ln -s linux-??? linux'.

Next, 'cd linux' and 'make oldconfig', then 'make menuconfig'. This will start the kernel configuration process. This is where you follow the instructions on the web sites, and in the first comment of this thread to configure support for your hardware.

Once that is done, you compile the kernel with 'make bzImage', then you compile the modules/drivers with 'make modules'. Next you install the modules with 'make modules_install'. This takes time, and requires you to have the development tools installed as well, i.e. gcc, glibc-devel etc.

Now, make sure you have a rescue or a bootable cd ready in case something bad happens (I recommend knoppix), because if the next steps fail for some reason, you propably wont be able to boot.

What you do next is to copy your newly compiled kernel into the boot dir, like so 'cp arch/i386/boot/bzImage /boot/linux-????' (again the ???? means.. you know).

Last thing on the list is to tell your bootloader about the new kernel. I dont know if mandrake uses lilo or grub ( you can 'rpm -qa | egrep -i "lilo|grub"' to find out), but in case of lilo, see comment 2 in this thread. In case of grub, open grub's config file (called either grub.conf or menu.lst and is somewhere under the /boot directory) with a editor (pico or nano or something else). Look for something like this:

title Linux
    kernel (hd0,1)/boot/vmlinuz root=/dev/hda2
    initrd (hd0,1)/boot/initrd

(this is from suse, your will be different, but similar)

Make another entry exactly like the one you found, but give it a different title, and make the kernel argument match your freshly compiled kernel.

Reboot, cross fingers, and once the boot screen comes up, select the new title to boot.


Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

  • 3
  • 3
Tackle projects and never again get stuck behind a technical roadblock.
Join Now