lp://staging/~bengal/helenos/openrisc
- Get this branch:
- bzr branch lp://staging/~bengal/helenos/openrisc
Branch merges
Branch information
Recent revisions
- 2033. By Jakub Jermar
-
Link ext4fs statically so that it can serve as a root FS when dynamic linking is enabled.
- 2032. By Martin Decky
-
fix kernel assertion (panic) on arm32 (BeagleBone and others) in frame_reference
_add() The macro PTE_GET_
FRAME_ARCH( ) retrieves a physical frame number from the page table entry. Although the frame_base_addr member of the page table entry structure (pte_t) is declared as an unsigned bit field, due to the integer promotion rules the value is interpreted as a signed integer. C99-ยง6.3.1.1: Boolean, characters, and integers
2: If an int can represent all values of the original type (as restricted by the width, for a bit-field), the value is converted to an int; otherwise, it is converted to an unsigned int. These are called the integer promotions. All other types are unchanged by the integer promotions.Since the bitwise shift operations in PTE_GET_
FRAME_ARCH( ) and especially in ADDR2PFN() (used by anon_share() in backend_anon.c) are applied on a signed integer, they create a false sign-extended (negative) physical frame number that is then passed to frame_reference _add(). This routine is obviously unable to find a valid physical memory zone for the malformed frame number and hits the assertion. The fix is to explicitly typecast the value in PTE_GET_ FRAME_ARCH( ) as unsigned. The original panic and stack trace for reference:
######> Kernel panic on cpu0 due to a failed assertion: <######
frame_reference_add() at generic/ src/mm/ frame.c: 976:
znum != (size_t) -1THE=0x802ca000: pe=1 thr=0x802c8000 task=0x802c1000 cpu=0x80292800
as=0x8000112c magic=0xfacefeed
0x802cbd2c: generic/src/debug/ stacktrace. o:stack_ trace() +0x0000001c
0x802cbd5c: generic/src/debug/ panic.o: panic_common( )+0x000001b4
0x802cbd94: generic/src/mm/ frame.o: frame_reference _add()+ 0x000000a8
0x802cbdf4: generic/src/mm/ backend_ anon.o: anon_share( )+0x00000168
0x802cbe44: generic/src/mm/ as.o:as_ area_share( )+0x000001bc
0x802cbe7c: generic/src/ipc/ ops/sharein. o:answer_ preprocess( )+0x0000007c
0x802cbeb4: generic/src/ipc/ sysipc. o:answer_ preprocess( )+0x000000a4
0x802cbf04: generic/src/ipc/ sysipc. o:sys_ipc_ answer_ fast()+ 0x0000007c
0x802cbf4c: generic/src/syscall/ syscall. o:syscall_ handler( )+0x000000e0
0x802cbf74: arch/arm32/src/exception. o:swi_exception ()+0x00000034
0x802cbfb4: generic/src/interrupt/ interrupt. o:exc_dispatch( )+0x00000144
cpu0: halted - 2031. By Vojtech Horky
-
Merge GCC port updates
libposix changes
* unimplemented methods do not abort, they warn instead
* add pthread.h, no implementation yet
* speed-up symbol redefinition (objcopy can work with static
libraries as well)
* add some functions already implemented in libc to libposixtoolchain changes
* experimental support for HelenOS-specific toolchain
* toolchain.sh --helenos-target
* adds *-helenos*- target, e.g. we can have amd64-helenos-gcc
* added as another choice to HelenOS.config, updated other scripts
accordingly
* added non-root compilation
* install into PKG/ to be later copied to real root
(package-like installation)
Branch metadata
- Branch format:
- Branch format 7
- Repository format:
- Bazaar repository format 2a (needs bzr 1.16 or later)
- Stacked on:
- lp://staging/helenos