void flounder_support_trigger_chan(struct waitset_chanstate *wc) { if (waitset_chan_is_registered(wc)) { errval_t err = waitset_chan_trigger(wc); assert(err_is_ok(err)); // shouldn't fail if registered } }
/** * \brief Poll an incoming UMP endpoint. * This is logically part of the UMP endpoint implementation, but placed here * for easier inlining. */ static inline void ump_endpoint_poll(struct waitset_chanstate *chan) { /* XXX: calculate location of endpoint from waitset channel state */ struct ump_endpoint *ep = (struct ump_endpoint *) ((char *)chan - offsetof(struct ump_endpoint, waitset_state)); if (ump_endpoint_can_recv(ep)) { errval_t err = waitset_chan_trigger(chan); assert(err_is_ok(err)); // should not be able to fail } }