Lines Matching refs:adp

108 	mraid_mmadp_t	*adp;  in mraid_mm_ioctl()  local
154 if ((adp = mraid_mm_get_adapter(argp, &rval)) == NULL) { in mraid_mm_ioctl()
162 if (!adp->quiescent) { in mraid_mm_ioctl()
174 kioc = mraid_mm_alloc_kioc(adp); in mraid_mm_ioctl()
181 if ((rval = mimd_to_kioc(argp, adp, kioc))) { in mraid_mm_ioctl()
182 mraid_mm_dealloc_kioc(adp, kioc); in mraid_mm_ioctl()
193 if ((rval = lld_ioctl(adp, kioc))) { in mraid_mm_ioctl()
196 mraid_mm_dealloc_kioc(adp, kioc); in mraid_mm_ioctl()
209 mraid_mm_dealloc_kioc(adp, kioc); in mraid_mm_ioctl()
354 mimd_to_kioc(mimd_t __user *umimd, mraid_mmadp_t *adp, uioc_t *kioc) in mimd_to_kioc() argument
395 if (mraid_mm_attach_buf(adp, kioc, kioc->xferlen)) in mimd_to_kioc()
413 if (mraid_mm_attach_buf(adp, kioc, kioc->xferlen)) in mimd_to_kioc()
429 if (mraid_mm_attach_buf(adp, kioc, kioc->xferlen)) in mimd_to_kioc()
508 mraid_mm_attach_buf(mraid_mmadp_t *adp, uioc_t *kioc, int xferlen) in mraid_mm_attach_buf() argument
527 pool = &adp->dma_pool_list[i]; in mraid_mm_attach_buf()
563 pool = &adp->dma_pool_list[right_pool]; in mraid_mm_attach_buf()
588 mraid_mm_alloc_kioc(mraid_mmadp_t *adp) in mraid_mm_alloc_kioc() argument
594 down(&adp->kioc_semaphore); in mraid_mm_alloc_kioc()
596 spin_lock_irqsave(&adp->kioc_pool_lock, flags); in mraid_mm_alloc_kioc()
598 head = &adp->kioc_pool; in mraid_mm_alloc_kioc()
601 up(&adp->kioc_semaphore); in mraid_mm_alloc_kioc()
602 spin_unlock_irqrestore(&adp->kioc_pool_lock, flags); in mraid_mm_alloc_kioc()
611 spin_unlock_irqrestore(&adp->kioc_pool_lock, flags); in mraid_mm_alloc_kioc()
634 mraid_mm_dealloc_kioc(mraid_mmadp_t *adp, uioc_t *kioc) in mraid_mm_dealloc_kioc() argument
640 pool = &adp->dma_pool_list[kioc->pool_index]; in mraid_mm_dealloc_kioc()
662 spin_lock_irqsave(&adp->kioc_pool_lock, flags); in mraid_mm_dealloc_kioc()
663 list_add(&kioc->list, &adp->kioc_pool); in mraid_mm_dealloc_kioc()
664 spin_unlock_irqrestore(&adp->kioc_pool_lock, flags); in mraid_mm_dealloc_kioc()
667 up(&adp->kioc_semaphore); in mraid_mm_dealloc_kioc()
678 lld_ioctl(mraid_mmadp_t *adp, uioc_t *kioc) in lld_ioctl() argument
684 rval = adp->issue_uioc(adp->drvr_data, kioc, IOCTL_ISSUE); in lld_ioctl()
691 if (adp->timeout > 0) { in lld_ioctl()
695 timeout.timer.expires = jiffies + adp->timeout * HZ; in lld_ioctl()
715 adp->quiescent = 0; in lld_ioctl()
1068 mraid_mm_setup_dma_pools(mraid_mmadp_t *adp) in mraid_mm_setup_dma_pools() argument
1081 pool = &adp->dma_pool_list[i]; in mraid_mm_setup_dma_pools()
1087 &adp->pdev->dev, bufsize, in mraid_mm_setup_dma_pools()
1107 mraid_mm_teardown_dma_pools(adp); in mraid_mm_setup_dma_pools()
1153 mraid_mm_free_adp_resources(mraid_mmadp_t *adp) in mraid_mm_free_adp_resources() argument
1158 mraid_mm_teardown_dma_pools(adp); in mraid_mm_free_adp_resources()
1160 for (i = 0; i < adp->max_kioc; i++) { in mraid_mm_free_adp_resources()
1162 kioc = adp->kioc_list + i; in mraid_mm_free_adp_resources()
1164 dma_pool_free(adp->pthru_dma_pool, kioc->pthru32, in mraid_mm_free_adp_resources()
1168 kfree(adp->kioc_list); in mraid_mm_free_adp_resources()
1169 kfree(adp->mbox_list); in mraid_mm_free_adp_resources()
1171 dma_pool_destroy(adp->pthru_dma_pool); in mraid_mm_free_adp_resources()
1183 mraid_mm_teardown_dma_pools(mraid_mmadp_t *adp) in mraid_mm_teardown_dma_pools() argument
1190 pool = &adp->dma_pool_list[i]; in mraid_mm_teardown_dma_pools()