[Top] [All Lists]

no bss cause strange values in insmod and ELF

Subject: no bss cause strange values in insmod and ELF
From: Shay Deloya <>
Date: Wed, 9 May 2001 09:47:05 +0300
Organization: Jungo Corp.
Continuing my previous problem...

I have created a module with no bss , and compiled it with kernel 2.2.
Comparing this module with same code that has bss and acts OK.

Inserting the module with modutiles 2.2.2/ busybox insmod causes 
a relocation overflow message , the reasons are: function obj_relocate: corrupted intsym->secidx value
  (not the needed index in the ELF)
   for some .text segments, other segments get their index value OK.
  the ELF file seems to be OK.
2. in function arch_apply_relocation: the wrong index (secidx=1006a1e8) 
   cause R_MIPS_26 symbols (jump commands) to have the value of 
   obj_reloc_overflow and then causes relocation overflow.

Does anyone knows why same module that has a variable in bss acts fine
 and the one without bss causes Relocation overflow in MIPS ? (in x86 there 
is no problem).

Searching the code I see there is no initialization of the secidx ,
 is it a problem of wrong reading of ELF files by insmod ? 

Attached the two ELF files , and obj_relocate values.

Shay Deloya
Software Developer
Jungo - R&D
Phone: 1-877-514-0537(USA)  +972-9-8859365(Worldwide) ext. 221
Fax:   1-877-514-0538(USA)  +972-9-8859366(Worldwide)

Attachment: elf.with_bss
Description: Text document

Attachment: elf.no_bss
Description: Text document

Attachment: obj_relocate_log
Description: Text document

<Prev in Thread] Current Thread [Next in Thread>
  • no bss cause strange values in insmod and ELF, Shay Deloya <=