[arm-gnu] ARM 4.x and XIP problems
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[arm-gnu] ARM 4.x and XIP problems
- To: <arm-gnu@xxxxxxxxxxxxxxxx>
- Subject: [arm-gnu] ARM 4.x and XIP problems
- From: "Ales Mulej" <Ales.Mulej@xxxxxxxxxxx>
- Date: Tue, 9 Jun 2009 09:25:50 +0200
Hi,
I'm currently porting linux kernel version 2.6.29 to my ARM7TDMI
processor. At the same time I also change my old SnapGear cross compiler
3.4.4 to your latest arm-uclinuxeabi 4.3.3.
I have already ported the kernel and it seems working, but as soon as
the romfs mounts, everything crashes:
...
RAMDISK: romfs filesystem found at block 0
RAMDISK: Loading 259KiB [1 disk] into ram disk... done.
VFS: Mounted root (romfs filesystem) readonly on device 1:0.
Freeing init memory: 80K
BINFMT_FLAT: ROM mapping of file (we hope)
BINFMT_FLAT: Allocated data+bss+stack (30796 bytes): a29a0004
p=a29a7ffc
start_thread(regs=0xa3815f48, entry=0xa39d0044, start_stack=0xa29a7fb0)
Unhandled fault: vector exception (0x800) at 0x00000000
init[1] killed because of sig - 11
STACK DUMP:
0xa29a7fa0: 00000000 00000028 a39dadcc 00000000 a29a7fc0
...
init used greatest stack depth: 5484 bytes left
Kernel panic - not syncing: Attempted to kill init!
After investigation and help with uClinux forum, I found out, that this
is the problem with GCC 4.x.x, since doesn't support XIP and PIC at the
same time.
This is also reported as a bug:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28194.
If I downgrade the compiler back to 3.4.4, everything is working
perfectly fine.
I also try to build uClinux with GCC 4.3.3 with DISABLE_XIP flag
(without flags: -fPIC -msingle-pic-base).
If the code would be compiled properly, then the flags from FLAT
binary(running the flthdr) should be: >Flags: 0x1 ( Load to RAM )< but
they are
always >Flags: 0x2 ( Has-PIC-GOT )<. No matter how I change the build
settings, the result is XIP code, which doesn't work properly. Is there
any other
way to build the code without XIP functionality.
The second problem, which I found out is, that the enviroment variable
>FLTFLAGS< is always ignored. So it is very difficult to change any
default parameters durong the build time.
Regards,
Ales