Lines Matching refs:cp_inst
267 struct coproc_instance *cp_inst; in coproc_open() local
269 cp_inst = kzalloc(sizeof(*cp_inst), GFP_KERNEL); in coproc_open()
270 if (!cp_inst) in coproc_open()
273 cp_inst->coproc = container_of(inode->i_cdev, struct coproc_dev, in coproc_open()
275 fp->private_data = cp_inst; in coproc_open()
284 struct coproc_instance *cp_inst; in coproc_ioc_tx_win_open() local
288 cp_inst = fp->private_data; in coproc_ioc_tx_win_open()
293 if (cp_inst->txwin) in coproc_ioc_tx_win_open()
307 if (!cp_inst->coproc->vops || !cp_inst->coproc->vops->open_win) { in coproc_ioc_tx_win_open()
312 txwin = cp_inst->coproc->vops->open_win(uattr.vas_id, uattr.flags, in coproc_ioc_tx_win_open()
313 cp_inst->coproc->cop_type); in coproc_ioc_tx_win_open()
321 cp_inst->txwin = txwin; in coproc_ioc_tx_win_open()
328 struct coproc_instance *cp_inst = fp->private_data; in coproc_release() local
331 if (cp_inst->txwin) { in coproc_release()
332 if (cp_inst->coproc->vops && in coproc_release()
333 cp_inst->coproc->vops->close_win) { in coproc_release()
334 rc = cp_inst->coproc->vops->close_win(cp_inst->txwin); in coproc_release()
338 cp_inst->txwin = NULL; in coproc_release()
341 kfree(cp_inst); in coproc_release()
399 struct coproc_instance *cp_inst = fp->private_data; in vas_mmap_fault() local
408 if (!cp_inst || !cp_inst->txwin) { in vas_mmap_fault()
413 txwin = cp_inst->txwin; in vas_mmap_fault()
436 paste_addr = cp_inst->coproc->vops->paste_addr(txwin); in vas_mmap_fault()
473 struct coproc_instance *cp_inst = fp->private_data; in coproc_mmap() local
480 txwin = cp_inst->txwin; in coproc_mmap()
494 if (!cp_inst->coproc->vops || !cp_inst->coproc->vops->paste_addr) { in coproc_mmap()
517 paste_addr = cp_inst->coproc->vops->paste_addr(txwin); in coproc_mmap()