LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 09-02-2005, 04:41 PM   #1
declassified
LQ Newbie
 
Registered: Sep 2005
Posts: 2

Rep: Reputation: 0
Applying MANY patches to kernel source


I currently run Fedora Core 3 with the PlanetCCRMA 2.6 kernel. It runs nicely, except that my WLAN and my USB-MP3-player don't work.

I read that I have to compile certain modules into the kernel, so I need the kernel source of the kernel (which I had installed as a binary RPM).

I downloaded a SRPM of the kernel and extracted it using "rpm -i", and it extracted into "/usr/src/redhat/SOURCES". Problem is, it extracted a LOT of ".patch" and ".config" files and One .bz2 file (linux-2.6.13.tar.bz2) which appears to be the vanilla kernel source. I extracted the source and it created a new subdirectory, as you know.

However, I can't figure out how to apply all these patches! Is there any specific way of doing it? Because some of the patches are made for other 2.6 kernels.
And: Is there a specific order in which I should apply the patches?

Is there any kind of script that could do the work for me?

Thanks a lot in advance!
 
Old 09-02-2005, 07:58 PM   #2
mlomker
Member
 
Registered: Aug 2005
Location: Saint Paul, MN
Distribution: Kubuntu
Posts: 34

Rep: Reputation: 15
Re: Applying MANY patches to kernel source

Hmm. I was under the impression that you can only apply one patch to a kernel. I'm curious why you have more than one to apply? I run Ubuntu but I didn't bother with their patch--I just applied the CZ patch, instead, and it works fine.
 
Old 09-02-2005, 09:19 PM   #3
cs-cam
Senior Member
 
Registered: May 2004
Location: Australia
Distribution: Gentoo
Posts: 3,545

Rep: Reputation: 57
I'd look on the Redhat site for docs or something. Sometimes there is an order, like if two patches want to modify the same piece of code, but that's probably not too common. I'd just give it a go applying them all in random order and see if you have any luck. You could always put all the patch files in a subdir and write a script to loop through the files and apply them to the source tree one-by-one...

Quote:
Hmm. I was under the impression that you can only apply one patch to a kernel. I'm curious why you have more than one to apply? I run Ubuntu but I didn't bother with their patch--I just applied the CZ patch, instead, and it works fine.
Not at all true. A patch or diff simply modifies the a file based on specifications that come in the patch. If you have 100 patches that all modify different files then they will all apply cleanly and everything might work, depending on how linking goes. kernel patchsets such as -ck, -cko, -love, -gentoo are generally a shitload of patches that someone has bundled together in one. The -cz patch probably is too but I couldn't find any info around to confirm that
 
Old 09-02-2005, 10:51 PM   #4
mlomker
Member
 
Registered: Aug 2005
Location: Saint Paul, MN
Distribution: Kubuntu
Posts: 34

Rep: Reputation: 15
Quote:
Originally posted by cs-cam
The -cz patch probably is too but I couldn't find any info around to confirm that
That was a typo on my part. I used the ck patch.
 
Old 09-03-2005, 12:00 AM   #5
foo_bar_foo
Senior Member
 
Registered: Jun 2004
Posts: 2,553

Rep: Reputation: 53
first try to make sure there are not just some modules you could load to get the things working
planet ccrma kernel is turbocharged but not stripped down so it should support those things
second just get the kernel-source package not the SRMP this has the proper files for adding modules
apt-cache search kernel
and make sure you have in /etc/apt/apt.conf
Allow-Duplicated {
"^kernel(-(BOOT|smp|bigmem|debug|doc|source.*)|)$";
"^gpg-pubkey$";
};


third if you build a new version go into the MAKEFILE and change VERSION= to something new
so you don't overwrite the modules for the one you have
that way you can play with it without damage.

i have built some kernels similar to that
when you apply the patch you have to do it with
patch -Np1 -i
for the ones that are the wrong version (low latency ?)
-N will let patch skip where it finds the patch has already been applied
it will also try to look around and fix where the lines arent exactly right
you will have to go through the patched code line by line where there are warnings and make sure everything is ok like where it skiped and possibly change some stuff using the patch file as a guide
not sure about patch order accept do the realtime security module last after making the bzimage and before you do the make modules
lookup the places the patches came from and get the original package if you need to for instructions (realtime security module is on sourceforge)
the configs are because the patches introduce some new config options some of which need other obscure options security module options or what new latency level to use and what other options need to support it.
be prepared for your new kernel not to work !

just as a side note the vanilla 2.6.13 with just the realtime security module and not the other patches will most likely work fine for you as well.
 
Old 09-03-2005, 12:45 AM   #6
declassified
LQ Newbie
 
Registered: Sep 2005
Posts: 2

Original Poster
Rep: Reputation: 0
Thanks for your replies so far!

I somehow got the USB mp3 player to work, so there's only the WLAN remaining.

The actual driver of the WLAN adapter seems to be there, since I can insert it using "modprobe ipw2200". However, the redhat network utility sais that the device is not available. I googled and found out that I need the firmware. So I downloaded it and extracted the ".fw" files to the hotplug firmware folder (/lib/firmware/).

Problem is, the firmware_class module doesn't seem to be built into the kernel. I have the PlanetCCRMA 2.6.11 rdt kernel and I can't find the source for it anywhere. I only find "kernel-debuginfo-2.6.11-0.15.rdt.rhfc3.ccrma.i686.rpm" on the PlanetCCRMA servers, which is about 235MB. Is this the kernel source?
 
Old 09-03-2005, 01:56 AM   #7
cs-cam
Senior Member
 
Registered: May 2004
Location: Australia
Distribution: Gentoo
Posts: 3,545

Rep: Reputation: 57
Quote:
Is this the kernel source?
I can't help you with much here but you can rest assured, that is not the kernel source
 
Old 09-03-2005, 07:00 AM   #8
mlomker
Member
 
Registered: Aug 2005
Location: Saint Paul, MN
Distribution: Kubuntu
Posts: 34

Rep: Reputation: 15
Quote:
Originally posted by declassified
The actual driver of the WLAN adapter seems to be there, since I can insert it using "modprobe ipw2200". However, the redhat network utility sais that the device is not available. I googled and found out that I need the firmware. So I downloaded it and extracted the ".fw" files to the hotplug firmware folder (/lib/firmware/).
I have the same adapter and recently went through the process. You get an error when you try to modprobe firmware_class? What is dmesg saying when you load the ipw2200 driver? Is it saying that it can't load the firmware?

When setting up my driver I discovered that my distro puts firmware in /lib/hotplug/firmware instead of /lib/firmware. It's easy to determine, though, because there will be other *.fw files in that directory already.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Applying patches. landfill Linux - Software 7 09-11-2005 05:05 PM
applying patches in gnome ?? mlu Linux - Software 0 07-05-2005 05:59 AM
Order of applying patches Steve1445 Linux - Newbie 4 01-12-2004 10:10 AM
applying software patches yocompia Slackware 4 07-29-2003 07:36 PM
Applying kernel patches questions wrc1944 Linux - General 4 05-19-2003 03:57 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 07:41 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration