本文整理汇总了C++中FsmChangeState函数的典型用法代码示例。如果您正苦于以下问题:C++ FsmChangeState函数的具体用法?C++ FsmChangeState怎么用?C++ FsmChangeState使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了FsmChangeState函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: lc_release_ind
static void
lc_release_ind(struct FsmInst *fi, int event, void *arg)
{
struct PStack *st = fi->userdata;
FsmDelTimer(&st->l3.l3m_timer, 52);
FsmChangeState(fi, ST_L3_LC_REL);
skb_queue_purge(&st->l3.squeue);
l3ml3p(st, DL_RELEASE | INDICATION);
}
示例2: dout_underrun
static void dout_underrun(struct FsmInst *fsm, int event, void *arg)
{
struct st5481_adapter *adapter = fsm->userdata;
struct st5481_d_out *d_out = &adapter->d_out;
if (test_bit(0, &d_out->busy) || test_bit(1, &d_out->busy)) {
FsmChangeState(&d_out->fsm, ST_DOUT_WAIT_FOR_NOT_BUSY);
} else {
dout_stop(fsm, event, arg);
}
}
示例3: l1_go_f3
static void
l1_go_f3(struct FsmInst *fi, int event, void *arg)
{
struct st5481_adapter *adapter = fi->userdata;
if (fi->state == ST_L1_F7)
ph_disconnect(adapter);
FsmChangeState(fi, ST_L1_F3);
D_L1L2(adapter, PH_DEACTIVATE | INDICATION, NULL);
}
示例4: lc_start_delay_check
static void
lc_start_delay_check(struct FsmInst *fi, int event, void *arg)
/* 20/09/00 - GE timer not user for NI-1 as layer 2 should stay up */
{
struct PStack *st = fi->userdata;
FsmChangeState(fi, ST_L3_LC_REL_DELAY);
/* 19/09/00 - GE timer not user for NI-1 */
if (st->protocol != ISDN_PTYPE_NI1)
FsmAddTimer(&st->l3.l3m_timer, DREL_TIMER_VALUE, EV_TIMEOUT, NULL, 50);
}
示例5: l1_activate
static void
l1_activate(struct FsmInst *fi, int event, void *arg)
{
struct st5481_adapter *adapter = fi->userdata;
st5481_ph_command(adapter, ST5481_CMD_DR);
st5481_ph_command(adapter, ST5481_CMD_PUP);
FsmRestartTimer(&adapter->timer, TIMER3_VALUE, EV_TIMER3, NULL, 2);
st5481_ph_command(adapter, ST5481_CMD_AR8);
FsmChangeState(fi, ST_L1_F4);
}
示例6: lc_connect
static void
lc_connect(struct FsmInst *fi, int event, void *arg)
{
struct PStack *st = fi->userdata;
struct sk_buff *skb = arg;
FsmChangeState(fi, ST_L3_LC_ESTAB);
while ((skb = skb_dequeue(&st->l3.squeue))) {
st->l3.l3l2(st, DL_DATA | REQUEST, skb);
}
st->l3.l3l4(st, DL_ESTABLISH | INDICATION, NULL);
}
示例7: l2_st6_dm_release
static void
l2_st6_dm_release(struct FsmInst *fi, int event, void *arg)
{
layer2_t *l2 = fi->userdata;
msg_t *msg = arg;
if (get_PollFlagFree(l2, msg)) {
stop_t200(l2, 8);
lapb_dl_release_l2l3(l2, CONFIRM);
FsmChangeState(fi, ST_L2_4);
}
}
示例8: tei_id_verify
static void
tei_id_verify(struct FsmInst *fi, int event, void *arg)
{
struct PStack *st = fi->userdata;
if (st->ma.debug)
st->ma.tei_m.printdebug(&st->ma.tei_m,
"id verify request for tei %d", st->l2.tei);
put_tei_msg(st, ID_VERIFY, 0, st->l2.tei);
FsmChangeState(&st->ma.tei_m, ST_TEI_IDVERIFY);
FsmAddTimer(&st->ma.t202, st->ma.T202, EV_T202, NULL, 2);
st->ma.N202 = 2;
}
示例9: l2_queue_ui_assign
static void
l2_queue_ui_assign(struct FsmInst *fi, int event, void *arg)
{
layer2_t *l2 = fi->userdata;
msg_t *msg = arg;
msg_queue_tail(&l2->ui_queue, msg);
FsmChangeState(fi, ST_L2_2);
if ((msg = create_link_msg(MDL_ASSIGN | INDICATION, 0, 0, NULL, 0))) {
if (l2_tei(l2->tm, msg))
free_msg(msg);
}
}
示例10: l2_mdl_assign
static void
l2_mdl_assign(struct FsmInst *fi, int event, void *arg)
{
layer2_t *l2 = fi->userdata;
msg_t *msg = arg;
mISDNuser_head_t *hh;
FsmChangeState(fi, ST_L2_3);
msg_trim(msg, 0);
hh = (mISDNuser_head_t *)msg_put(msg, mISDNUSER_HEAD_SIZE);
hh->prim = MDL_ASSIGN | INDICATION;
hh->dinfo = 0;
if (l2_tei(l2->tm, msg))
free_msg(msg);
}
示例11: l2_released
static void
l2_released(struct FsmInst *fi, int event, void *arg)
{
layer2_t *l2 = fi->userdata;
msg_t *msg = arg;
if (!get_PollFlag(l2, msg)) {
l2_mdl_error_ua(fi, event, arg);
return;
}
free_msg(msg);
stop_t200(l2, 6);
lapb_dl_release_l2l3(l2, CONFIRM);
FsmChangeState(fi, ST_L2_4);
}
示例12: lc_release_req
static void
lc_release_req(struct FsmInst *fi, int event, void *arg)
{
struct PStack *st = fi->userdata;
if (test_bit(FLG_L2BLOCK, &st->l2.flag)) {
if (st->l3.debug)
l3_debug(st, "lc_release_req: l2 blocked");
/* restart release timer */
FsmAddTimer(&st->l3.l3m_timer, DREL_TIMER_VALUE, EV_TIMEOUT, NULL, 51);
} else {
FsmChangeState(fi, ST_L3_LC_REL_WAIT);
st->l3.l3l2(st, DL_RELEASE | REQUEST, NULL);
}
}
示例13: l2_stop_multi
static void
l2_stop_multi(struct FsmInst *fi, int event, void *arg)
{
layer2_t *l2 = fi->userdata;
msg_t *msg = arg;
FsmChangeState(fi, ST_L2_4);
FsmDelTimer(&l2->t203, 3);
stop_t200(l2, 4);
send_uframe(l2, msg, UA | get_PollFlag(l2, msg), RSP);
msg_queue_purge(&l2->i_queue);
freewin(l2);
lapb_dl_release_l2l3(l2, INDICATION);
}
示例14: establishlink
static void
establishlink(struct FsmInst *fi)
{
layer2_t *l2 = fi->userdata;
u_char cmd;
clear_exception(l2);
l2->rc = 0;
cmd = (test_bit(FLG_MOD128, &l2->flag) ? SABME : SABM) | 0x10;
send_uframe(l2, NULL, cmd, CMD);
FsmDelTimer(&l2->t203, 1);
restart_t200(l2, 1);
test_and_clear_bit(FLG_PEND_REL, &l2->flag);
freewin(l2);
FsmChangeState(fi, ST_L2_5);
}
示例15: l2_disconnect
static void
l2_disconnect(struct FsmInst *fi, int event, void *arg)
{
layer2_t *l2 = fi->userdata;
msg_t *msg = arg;
msg_queue_purge(&l2->i_queue);
freewin(l2);
FsmChangeState(fi, ST_L2_6);
l2->rc = 0;
send_uframe(l2, NULL, DISC | 0x10, CMD);
FsmDelTimer(&l2->t203, 1);
restart_t200(l2, 2);
if (msg)
free_msg(msg);
}