Lines Matching refs:cfctrl

17 #define container_obj(layr) container_of(layr, struct cfctrl, serv.layer)
22 static int handle_loop(struct cfctrl *ctrl, in handle_loop()
27 static int handle_loop(struct cfctrl *ctrl,
38 struct cfctrl *this = in cfctrl_create()
39 kzalloc(sizeof(struct cfctrl), GFP_ATOMIC); in cfctrl_create()
42 caif_assert(offsetof(struct cfctrl, serv.layer) == 0); in cfctrl_create()
63 struct cfctrl *ctrl = container_obj(layer); in cfctrl_remove()
129 static void cfctrl_insert_req(struct cfctrl *ctrl, in cfctrl_insert_req()
140 static struct cfctrl_request_info *cfctrl_remove_req(struct cfctrl *ctrl, in cfctrl_remove_req()
165 struct cfctrl *this = container_obj(layer); in cfctrl_get_respfuncs()
169 static void init_info(struct caif_payload_info *info, struct cfctrl *cfctrl) in init_info() argument
172 info->channel_id = cfctrl->serv.layer.id; in init_info()
173 info->dev_info = &cfctrl->serv.dev_info; in init_info()
179 struct cfctrl *cfctrl = container_obj(layer); in cfctrl_enum_req() local
180 struct cflayer *dn = cfctrl->serv.layer.dn; in cfctrl_enum_req()
189 caif_assert(offsetof(struct cfctrl, serv.layer) == 0); in cfctrl_enum_req()
190 init_info(cfpkt_info(pkt), cfctrl); in cfctrl_enum_req()
192 cfctrl->serv.dev_info.id = physlinkid; in cfctrl_enum_req()
203 struct cfctrl *cfctrl = container_obj(layer); in cfctrl_linkup_request() local
211 struct cflayer *dn = cfctrl->serv.layer.dn; in cfctrl_linkup_request()
284 cfctrl_insert_req(cfctrl, req); in cfctrl_linkup_request()
285 init_info(cfpkt_info(pkt), cfctrl); in cfctrl_linkup_request()
298 count = cfctrl_cancel_req(&cfctrl->serv.layer, in cfctrl_linkup_request()
313 struct cfctrl *cfctrl = container_obj(layer); in cfctrl_linkdown_req() local
314 struct cflayer *dn = cfctrl->serv.layer.dn; in cfctrl_linkdown_req()
325 init_info(cfpkt_info(pkt), cfctrl); in cfctrl_linkdown_req()
330 cfctrl->loop_linkused[channelid] = 0; in cfctrl_linkdown_req()
338 struct cfctrl *ctrl = container_obj(layr); in cfctrl_cancel_req()
362 struct cfctrl *cfctrl = container_obj(layer); in cfctrl_recv() local
371 if (handle_loop(cfctrl, cmd, pkt) != 0) in cfctrl_recv()
498 spin_lock_bh(&cfctrl->info_list_lock); in cfctrl_recv()
499 req = cfctrl_remove_req(cfctrl, &rsp); in cfctrl_recv()
505 cfctrl->res.reject_rsp(cfctrl->serv.layer.up, in cfctrl_recv()
510 cfctrl->res.linksetup_rsp(cfctrl->serv. in cfctrl_recv()
519 spin_unlock_bh(&cfctrl->info_list_lock); in cfctrl_recv()
524 cfctrl->res.linkdestroy_rsp(cfctrl->serv.layer.up, linkid); in cfctrl_recv()
528 cfctrl->res.linkerror_ind(); in cfctrl_recv()
531 cfctrl->res.enum_rsp(); in cfctrl_recv()
534 cfctrl->res.sleep_rsp(); in cfctrl_recv()
537 cfctrl->res.wake_rsp(); in cfctrl_recv()
540 cfctrl->res.restart_rsp(); in cfctrl_recv()
543 cfctrl->res.radioset_rsp(); in cfctrl_recv()
558 struct cfctrl *this = container_obj(layr); in cfctrl_ctrlcmd()
590 static int handle_loop(struct cfctrl *ctrl, int cmd, struct cfpkt *pkt) in handle_loop()