mirror of
https://github.com/genodelabs/genode.git
synced 2024-12-18 21:27:56 +00:00
Ignore suspicious wake-up messages on OKL4
This commit is contained in:
parent
8bd02a5333
commit
22084dbfa5
@ -77,6 +77,7 @@ namespace Genode {
|
|||||||
|
|
||||||
Okl4::L4_MsgTag_t _faulter_tag; /* fault flags */
|
Okl4::L4_MsgTag_t _faulter_tag; /* fault flags */
|
||||||
Okl4::L4_ThreadId_t _last; /* faulted thread */
|
Okl4::L4_ThreadId_t _last; /* faulted thread */
|
||||||
|
Okl4::L4_Word_t _last_space; /* space of faulted thread */
|
||||||
Okl4::L4_Word_t _fault_addr; /* page-fault address */
|
Okl4::L4_Word_t _fault_addr; /* page-fault address */
|
||||||
Okl4::L4_Word_t _fault_ip; /* instruction pointer of faulter */
|
Okl4::L4_Word_t _fault_ip; /* instruction pointer of faulter */
|
||||||
Mapping _reply_mapping; /* page-fault answer */
|
Mapping _reply_mapping; /* page-fault answer */
|
||||||
@ -148,6 +149,11 @@ namespace Genode {
|
|||||||
*/
|
*/
|
||||||
Native_thread_id last() const { return _last; }
|
Native_thread_id last() const { return _last; }
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Return address space where the last page fault occurred
|
||||||
|
*/
|
||||||
|
unsigned long last_space() const { return _last_space; }
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return badge for faulting thread
|
* Return badge for faulting thread
|
||||||
*
|
*
|
||||||
|
@ -108,6 +108,7 @@ void Ipc_pager::wait_for_fault()
|
|||||||
if (verbose_page_fault)
|
if (verbose_page_fault)
|
||||||
print_page_fault(L4_Label(_faulter_tag), _fault_addr, _fault_ip, _last.raw);
|
print_page_fault(L4_Label(_faulter_tag), _fault_addr, _fault_ip, _last.raw);
|
||||||
}
|
}
|
||||||
|
_last_space = L4_SenderSpace().raw;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -54,14 +54,16 @@ void Pager_activation_base::entry()
|
|||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
/* prevent threads outside of core to mess with our wake-up interface */
|
/*
|
||||||
// enum { CORE_TASK_ID = 4 };
|
* Prevent threads outside of core to mess with our wake-up
|
||||||
// if (pager.last() != CORE_TASK_ID) {
|
* interface. This condition can trigger if a process gets
|
||||||
|
* destroyed which triggered a page fault shortly before getting
|
||||||
#warning Check for messages from outside of core
|
* killed. In this case, 'wait_for_fault()' returns (because of
|
||||||
if (0) {
|
* the page fault delivery) but the pager-object lookup will fail
|
||||||
|
* (because core removed the process already).
|
||||||
} else {
|
*/
|
||||||
|
enum { CORE_SPACE = 0 };
|
||||||
|
if (pager.last_space() == CORE_SPACE) {
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* We got a request from one of cores region-manager sessions
|
* We got a request from one of cores region-manager sessions
|
||||||
|
Loading…
Reference in New Issue
Block a user