patching kgdb to linux
i am trying to debug the linux kernel 2.6.10 using kgdb.i have downloaded the kgdb patch 2.6.10-mm2.bz2. after bunzip2 it gives me the file 2.6.10-mm2.
problem:
1- which type of file is this?
2- what patch command should i use(the options) so that i can patch it to linux 2.6.10.?
3-i have used the following command and it gives me some errors:
root@localhost root]# patch -p1 <2.6.10-mm2 can't find file to patch at input line 3 Perhaps you used the wrong -p or --strip option? The text leading up to this was:--------------------------|--- linux-2.6.10/arch/alpha/defconfig 2004-10-18 16:55:19.000000000 -0700
|+++ 25/arch/alpha/defconfig 2005-01-05
23:22:42.000000000 -0800
--------------------------
File to patch:
__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
Quoted 6 lines · On Sat, 24 Sep 2005 20:55:39 -0700 (PDT) anup badhe wrote:
i am trying to debug the linux kernel 2.6.10 using kgdb.i have downloaded the kgdb patch 2.6.10-mm2.bz2. after bunzip2 it gives me the file 2.6.10-mm2.
problem:
1- which type of file is this?
It's a diff; apply it using 'patch'.
Quoted 5 lines
2- what patch command should i use(the options) so that i can patch it to linux 2.6.10.?
3-i have used the following command and it gives me some errors:
Quoted 11 lines
root@localhost root]# patch -p1 <2.6.10-mm2 can't find file to patch at input line 3 Perhaps you used the wrong -p or --strip option? The text leading up to this was:--------------------------|--- linux-2.6.10/arch/alpha/defconfig 2004-10-18 16:55:19.000000000 -0700
|+++ 25/arch/alpha/defconfig 2005-01-05
23:22:42.000000000 -0800
--------------------------
File to patch:
$ cd linux-2.6.10 $ patch -p1 -b < /path/to/2.6.10-mm2 # wherever you put it $ make *config
---
~Randy
You can't do anything without having to do something else first. -- Belefant's Law
Quoted 10 lines · anup badhe
i am trying to debug the linux kernel 2.6.10 using kgdb.i have downloaded the kgdb patch 2.6.10-mm2.bz2. after bunzip2 it gives me the file 2.6.10-mm2.
problem:
1- which type of file is this?
2- what patch command should i use(the options) so that i can patch it to linux 2.6.10.?
3-i have used the following command and it gives me some errors:
Search the archives for a tool named ketchup.
It allows you to do:
ketchup 2.6-mm
And after a cup of coffee or three you have a full kernel tree available.
Sam
Quoted 11 lines · anup badhe
i am trying to debug the linux kernel 2.6.10 using kgdb.i have downloaded the kgdb patch 2.6.10-mm2.bz2. after bunzip2 it gives me the file 2.6.10-mm2.
problem:
1- which type of file is this?
2- what patch command should i use(the options) so that i can patch it to linux 2.6.10.?
3-i have used the following command and it gives me some errors:
Quoted 12 lines
root@localhost root]# patch -p1 <2.6.10-mm2 can't find file to patch at input line 3 Perhaps you used the wrong -p or --strip option? The text leading up to this was:--------------------------|--- linux-2.6.10/arch/alpha/defconfig 2004-10-18 16:55:19.000000000 -0700
|+++ 25/arch/alpha/defconfig 2005-01-05
23:22:42.000000000 -0800
--------------------------
File to patch:
For patch the same kernel version is necessary ... means if the patch is for 2.6.10-mm2 then you must have that kernel version .... means first get 2.6.10 and then get mm2 patch for it .... apply patch to the kernel and then apply patch for kgdb-2.6.10-mm2
mm2 patch you can get from kernel.org .........
for applying patch do :
1) extract the kernel source to /usr/src/ directory then do cd to that directory
2) run in kernel directorty ....... (don't extract the patch file from bz2 file)
bzip2 -dc <patch_file_name> < patch -p1
the above command should succeed and have to show you patching file msgs only ... don't show hunk or ask you something .... if its happening then you patch and kernel are not syncronized and patch wqon't be successful
3) then run the kgdb-2.6.10-mm2 patch like the above command in the kernel directory ...
Then recompile kernel and do select kgdb option from the kernel configuration menu
I hope this will work ...
--
Fawad Lateef