Commit Graph

21 Commits

Author SHA1 Message Date
Martin Stein
0b64328944 base: setup thread object for main thread in CRT0
For a main thread a thread object is created by the CRT0 before _main gets
called so that _main can already run in a generic environment that, e.g.,
catches stack overflows as a page-fault instead of corrupting the BSS.
Additionally dynamic programs have only one CRT0 - the one of the LDSO -
which does the initialization for both LDSO and program.

ref #989
2014-02-25 14:58:05 +01:00
Martin Stein
f4c724639b arm: raise stack size of main thread
With 64K stack size, when doing 'make core' in noux on base-hw, the main thread
of /libexec/gcc/arm-elf-eabi/4.7.2/cc1plus runs into a stack overflow during
the compilation of core/main.o . Thus raise the stack size to 128K.

fix #964
2013-12-03 08:33:26 +01:00
Christian Prochaska
1a22664fee Call exit handlers before notfying the parent
Fixes #941.
2013-11-05 12:01:13 +01:00
Josef Söntgen
eab8217bdb base: call proper __cxa_finalize
Fixes #909.
2013-10-17 11:05:20 +02:00
Christian Helmuth
f763e5ec2a Move main bootstrap to platform-specific object
To prevent multiple execution of main-bootstrap, I moved the code to a
statically initialized object. The reason for this change is that
_main() is exeuted twice when starting dynamic binaries. Now, the object
is part of the base-common library which is linked with ld.lib.so.
2013-09-26 15:00:16 +02:00
Christian Helmuth
4556a9e353 Preserve thread-context area as early as possible 2013-09-26 14:42:52 +02:00
Christian Helmuth
9f3c4c227e Put entry point at start of text segment / binary
Fixes #881.
2013-09-23 14:26:00 +02:00
Norman Feske
fe4a6d7d81 base: User-level tracing support 2013-08-14 18:43:19 +02:00
Alexander Boettcher
0079179f05 base: store initial ax and di registers in crt0.s
The values are used by a follow up commit by nova to get the boot CPU number.

Issue #814
2013-08-13 17:08:24 +02:00
Christian Prochaska
c962240922 crt0 cleanup
- use the generic 'crt0.s' for Linux
- move the read-only '__dso_handle' definition into the '.text' section
- move the '__initial_sp' definition into the '.bss' section
- remove the '_main_utcb' definition

Part of #766.
2013-07-05 12:37:43 +02:00
Martin Stein
ee4c98e093 base: provide BSS boundary marks in genode.ld
This enables us to use the generic linker script for
base-hw also.

Ref #766
2013-07-05 12:37:43 +02:00
Christian Prochaska
4a9b1c6aab base-linux: add ARM support
This patch introduces a new platform 'linux_arm' for building and running
Genode/Linux on an ARM device.

Known limitations:

- libc 'setjmp()'/'longjmp()' doesn't currently save/restore floating
  point registers

Fixes #746.
2013-05-24 14:55:37 +02:00
Christian Prochaska
ea3adfef9a Create the context area RM session at startup
With this patch, the thread context area RM session gets created at
program startup to have the thread context area's virtual address range
reserved right from the beginning.

Fixes #734.

This patch implies that all Genode processes try to create an RM
session. So a route to the RM service must be present even for processes
that have only a single thread. Hence, the patch contains an update of
affected components.
2013-05-07 21:56:07 +02:00
Norman Feske
73ab30c22c Update copyright headers to 2013 2013-01-10 21:44:47 +01:00
Martin Stein
ab0296bd20 base-mb: Fix compile and link errors
Fix #531
2012-11-29 09:55:04 +01:00
Alexander Boettcher
775b5a174b Reserve up to 8x4 bytes for the parent capability 2012-08-14 19:14:25 +02:00
Christian Prochaska
7d419893f9 ARM stack alignment
Align the stack on a 16-byte boundary as on the x86_32 platform.

Fixes #236.
2012-06-20 10:20:56 +02:00
Norman Feske
97cd7ca022 Hook for passing env pointer to main function
The new 'genode_envp' variable declared in '_main.cc' allows libc
plugins to supplying custom environment pointers to the main function.
This is needed by 3rd-party software such as GNU make, which expects the
environment pointer as third argument of the main function.
2012-05-18 19:32:44 +02:00
Stefan Kalkowski
42b7c01685 Unify policy name for Native_capability_tpl.
This commit unifies the policy name for the template argument for
Native_capability_tpl to Cap_dst_policy, like suggested by Norman in the
discussion resulting from issue #145. Moreover, it takes the memcpy
operation for copying a Native_capability out of the template, which is
included by a significant bunch of files, and separates it in a library,
analog to the suggestion in issue #145.
2012-03-10 15:52:13 +01:00
Norman Feske
08ce32215d Bump year in copyright headers to 2012 2012-01-03 15:35:05 +01:00
Genode Labs
da4e1feaa5 Imported Genode release 11.11 2011-12-22 16:19:25 +01:00