diff options
Diffstat (limited to 'drivers/isdn/mISDN/fsm.c')
-rw-r--r-- | drivers/isdn/mISDN/fsm.c | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/drivers/isdn/mISDN/fsm.c b/drivers/isdn/mISDN/fsm.c index b5d6553..26477d4 100644 --- a/drivers/isdn/mISDN/fsm.c +++ b/drivers/isdn/mISDN/fsm.c @@ -28,23 +28,23 @@ void mISDN_FsmNew(struct Fsm *fsm, - struct FsmNode *fnlist, int fncount) + struct FsmNode *fnlist, int fncount) { int i; fsm->jumpmatrix = kzalloc(sizeof(FSMFNPTR) * fsm->state_count * - fsm->event_count, GFP_KERNEL); + fsm->event_count, GFP_KERNEL); for (i = 0; i < fncount; i++) if ((fnlist[i].state >= fsm->state_count) || (fnlist[i].event >= fsm->event_count)) { printk(KERN_ERR - "mISDN_FsmNew Error: %d st(%ld/%ld) ev(%ld/%ld)\n", - i, (long)fnlist[i].state, (long)fsm->state_count, - (long)fnlist[i].event, (long)fsm->event_count); + "mISDN_FsmNew Error: %d st(%ld/%ld) ev(%ld/%ld)\n", + i, (long)fnlist[i].state, (long)fsm->state_count, + (long)fnlist[i].event, (long)fsm->event_count); } else fsm->jumpmatrix[fsm->state_count * fnlist[i].event + - fnlist[i].state] = (FSMFNPTR) fnlist[i].routine; + fnlist[i].state] = (FSMFNPTR) fnlist[i].routine; } EXPORT_SYMBOL(mISDN_FsmNew); @@ -63,24 +63,24 @@ mISDN_FsmEvent(struct FsmInst *fi, int event, void *arg) if ((fi->state >= fi->fsm->state_count) || (event >= fi->fsm->event_count)) { printk(KERN_ERR - "mISDN_FsmEvent Error st(%ld/%ld) ev(%d/%ld)\n", - (long)fi->state, (long)fi->fsm->state_count, event, - (long)fi->fsm->event_count); + "mISDN_FsmEvent Error st(%ld/%ld) ev(%d/%ld)\n", + (long)fi->state, (long)fi->fsm->state_count, event, + (long)fi->fsm->event_count); return 1; } r = fi->fsm->jumpmatrix[fi->fsm->state_count * event + fi->state]; if (r) { if (fi->debug) fi->printdebug(fi, "State %s Event %s", - fi->fsm->strState[fi->state], - fi->fsm->strEvent[event]); + fi->fsm->strState[fi->state], + fi->fsm->strEvent[event]); r(fi, event, arg); return 0; } else { if (fi->debug) fi->printdebug(fi, "State %s Event %s no action", - fi->fsm->strState[fi->state], - fi->fsm->strEvent[event]); + fi->fsm->strState[fi->state], + fi->fsm->strEvent[event]); return 1; } } @@ -92,7 +92,7 @@ mISDN_FsmChangeState(struct FsmInst *fi, int newstate) fi->state = newstate; if (fi->debug) fi->printdebug(fi, "ChangeState %s", - fi->fsm->strState[newstate]); + fi->fsm->strState[newstate]); } EXPORT_SYMBOL(mISDN_FsmChangeState); @@ -126,7 +126,7 @@ mISDN_FsmDelTimer(struct FsmTimer *ft, int where) #if FSM_TIMER_DEBUG if (ft->fi->debug) ft->fi->printdebug(ft->fi, "mISDN_FsmDelTimer %lx %d", - (long) ft, where); + (long) ft, where); #endif del_timer(&ft->tl); } @@ -134,21 +134,21 @@ EXPORT_SYMBOL(mISDN_FsmDelTimer); int mISDN_FsmAddTimer(struct FsmTimer *ft, - int millisec, int event, void *arg, int where) + int millisec, int event, void *arg, int where) { #if FSM_TIMER_DEBUG if (ft->fi->debug) ft->fi->printdebug(ft->fi, "mISDN_FsmAddTimer %lx %d %d", - (long) ft, millisec, where); + (long) ft, millisec, where); #endif if (timer_pending(&ft->tl)) { if (ft->fi->debug) { printk(KERN_WARNING - "mISDN_FsmAddTimer: timer already active!\n"); + "mISDN_FsmAddTimer: timer already active!\n"); ft->fi->printdebug(ft->fi, - "mISDN_FsmAddTimer already active!"); + "mISDN_FsmAddTimer already active!"); } return -1; } @@ -163,13 +163,13 @@ EXPORT_SYMBOL(mISDN_FsmAddTimer); void mISDN_FsmRestartTimer(struct FsmTimer *ft, - int millisec, int event, void *arg, int where) + int millisec, int event, void *arg, int where) { #if FSM_TIMER_DEBUG if (ft->fi->debug) ft->fi->printdebug(ft->fi, "mISDN_FsmRestartTimer %lx %d %d", - (long) ft, millisec, where); + (long) ft, millisec, where); #endif if (timer_pending(&ft->tl)) |