Lines Matching full:hdl
118 * irdma_find_handler - obtain hdl object to identify pf
124 struct irdma_handler *hdl; in irdma_find_handler() local
128 list_for_each_entry(hdl, &irdma_handlers, list) { in irdma_find_handler()
129 if (!hdl->iwdev->rf->peer_info) in irdma_find_handler()
131 if (hdl->iwdev->rf->peer_info->dev == p_dev->dev) { in irdma_find_handler()
133 return hdl; in irdma_find_handler()
148 struct irdma_handler *hdl; in peer_to_iwdev() local
150 hdl = irdma_find_handler(peer); in peer_to_iwdev()
151 if (!hdl) { in peer_to_iwdev()
156 return hdl->iwdev; in peer_to_iwdev()
562 struct irdma_handler *hdl; in irdma_probe() local
569 hdl = irdma_find_handler(peer); in irdma_probe()
570 if (hdl) in irdma_probe()
573 hdl = kzalloc(sizeof(*hdl), GFP_KERNEL); in irdma_probe()
574 if (!hdl) in irdma_probe()
579 kfree(hdl); in irdma_probe()
586 kfree(hdl); in irdma_probe()
589 hdl->iwdev = iwdev; in irdma_probe()
590 iwdev->hdl = hdl; in irdma_probe()
599 irdma_add_handler(hdl); in irdma_probe()
610 TASK_INIT(&hdl->deferred_task, 0, irdma_finalize_task, &rf->dev_ctx.task_arg); in irdma_probe()
611 hdl->deferred_tq = taskqueue_create_fast("irdma_defer", in irdma_probe()
613 &hdl->deferred_tq); in irdma_probe()
614 taskqueue_start_threads(&hdl->deferred_tq, 1, PI_NET, "irdma_defer_t"); in irdma_probe()
616 taskqueue_enqueue(hdl->deferred_tq, &hdl->deferred_task); in irdma_probe()
621 irdma_del_handler(hdl); in irdma_probe()
626 kfree(hdl); in irdma_probe()
641 struct irdma_handler *hdl; in irdma_remove() local
647 hdl = irdma_find_handler(peer); in irdma_remove()
648 if (!hdl) in irdma_remove()
651 iwdev = hdl->iwdev; in irdma_remove()
658 taskqueue_enqueue(hdl->deferred_tq, &hdl->deferred_task); in irdma_remove()
660 taskqueue_drain(hdl->deferred_tq, &hdl->deferred_task); in irdma_remove()
661 taskqueue_free(hdl->deferred_tq); in irdma_remove()
662 hdl->iwdev->rf->dev_ctx.task_arg.iwdev = NULL; in irdma_remove()
663 hdl->iwdev->rf->dev_ctx.task_arg.peer = NULL; in irdma_remove()
666 hdl->iwdev->rf->tun_info.irdma_sysctl_tree = NULL; in irdma_remove()
667 hdl->iwdev->rf->tun_info.sws_sysctl_tree = NULL; in irdma_remove()
673 irdma_del_handler(iwdev->hdl); in irdma_remove()
674 kfree(iwdev->hdl); in irdma_remove()
737 struct irdma_handler *hdl; in irdma_prep_for_unregister() local
744 list_for_each_entry(hdl, &irdma_handlers, list) { in irdma_prep_for_unregister()
745 if (!hdl->iwdev->rf->peer_info) in irdma_prep_for_unregister()
751 if (!hdl || !hdl_valid) in irdma_prep_for_unregister()
753 IRDMA_CLOSE(hdl->iwdev->rf->peer_info); in irdma_prep_for_unregister()
754 IRDMA_REMOVE(hdl->iwdev->rf->peer_info); in irdma_prep_for_unregister()