/drivers/usb/common/ |
D | usb-otg-fsm.c | 35 static int otg_set_protocol(struct otg_fsm *fsm, int protocol) in otg_set_protocol() argument 39 if (fsm->protocol != protocol) { in otg_set_protocol() 41 fsm->protocol, protocol); in otg_set_protocol() 43 if (fsm->protocol == PROTO_HOST) in otg_set_protocol() 44 ret = otg_start_host(fsm, 0); in otg_set_protocol() 45 else if (fsm->protocol == PROTO_GADGET) in otg_set_protocol() 46 ret = otg_start_gadget(fsm, 0); in otg_set_protocol() 52 ret = otg_start_host(fsm, 1); in otg_set_protocol() 54 ret = otg_start_gadget(fsm, 1); in otg_set_protocol() 58 fsm->protocol = protocol; in otg_set_protocol() [all …]
|
/drivers/mtd/devices/ |
D | st_spi_fsm.c | 316 static int stfsm_n25q_config(struct stfsm *fsm); 317 static int stfsm_mx25_config(struct stfsm *fsm); 318 static int stfsm_s25fl_config(struct stfsm *fsm); 319 static int stfsm_w25q_config(struct stfsm *fsm); 707 static inline int stfsm_is_idle(struct stfsm *fsm) in stfsm_is_idle() argument 709 return readl(fsm->base + SPI_FAST_SEQ_STA) & 0x10; in stfsm_is_idle() 712 static inline uint32_t stfsm_fifo_available(struct stfsm *fsm) in stfsm_fifo_available() argument 714 return (readl(fsm->base + SPI_FAST_SEQ_STA) >> 5) & 0x7f; in stfsm_fifo_available() 717 static inline void stfsm_load_seq(struct stfsm *fsm, in stfsm_load_seq() argument 720 void __iomem *dst = fsm->base + SPI_FAST_SEQ_TRANSFER_SIZE; in stfsm_load_seq() [all …]
|
/drivers/usb/chipidea/ |
D | otg_fsm.c | 43 t = scnprintf(next, size, "%d\n", ci->fsm.a_bus_req); in get_a_bus_req() 59 mutex_lock(&ci->fsm.lock); in set_a_bus_req() 61 ci->fsm.a_bus_req = 0; in set_a_bus_req() 64 if (ci->fsm.a_bus_drop) { in set_a_bus_req() 65 mutex_unlock(&ci->fsm.lock); in set_a_bus_req() 68 ci->fsm.a_bus_req = 1; in set_a_bus_req() 69 if (ci->fsm.otg->state == OTG_STATE_A_PERIPHERAL) { in set_a_bus_req() 71 mutex_unlock(&ci->fsm.lock); in set_a_bus_req() 77 mutex_unlock(&ci->fsm.lock); in set_a_bus_req() 92 t = scnprintf(next, size, "%d\n", ci->fsm.a_bus_drop); in get_a_bus_drop() [all …]
|
D | debug.c | 222 struct otg_fsm *fsm; in ci_otg_show() local 227 fsm = &ci->fsm; in ci_otg_show() 234 seq_printf(s, "a_bus_drop: %d\n", fsm->a_bus_drop); in ci_otg_show() 236 seq_printf(s, "a_bus_req: %d\n", fsm->a_bus_req); in ci_otg_show() 238 seq_printf(s, "a_srp_det: %d\n", fsm->a_srp_det); in ci_otg_show() 240 seq_printf(s, "a_vbus_vld: %d\n", fsm->a_vbus_vld); in ci_otg_show() 242 seq_printf(s, "b_conn: %d\n", fsm->b_conn); in ci_otg_show() 244 seq_printf(s, "adp_change: %d\n", fsm->adp_change); in ci_otg_show() 246 seq_printf(s, "power_up: %d\n", fsm->power_up); in ci_otg_show() 248 seq_printf(s, "a_bus_resume: %d\n", fsm->a_bus_resume); in ci_otg_show() [all …]
|
/drivers/usb/phy/ |
D | phy-fsl-usb.c | 123 void fsl_otg_chrg_vbus(struct otg_fsm *fsm, int on) in fsl_otg_chrg_vbus() argument 159 void fsl_otg_drv_vbus(struct otg_fsm *fsm, int on) in fsl_otg_drv_vbus() argument 177 void fsl_otg_loc_conn(struct otg_fsm *fsm, int on) in fsl_otg_loc_conn() argument 196 void fsl_otg_loc_sof(struct otg_fsm *fsm, int on) in fsl_otg_loc_sof() argument 211 void fsl_otg_start_pulse(struct otg_fsm *fsm) in fsl_otg_start_pulse() argument 224 fsl_otg_add_timer(fsm, b_data_pulse_tmr); in fsl_otg_start_pulse() 241 fsl_otg_chrg_vbus(&fsl_otg_dev->fsm, 1); in fsl_otg_pulse_vbus() 243 fsl_otg_add_timer(&fsl_otg_dev->fsm, b_vbus_pulse_tmr); in fsl_otg_pulse_vbus() 248 fsl_otg_chrg_vbus(&fsl_otg_dev->fsm, 0); in b_vbus_pulse_end() 256 fsl_otg_add_timer(&fsl_otg_dev->fsm, b_srp_wait_tmr); in b_vbus_pulse_end() [all …]
|
D | phy-fsl-usb.h | 373 struct otg_fsm fsm; member 404 void fsl_otg_add_timer(struct otg_fsm *fsm, void *timer); 405 void fsl_otg_del_timer(struct otg_fsm *fsm, void *timer);
|
/drivers/isdn/hisax/ |
D | fsm.c | 25 FsmNew(struct Fsm *fsm, struct FsmNode *fnlist, int fncount) in FsmNew() argument 29 fsm->jumpmatrix = in FsmNew() 30 kzalloc(sizeof(FSMFNPTR) * fsm->state_count * fsm->event_count, GFP_KERNEL); in FsmNew() 31 if (!fsm->jumpmatrix) in FsmNew() 35 if ((fnlist[i].state >= fsm->state_count) || (fnlist[i].event >= fsm->event_count)) { in FsmNew() 37 i, (long)fnlist[i].state, (long)fsm->state_count, in FsmNew() 38 (long)fnlist[i].event, (long)fsm->event_count); in FsmNew() 40 fsm->jumpmatrix[fsm->state_count * fnlist[i].event + in FsmNew() 46 FsmFree(struct Fsm *fsm) in FsmFree() argument 48 kfree((void *) fsm->jumpmatrix); in FsmFree() [all …]
|
D | st5481_d.c | 289 FsmEvent(&adapter->d_out.fsm, EV_DOUT_STOPPED, NULL); in dout_stop_event() 304 if (d_out->fsm.state != ST_DOUT_NORMAL) in usb_d_out() 330 FsmChangeState(&d_out->fsm, ST_DOUT_WAIT_FOR_UNDERRUN); in usb_d_out() 372 FsmEvent(&adapter->d_out.fsm, EV_DOUT_RESETED, NULL); in fifo_reseted() 403 FsmEvent(&adapter->d_out.fsm, EV_DOUT_COMPLETE, (void *) buf_nr); in usb_d_out_complete() 408 static void dout_start_xmit(struct FsmInst *fsm, int event, void *arg) in dout_start_xmit() argument 411 struct st5481_adapter *adapter = fsm->userdata; in dout_start_xmit() 437 FsmChangeState(&d_out->fsm, ST_DOUT_SHORT_INIT); in dout_start_xmit() 439 FsmChangeState(&d_out->fsm, ST_DOUT_LONG_INIT); in dout_start_xmit() 462 static void dout_short_fifo(struct FsmInst *fsm, int event, void *arg) in dout_short_fifo() argument [all …]
|
D | fsm.h | 30 struct Fsm *fsm; member 50 int FsmNew(struct Fsm *fsm, struct FsmNode *fnlist, int fncount); 51 void FsmFree(struct Fsm *fsm);
|
/drivers/isdn/mISDN/ |
D | fsm.c | 30 mISDN_FsmNew(struct Fsm *fsm, in mISDN_FsmNew() argument 35 fsm->jumpmatrix = kzalloc(sizeof(FSMFNPTR) * fsm->state_count * in mISDN_FsmNew() 36 fsm->event_count, GFP_KERNEL); in mISDN_FsmNew() 39 if ((fnlist[i].state >= fsm->state_count) || in mISDN_FsmNew() 40 (fnlist[i].event >= fsm->event_count)) { in mISDN_FsmNew() 43 i, (long)fnlist[i].state, (long)fsm->state_count, in mISDN_FsmNew() 44 (long)fnlist[i].event, (long)fsm->event_count); in mISDN_FsmNew() 46 fsm->jumpmatrix[fsm->state_count * fnlist[i].event + in mISDN_FsmNew() 52 mISDN_FsmFree(struct Fsm *fsm) in mISDN_FsmFree() argument 54 kfree((void *) fsm->jumpmatrix); in mISDN_FsmFree() [all …]
|
/drivers/net/irda/ |
D | sir_dev.c | 38 struct sir_fsm *fsm = &dev->fsm; in sirdev_tx_complete_fsm() local 43 next_state = fsm->substate; /* default: stay in current substate */ in sirdev_tx_complete_fsm() 46 switch(fsm->substate) { in sirdev_tx_complete_fsm() 88 fsm->substate = next_state; in sirdev_tx_complete_fsm() 106 struct sir_dev *dev = container_of(work, struct sir_dev, fsm.work.work); in sirdev_config_fsm() 107 struct sir_fsm *fsm = &dev->fsm; in sirdev_config_fsm() local 116 __func__, fsm->state, fsm->substate); in sirdev_config_fsm() 118 next_state = fsm->state; in sirdev_config_fsm() 121 switch(fsm->state) { in sirdev_config_fsm() 127 fsm->result = -EINVAL; in sirdev_config_fsm() [all …]
|
D | mcp2120-sir.c | 96 unsigned state = dev->fsm.substate; in mcp2120_change_speed() 157 dev->fsm.substate = state; in mcp2120_change_speed() 181 unsigned state = dev->fsm.substate; in mcp2120_reset() 214 dev->fsm.substate = state; in mcp2120_reset()
|
D | girbil-sir.c | 120 unsigned state = dev->fsm.substate; in girbil_change_speed() 181 dev->fsm.substate = state; in girbil_change_speed() 202 unsigned state = dev->fsm.substate; in girbil_reset() 242 dev->fsm.substate = state; in girbil_reset()
|
D | toim3232-sir.c | 226 unsigned state = dev->fsm.substate; in toim3232_change_speed() 292 dev->fsm.substate = state; in toim3232_change_speed()
|
D | tekram-sir.c | 124 unsigned state = dev->fsm.substate; in tekram_change_speed() 182 dev->fsm.substate = state; in tekram_change_speed()
|
/drivers/s390/net/ |
D | ctcm_mpc.c | 111 static void mpc_action_nop(fsm_instance *fsm, int event, void *arg); 112 static void mpc_action_go_ready(fsm_instance *fsm, int event, void *arg); 116 static void mpc_action_yside_xid(fsm_instance *fsm, int event, void *arg); 117 static void mpc_action_doxid0(fsm_instance *fsm, int event, void *arg); 118 static void mpc_action_doxid7(fsm_instance *fsm, int event, void *arg); 119 static void mpc_action_xside_xid(fsm_instance *fsm, int event, void *arg); 120 static void mpc_action_rcvd_xid0(fsm_instance *fsm, int event, void *arg); 121 static void mpc_action_rcvd_xid7(fsm_instance *fsm, int event, void *arg); 344 CTCM_FUNTAIL, dev->name, fsm_getstate_str(grp->fsm)); in ctc_mpc_alloc_channel() 346 switch (fsm_getstate(grp->fsm)) { in ctc_mpc_alloc_channel() [all …]
|
D | ctcm_main.c | 191 fsm_newstate(ch->fsm, CTC_STATE_IDLE); in channel_free() 218 kfree_fsm(ch->fsm); in channel_remove() 270 fsm_newstate(ch->fsm, CTC_STATE_STOPPED); in channel_get() 322 fsm_event(ch->fsm, CTC_EVENT_UC_RCRESET, ch); in ccw_unit_check() 330 fsm_event(ch->fsm, CTC_EVENT_UC_RSRESET, ch); in ccw_unit_check() 340 fsm_event(ch->fsm, CTC_EVENT_UC_HWFAIL, ch); in ccw_unit_check() 348 fsm_event(ch->fsm, CTC_EVENT_UC_RXPARITY, ch); in ccw_unit_check() 358 fsm_event(ch->fsm, CTC_EVENT_UC_TXTIMEOUT, ch); in ccw_unit_check() 360 fsm_event(ch->fsm, CTC_EVENT_UC_TXPARITY, ch); in ccw_unit_check() 372 fsm_event(ch->fsm, CTC_EVENT_UC_ZERO, ch); in ccw_unit_check() [all …]
|
D | ctcm_fsms.c | 179 static void ctcmpc_chx_attn(fsm_instance *fsm, int event, void *arg); 182 static void ctcmpc_chx_send_sweep(fsm_instance *fsm, int event, void *arg); 199 fsm_event(ch->fsm, CTC_EVENT_IO_EBUSY, ch); in ctcm_ccw_check_rc() 204 fsm_event(ch->fsm, CTC_EVENT_IO_ENODEV, ch); in ctcm_ccw_check_rc() 209 fsm_event(ch->fsm, CTC_EVENT_IO_UNKNOWN, ch); in ctcm_ccw_check_rc() 344 fsm_event(priv->fsm, DEV_EVENT_TXUP, ch->netdev); in ctcm_chx_txidle() 462 fsm_event(priv->fsm, DEV_EVENT_TXUP, dev); in chx_firstio() 498 fsm_event(priv->fsm, DEV_EVENT_RXUP, dev); in chx_firstio() 535 fsm_event(priv->fsm, DEV_EVENT_RXUP, dev); in chx_rxidle() 722 fsm_event(priv->fsm, DEV_EVENT_RXDOWN, dev); in ctcm_chx_cleanup() [all …]
|
D | netiucv.c | 199 fsm_instance *fsm; member 227 fsm_instance *fsm; member 537 fsm_event(conn->fsm, CONN_EVENT_RX, &ev); in netiucv_callback_rx() 548 fsm_event(conn->fsm, CONN_EVENT_TXDONE, &ev); in netiucv_callback_txdone() 555 fsm_event(conn->fsm, CONN_EVENT_CONN_ACK, conn); in netiucv_callback_connack() 580 fsm_event(conn->fsm, CONN_EVENT_CONN_REQ, &ev); in netiucv_callback_connreq() 593 fsm_event(conn->fsm, CONN_EVENT_CONN_REJ, conn); in netiucv_callback_connrej() 600 fsm_event(conn->fsm, CONN_EVENT_CONN_SUS, conn); in netiucv_callback_connsusp() 607 fsm_event(conn->fsm, CONN_EVENT_CONN_RES, conn); in netiucv_callback_connres() 832 fsm_event(privptr->fsm, DEV_EVENT_CONUP, netdev); in conn_action_connaccept() [all …]
|
D | Makefile | 6 obj-$(CONFIG_CTCM) += ctcm.o fsm.o 7 obj-$(CONFIG_NETIUCV) += netiucv.o fsm.o
|
D | ctcm_sysfs.c | 88 fsm_getstate_str(priv->fsm)); in ctcm_print_statistics() 90 fsm_getstate_str(priv->channel[CTCM_READ]->fsm)); in ctcm_print_statistics() 92 fsm_getstate_str(priv->channel[CTCM_WRITE]->fsm)); in ctcm_print_statistics()
|
/drivers/net/ethernet/brocade/bna/ |
D | bfa_cs.h | 40 typedef void (*bfa_fsm_t)(void *fsm, int event); 48 static void oc ## _sm_ ## st(otype * fsm, etype event); \ 49 static void oc ## _sm_ ## st ## _entry(otype * fsm) 52 (_fsm)->fsm = (bfa_fsm_t)(_state); \ 56 #define bfa_fsm_send_event(_fsm, _event) ((_fsm)->fsm((_fsm), (_event))) 58 ((_fsm)->fsm == (bfa_fsm_t)(_state))
|
D | bna_types.h | 324 bfa_fsm_t fsm; member 346 bfa_fsm_t fsm; member 372 bfa_fsm_t fsm; member 471 bfa_fsm_t fsm; member 710 bfa_fsm_t fsm; member 786 bfa_fsm_t fsm; member
|
D | bfa_msgq.h | 67 bfa_fsm_t fsm; member 93 bfa_fsm_t fsm; member
|
/drivers/scsi/bfa/ |
D | bfa_cs.h | 196 static void oc ## _sm_ ## st(otype * fsm, etype event) 216 typedef void (*bfa_fsm_t)(void *fsm, int event); 225 static void oc ## _sm_ ## st(otype * fsm, etype event); \ 226 static void oc ## _sm_ ## st ## _entry(otype * fsm) 229 (_fsm)->fsm = (bfa_fsm_t)(_state); \ 233 #define bfa_fsm_send_event(_fsm, _event) ((_fsm)->fsm((_fsm), (_event))) 234 #define bfa_fsm_get_state(_fsm) ((_fsm)->fsm) 236 ((_fsm)->fsm == (bfa_fsm_t)(_state))
|