From d30edd48410fb70bb5b440bd72729dd155ba0ea0 Mon Sep 17 00:00:00 2001 From: Martin Stein Date: Wed, 12 Mar 2014 16:29:44 +0100 Subject: [PATCH] hw: make RM faults less noisy in release mode If an RM fault ends up in any trouble, the faulter remains paused and the pager activation continues with the next fault. Thus we can print a warning instead of an error and safe execution time in release mode. ref #1096 --- base-hw/src/core/rm_session_support.cc | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/base-hw/src/core/rm_session_support.cc b/base-hw/src/core/rm_session_support.cc index de9de024a5..941dc458a2 100644 --- a/base-hw/src/core/rm_session_support.cc +++ b/base-hw/src/core/rm_session_support.cc @@ -47,12 +47,12 @@ void Rm_client::unmap(addr_t, addr_t virt_base, size_t size) /* remove mapping from the translation table of the thread that we serve */ Platform_thread * const pt = (Platform_thread *)badge(); if (!pt) { - PERR("failed to get platform thread of RM client"); + PWRN("failed to get platform thread of RM client"); return; } Tlb * const tlb = pt->tlb(); if (!tlb) { - PERR("failed to get page table of RM client"); + PWRN("failed to get page table of RM client"); return; } tlb->remove_region(virt_base, size); @@ -91,7 +91,7 @@ int Pager_activation_base::apply_mapping() bool ram_ok = platform()->ram_alloc()->alloc_aligned(1<fault_occured(s); break; } - PERR("unknown pager object"); + PWRN("unknown pager object"); } /* fetch fault data */ Platform_thread * const pt = (Platform_thread *)o->badge(); if (!pt) { - PERR("failed to get platform thread of faulter"); + PWRN("failed to get platform thread of faulter"); continue; } unsigned const thread_id = pt->id(); @@ -142,13 +142,13 @@ void Pager_activation_base::entry() memcpy(utcb, read_regs, sizeof(read_regs)); addr_t * const read_values = (addr_t *)&_fault; if (Kernel::access_thread_regs(thread_id, READS, 0, read_values, 0)) { - PERR("failed to read fault data"); + PWRN("failed to read fault data"); continue; } /* handle fault */ if (o->pager(*this)) { continue; } if (apply_mapping()) { - PERR("failed to apply mapping"); + PWRN("failed to apply mapping"); continue; } o->fault_resolved();