Lines Matching defs:daio_mgr
400 struct daio_mgr *mgr)
464 struct daio_mgr *mgr = dao->mgr;
476 struct daio_mgr *mgr)
535 static int get_daio_rsc(struct daio_mgr *mgr,
597 static int put_daio_rsc(struct daio_mgr *mgr, struct daio *daio)
619 static int daio_mgr_enb_daio(struct daio_mgr *mgr, struct daio *daio)
633 static int daio_mgr_dsb_daio(struct daio_mgr *mgr, struct daio *daio)
649 struct rsc_mgr *mgr = &((struct daio_mgr *)data)->mgr;
660 static int daio_imap_add(struct daio_mgr *mgr, struct imapper *entry)
677 static int daio_imap_delete(struct daio_mgr *mgr, struct imapper *entry)
694 static int daio_mgr_commit_write(struct daio_mgr *mgr)
702 int daio_mgr_create(void *hw, struct daio_mgr **rdaio_mgr)
705 struct daio_mgr *daio_mgr;
709 daio_mgr = kzalloc(sizeof(*daio_mgr), GFP_KERNEL);
710 if (!daio_mgr)
713 err = rsc_mgr_init(&daio_mgr->mgr, DAIO, DAIO_RESOURCE_NUM, hw);
717 spin_lock_init(&daio_mgr->mgr_lock);
718 spin_lock_init(&daio_mgr->imap_lock);
719 INIT_LIST_HEAD(&daio_mgr->imappers);
726 list_add(&entry->list, &daio_mgr->imappers);
727 daio_mgr->init_imap = entry;
728 daio_mgr->init_imap_added = 1;
730 daio_mgr->get_daio = get_daio_rsc;
731 daio_mgr->put_daio = put_daio_rsc;
732 daio_mgr->daio_enable = daio_mgr_enb_daio;
733 daio_mgr->daio_disable = daio_mgr_dsb_daio;
734 daio_mgr->imap_add = daio_imap_add;
735 daio_mgr->imap_delete = daio_imap_delete;
736 daio_mgr->commit_write = daio_mgr_commit_write;
739 ((struct hw *)hw)->daio_mgr_dsb_dao(daio_mgr->mgr.ctrl_blk, i);
740 ((struct hw *)hw)->daio_mgr_dsb_dai(daio_mgr->mgr.ctrl_blk, i);
742 ((struct hw *)hw)->daio_mgr_commit_write(hw, daio_mgr->mgr.ctrl_blk);
744 *rdaio_mgr = daio_mgr;
749 rsc_mgr_uninit(&daio_mgr->mgr);
751 kfree(daio_mgr);
755 int daio_mgr_destroy(struct daio_mgr *daio_mgr)
760 spin_lock_irqsave(&daio_mgr->imap_lock, flags);
761 free_input_mapper_list(&daio_mgr->imappers);
762 spin_unlock_irqrestore(&daio_mgr->imap_lock, flags);
764 rsc_mgr_uninit(&daio_mgr->mgr);
765 kfree(daio_mgr);