[Top] [All Lists]

Re: Kernel build problem

To: Keith Owens <kaos@xxxxxxx>
Subject: Re: Kernel build problem
From: "Vladimir G. Ivanovic" <vladimir@xxxxxxx>
Date: Wed, 01 Sep 2004 07:07:15 -0700
Cc: kdb@xxxxxxxxxxx
In-reply-to: Your message of "Wed, 01 Sep 2004 20:59:00 +1000." <5368.1094036340@xxxxxxxxxxxxxxx>
Reply-to: "Vladimir G. Ivanovic" <vladimir@xxxxxxx>
Sender: kdb-bounce@xxxxxxxxxxx

Thanks for your quick response!

1. Should I file a Fedora bug?

2. I didn't know about grep's "-r" option. Works like a charm (and it's
   nearly twice as fast as "find . -type f -exec fgrep...").

3. I'm now getting a different error:

   gcc -Wp,-MD,kdb/modules/.kdbm_pg.o.d -nostdinc -iwithprefix include 
-D__KERNEL__ -Iinclude -Iinclude2 -I/usr/src/linux-2.6.8-1.533/include 
-I/usr/src/linux-2.6.8-1.533/kdb/modules -Ikdb/modules -Wall 
-Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -pipe 
-msoft-float -m32 -fno-builtin-sprintf -fno-builtin-log2 -fno-builtin-puts 
-mpreferred-stack-boundary=2 -march=pentium3 -fno-optimize-sibling-calls 
-Iinclude/asm-i386/mach-default -O2 -g -Wdeclaration-after-statement  
-DKBUILD_BASENAME=kdbm_pg -DKBUILD_MODNAME=kdbm_pg -c -o kdb/modules/kdbm_pg.o 
   /usr/src/linux-2.6.8-1.533/kdb/modules/kdbm_pg.c: In function 
   /usr/src/linux-2.6.8-1.533/kdb/modules/kdbm_pg.c:284: error: `PG_maplock' 
undeclared (first use in this function)
   /usr/src/linux-2.6.8-1.533/kdb/modules/kdbm_pg.c:284: error: (Each 
undeclared identifier is reported only once
   /usr/src/linux-2.6.8-1.533/kdb/modules/kdbm_pg.c:284: error: for each 
function it appears in.)

The only occurrence of PG_maplock is on line 284 of kdbm_pg.c. Should I
be using a v4.4-2.6.8 patch instead?

--- Vladimir

Vladimir G. Ivanovic                        http://leonora.org/~vladimir
Palo Alto, CA 94306                                      +1 650 678 8014

>>>>> "ko" == Keith Owens <kaos@xxxxxxx> writes:

    ko> On Tue, 31 Aug 2004 23:07:04 -0700, 
    ko> "Vladimir G. Ivanovic" <vladimir@xxxxxxx> wrote:
    >> I applied the KDB v4.4-2.6.9-rc1 patches to linux-2.6.8-1.533 (*), and
    >> now I get a strange build error:
    >> /usr/src/linux-2.6.8-1.533/arch/i386/kernel/entry.S: Assembler messages:
    >> /usr/src/linux-2.6.8-1.533/arch/i386/kernel/entry.S:431: Error: symbol 
`int80_ret_start_marker' is already defined
    >> /usr/src/linux-2.6.8-1.533/arch/i386/kernel/entry.S:431: Error: symbol 
`int80_ret_end_marker' is already defined
    >> Here's the compilation line that causes the error:
    >> gcc -Wp,-MD,arch/i386/kernel/.entry.o.d -nostdinc -iwithprefix include 
-D__KERNEL__ -Iinclude -Iinclude2 -I/usr/src/linux-2.6.8-1.533/include 
-D__ASSEMBLY__ -I/usr/src/linux-2.6.8-1.533/include/asm-i386/mach-default 
-Iinclude/asm-i386/mach-default -m32 -traditional -m32  -c -o 
arch/i386/kernel/entry.o /usr/src/linux-2.6.8-1.533/arch/i386/kernel/entry.S
    >> But, here's the rub: int80_ret_start_marker is not being redefined at
    >> line 431 of entry.S AFAICT. If I grep through all the sources, I find
    >> that int80_ret_start_marker is only referenced twice:
    >> # find . -name "*[chS]" -exec fgrep -Hn int80_ret_end_marker {} \;
    >> ./arch/i386/kernel/entry.S:140: cmpl $int80_ret_end_marker, %eax;        
    >> ./arch/i386/kernel/entry.S:171:int80_ret_end_marker:                     
    >> and neither of them are at line 431.
    >> What gives? Would someone illuminate me?
    ko> int80_ret_end_marker is only defined once, but in a macro.  If the
    ko> macro gets used twice, you end up with a duplicate label.  Why on earth
    ko> somebody defined a macro so it can only be used once is beyond me,
    ko> macros are meant to be reusable.  Add this fix.
    ko> Index: linux-2.6.8/arch/i386/kernel/entry.S
    ko> ===================================================================
    ko> --- linux-2.6.8.orig/arch/i386/kernel/entry.S   2004-09-01 
17:05:09.000000000 +1000
    ko> +++ linux-2.6.8/arch/i386/kernel/entry.S        2004-09-01 
20:52:58.000000000 +1000
    ko> @@ -294,7 +294,7 @@ ENTRY(kdb_call)
    ko>         pushl $7                # KDB_REASON_ENTRY
    ko>         call  kdb
    ko>         addl  $12,%esp          # remove args
    ko> -       RESTORE_ALL
    ko> +       jmp restore_all
    ko>  #endif
    ko>  /*
    ko> BTW, the grep family now supports recursive search, this is much faster.
    ko> grep -rIHn int80_ret_end_marker .
Use http://oss.sgi.com/ecartis to modify your settings or to unsubscribe.
<Prev in Thread] Current Thread [Next in Thread>