Anonymous | Login | Signup for a new account | 11-10-2008 11:15 PST |
Main | My View | View Issues | Change Log | Docs |
Viewing Issue Simple Details [ Jump to Notes ] | [ View Advanced ] [ Issue History ] [ Print ] | |||||||||||
ID | Category | Severity | Reproducibility | Date Submitted | Last Update | |||||||
0001345 | [uClibc] Shared Library Support | major | always | 05-13-07 17:40 | 10-08-08 04:28 | |||||||
Reporter | redhatter | View Status | public | |||||||||
Assigned To | uClibc | |||||||||||
Priority | normal | Resolution | open | |||||||||
Status | assigned | Product Version | 0.9.27 | |||||||||
Summary | 0001345: [MIPS,powerpc] uClibc fails to mmap shared libraries with CONFIG_PAGE_SIZE_16KB set in kernel | |||||||||||
Description |
Hi... Recently I started building some uClibc userland environments for a mipsel target. My build host is a Lemote Fulong miniPC running a Loongson2E processor (subset MIPS-3), and I've also been doing testing with a Cobalt Qube2 (MIPS-4). Everything builds fine, however, when I try to chroot in on the Loongson, I get told uClibc "can't map" the libraries. However, when I rsync this chroot across to the Qube2, everything works fine. It would appear that uClibc's ld.so assumes the kernel uses a page size of 4KB (0x1000). When it specifies an offset of 0x3000, this works fine on a kernel with a 4KB page size, since 3 |
|||||||||||
Additional Information |
An strace reveals what's happening behind the scenes: execve("bin/busybox.dynamic", ["bin/busybox.dynamic"], [/* 57 vars */]) = 0 svr4_syscall() = -1 ERRNO_4090 (Unknown error 4090) stat("/etc/ld.so.cache", {st_mode=S_IFREG|0644, st_size=1728, ...}) = 0 open("/etc/ld.so.cache", O_RDONLY) = 3 old_mmap(NULL, 1728, PROT_READ, MAP_SHARED, 3, 0) = 0x2aab4000 close(3) = 0 open("/lib/libcrypt.so.0", O_RDONLY) = 3 old_mmap(NULL, 16384, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2aab8000 read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\10\0\1\0\0\0`\5\0\000"..., 16384) = 13584 old_mmap(NULL, 348160, PROT_NONE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2aaf0000 old_mmap(0x2aaf0000, 10692, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_FIXED, 3, 0) = 0x2aaf0000 old_mmap(0x2ab33000, 68, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED, 3, 0x3000) = -1 EINVAL (Invalid argument) old_mmap(NULL, 16384, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2aabc000 write(2, "", 0) = 0 write(2, "bin/busybox.dynamic", 19) = 19 write(2, ": can\'t map \'", 13) = 13 write(2, "/lib/libcrypt.so.0", 18) = 18 write(2, "\'\n", 2) = 2 munmap(0x2aabc000, 16384) = 0 munmap(0x2aaf0000, 348160) = 0 close(3) = 0 The Loongson's kernel was compiled with a page size of 16KB, whereas the Qube2 uses 4KB. Presently, I'm recompiling my kernel with 4KB pages to see if this fixes the problem. At minimum though, people should be made aware of this limitation in uClibc. |
|||||||||||
Attached Files | ||||||||||||
|
Copyright © 2000 - 2006 Mantis Group |