* 2.6.26.8-rt16 powerpc and mem=...
@ 2009-02-17 17:46 Florian Boelstler
2009-02-17 17:54 ` Florian Boelstler
2009-02-18 11:48 ` Florian Boelstler
0 siblings, 2 replies; 4+ messages in thread
From: Florian Boelstler @ 2009-02-17 17:46 UTC (permalink / raw)
To: linux-rt-users
Hi,
I'm currently running 2.6.26.8-rt16 on a custom MPC8540-based board.
I was wondering whether there is any experience reducing the available
memory using the mem= kernel argument on linux-rt.
(Use case: A specific memory portion is reserved for configuration data,
which is set by an external system attached over PCI)
It seems that there is a race condition, which is hit during extraction
of the initrd only if the available memory is reduced.
(For vanilla 2.6.26.8 it works without any problems. The problem occurs
in 2.6.24.7-rt24 as well)
[...]
RAMDISK: Compressed image found at block 0
crc error
VFS: Mounted root (ext2 filesystem).
Freeing unused kernel memory: 140k init
Kernel panic - not syncing: No init found. Try passing init= option to
kernel.
Call Trace:
[d7441e90] [c00072c4] show_stack+0x54/0x188 (unreliable)
[d7441ec0] [c0020d58] panic+0x98/0x160
[d7441f50] [c0001bf8] name_to_dev_t+0x0/0x25c
[d7441f60] [c03059e0] kernel_init+0x250/0x284
[d7441ff0] [c000d910] kernel_thread+0x44/0x60
Sometimes the output is slightly different, and init is actually called.
But the file system is corrupt. E.g.:
[...]
RAMDISK: Compressed image found at block 0
RAMDISK: incomplete write (-28 != 7032) 33554432
crc error
VFS: Mounted root (ext2 filesystem).
Freeing unused kernel memory: 140k init
init started: BusyBox v1.1.0 (2007.01.23-00:05+0000) multi-call binary
[...]
EXT2-fs error (device ram0): ext2_check_page: bad entry in directory
#1594: : directory entry across blocks - offset=0, inode=909341804,
rec_len=14392, name_len=55
Remounting filesystem read-only
[...]
In a single case Linux even booted without any problems.
Some details about my setup:
- 512MB RAM in total
- Memory available for Linux is reduced to 508M (mem=520192K)
- Linux is booted from U-Boot (v1.2.0), which places the initrd image in
lowmem below 0x18000000 (initrd_high=0x18000000). This is done because
Linux seems to not allow having the initrd in highmem. (Output from
kernel regarding CAMs: "Memory CAM mapping: CAM0=256Mb, CAM1=64Mb,
CAM2=64Mb residual: 124Mb")
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: 2.6.26.8-rt16 powerpc and mem=...
2009-02-17 17:46 2.6.26.8-rt16 powerpc and mem= Florian Boelstler
@ 2009-02-17 17:54 ` Florian Boelstler
2009-02-18 11:48 ` Florian Boelstler
1 sibling, 0 replies; 4+ messages in thread
From: Florian Boelstler @ 2009-02-17 17:54 UTC (permalink / raw)
To: linux-rt-users
Sorry, that message was sent too early.
Additionally I put the boot output here:
http://pastebin.ch/1009
Please let me know if you need any other information, which may help
fixing this issue.
Thanks.
Cheers,
Florian
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: 2.6.26.8-rt16 powerpc and mem=...
2009-02-17 17:46 2.6.26.8-rt16 powerpc and mem= Florian Boelstler
2009-02-17 17:54 ` Florian Boelstler
@ 2009-02-18 11:48 ` Florian Boelstler
2009-02-18 16:13 ` Florian Boelstler
1 sibling, 1 reply; 4+ messages in thread
From: Florian Boelstler @ 2009-02-18 11:48 UTC (permalink / raw)
To: linux-rt-users
Hi,
I did some further tests in the meanwhile.
If the memory is reduced to 256M with mem=256M Linux does not make use
of highmem, since memory can be completely mapped using a single CAM entry.
(Kernel output: Memory CAM mapping: CAM0=256Mb, CAM1=0Mb, CAM2=0Mb
residual: 0Mb)
In that case the initrd is successfully mounted at all times up to now.
When I was starting to play with mem=... on vanilla kernels I was told
[1] that it should be trivial to allow more than three levels of CAM
mappings. May be this is an intermediate solution.
Florian
[1] http://ozlabs.org/pipermail/linuxppc-embedded/2008-June/030638.html
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: 2.6.26.8-rt16 powerpc and mem=...
2009-02-18 11:48 ` Florian Boelstler
@ 2009-02-18 16:13 ` Florian Boelstler
0 siblings, 0 replies; 4+ messages in thread
From: Florian Boelstler @ 2009-02-18 16:13 UTC (permalink / raw)
To: linux-rt-users
Hi again,
I adapted the kernel to allow a four-level CAM mapping.
If the memory is reduced to 448M (i.e. result is CAM0=256Mb, CAM1=64Mb,
CAM2=64Mb CAM3=64Mb residual: 0Mb) there will be no highmem assigned by
the kernel at all.
In that case the U-Boot boot loader is set to initrd_high=0x1C000000,
i.e. it will put the initrd right at the "upper end" of available memory.
linux-rt doesn't fail to mount the initrd.
I tend to believe that the issue is related to the use of highmem in
linux-rt (OK, pretty vague:).
Florian
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2009-02-18 16:14 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-17 17:46 2.6.26.8-rt16 powerpc and mem= Florian Boelstler
2009-02-17 17:54 ` Florian Boelstler
2009-02-18 11:48 ` Florian Boelstler
2009-02-18 16:13 ` Florian Boelstler
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.