base-hw: store Platform_pd pointer in Kernel::Pd

This enables the kernel to print out the label of the program
a thread belongs to.

fix #662
This commit is contained in:
Martin Stein
2013-02-22 10:30:48 +01:00
committed by Norman Feske
parent f3ef943bd8
commit 4b224dd67e
3 changed files with 27 additions and 13 deletions

View File

@@ -20,6 +20,7 @@
namespace Genode
{
class Platform_thread;
class Platform_pd;
class Tlb;
}
@@ -29,6 +30,7 @@ namespace Kernel
typedef Genode::addr_t addr_t;
typedef Genode::size_t size_t;
typedef Genode::Platform_thread Platform_thread;
typedef Genode::Platform_pd Platform_pd;
/**
* Unique opcodes of all syscalls supported by the kernel
@@ -143,6 +145,7 @@ namespace Kernel
*
* \param dst physical base of an appropriate portion of memory
* that is thereupon allocated to the kernel
* \param pd core local Platform_pd object
*
* \retval >0 ID of the new PD
* \retval 0 if no new PD was created
@@ -150,8 +153,8 @@ namespace Kernel
* Restricted to core threads. Regaining of the supplied memory is not
* supported by now.
*/
inline int new_pd(void * const dst) {
return syscall(NEW_PD, (Syscall_arg)dst); }
inline int new_pd(void * const dst, Platform_pd * const pd) {
return syscall(NEW_PD, (Syscall_arg)dst, (Syscall_arg)pd); }
/**