Beispiel #1
0
static void
revoke_local(struct revoke_master_st *st)
{
    DEBUG_CAPOPS("%s: called from %p\n", __FUNCTION__,
            __builtin_return_address(0));
    errval_t err;

    delete_steps_pause();

    err = monitor_revoke_mark_target(st->cap.croot,
                                     st->cap.cptr,
                                     st->cap.bits);
    PANIC_IF_ERR(err, "marking revoke");


    DEBUG_CAPOPS("%s ## revocation: mark phase\n", __FUNCTION__);
    // XXX: could check whether remote copies exist here(?), -SG, 2014-11-05
    err = capsend_relations(&st->rawcap, revoke_mark__send,
            &st->revoke_mc_st, &st->dests);
    PANIC_IF_ERR(err, "initiating revoke mark multicast");
}
Beispiel #2
0
errval_t
capsend_find_descendants(struct domcapref src, capsend_result_fn result_fn, void *st)
{
    errval_t err;

    struct capability cap;
    err = monitor_domains_cap_identify(src.croot, src.cptr, src.bits, &cap);
    if (err_is_fail(err)) {
        return err;
    }

    struct find_descendants_mc_st *mc_st;
    mc_st = malloc(sizeof(*mc_st));
    if (!mc_st) {
        return LIB_ERR_MALLOC_FAIL;
    }

    mc_st->result_fn = result_fn;
    mc_st->st = st;
    mc_st->have_result = false;
    return capsend_relations(&cap, find_descendants_send_cont,
            (struct capsend_mc_st*)mc_st, NULL);
}
Beispiel #3
0
void
revoke_ready__rx(struct intermon_binding *b, genvaddr_t st)
{
    DEBUG_CAPOPS("%s\n", __FUNCTION__);
    errval_t err;

    struct revoke_master_st *rvk_st = (struct revoke_master_st*)(lvaddr_t)st;
    if (!capsend_handle_mc_reply(&rvk_st->revoke_mc_st)) {
        DEBUG_CAPOPS("%s: waiting for remote cores\n", __FUNCTION__);
        // multicast not complete
        return;
    }

    DEBUG_CAPOPS("%s ## revocation: commit phase\n", __FUNCTION__);
    err = capsend_relations(&rvk_st->rawcap, revoke_commit__send,
            &rvk_st->revoke_mc_st, &rvk_st->dests);
    PANIC_IF_ERR(err, "enqueing revoke_commit multicast");

    delete_steps_resume();

    struct event_closure steps_fin_cont
        = MKCLOSURE(revoke_master_steps__fin, rvk_st);
    delete_queue_wait(&rvk_st->del_qn, steps_fin_cont);
}