Lines Matching refs:ldcssp

129 extern void i_ldc_init_mapin(ldc_soft_state_t *ldcssp, uint64_t major,
143 ldc_soft_state_t *ldcssp;
406 ldcssp = kmem_zalloc(sizeof (ldc_soft_state_t), KM_SLEEP);
408 i_ldc_init_mapin(ldcssp, ldc_hsvc.hsvc_major, ldc_sup_minor);
413 kmem_free(ldcssp, sizeof (ldc_soft_state_t));
418 mutex_init(&ldcssp->lock, NULL, MUTEX_DRIVER, NULL);
420 mutex_enter(&ldcssp->lock);
423 ldcssp->memhdl_cache = kmem_cache_create("ldc_memhdl_cache",
425 if (ldcssp->memhdl_cache == NULL) {
427 mutex_exit(&ldcssp->lock);
432 ldcssp->memseg_cache = kmem_cache_create("ldc_memseg_cache",
434 if (ldcssp->memseg_cache == NULL) {
436 mutex_exit(&ldcssp->lock);
441 ldcssp->channel_count = 0;
442 ldcssp->channels_open = 0;
443 ldcssp->chan_list = NULL;
444 ldcssp->dring_list = NULL;
449 mutex_exit(&ldcssp->lock);
480 dringp = ldcssp->dring_list;
499 ldcssp->dring_list = NULL;
502 ldcp = ldcssp->chan_list;
511 ldcssp->chan_list = NULL;
514 kmem_cache_destroy(ldcssp->memhdl_cache);
515 kmem_cache_destroy(ldcssp->memseg_cache);
521 mutex_destroy(&ldcssp->lock);
522 kmem_free(ldcssp, sizeof (ldc_soft_state_t));
759 ldcp = ldcssp->chan_list;
776 ldc_cnex_t *cinfo = &ldcssp->cinfo;
1988 ldc_cnex_t *cinfo = &ldcssp->cinfo;
2034 ldc_cnex_t *cinfo = &ldcssp->cinfo;
2081 rv = cinfo->unreg_chan(ldcssp->cinfo.dip, ldcp->id);
2607 mutex_enter(&ldcssp->lock);
2608 ldcp = ldcssp->chan_list;
2613 mutex_exit(&ldcssp->lock);
2618 mutex_exit(&ldcssp->lock);
2805 mutex_enter(&ldcssp->lock);
2806 ldcp->next = ldcssp->chan_list;
2807 ldcssp->chan_list = ldcp;
2808 ldcssp->channel_count++;
2809 mutex_exit(&ldcssp->lock);
2870 mutex_enter(&ldcssp->lock);
2871 tmp_ldcp = ldcssp->chan_list;
2873 ldcssp->chan_list = ldcp->next;
2886 mutex_exit(&ldcssp->lock);
2892 ldcssp->channel_count--;
2894 mutex_exit(&ldcssp->lock);
3085 mutex_enter(&ldcssp->lock);
3086 ldcssp->channels_open++;
3087 mutex_exit(&ldcssp->lock);
3265 mutex_enter(&ldcssp->lock);
3266 ldcssp->channels_open--;
3267 mutex_exit(&ldcssp->lock);
4678 mutex_enter(&ldcssp->lock);
4681 ldcssp->cinfo.dip = cinfo->dip;
4682 ldcssp->cinfo.reg_chan = cinfo->reg_chan;
4683 ldcssp->cinfo.unreg_chan = cinfo->unreg_chan;
4684 ldcssp->cinfo.add_intr = cinfo->add_intr;
4685 ldcssp->cinfo.rem_intr = cinfo->rem_intr;
4686 ldcssp->cinfo.clr_intr = cinfo->clr_intr;
4689 ldcp = ldcssp->chan_list;
4698 mutex_exit(&ldcssp->lock);
4711 mutex_enter(&ldcssp->lock);
4713 if (cinfo->dip != ldcssp->cinfo.dip) {
4715 mutex_exit(&ldcssp->lock);
4720 ldcssp->cinfo.dip = NULL;
4721 ldcssp->cinfo.reg_chan = NULL;
4722 ldcssp->cinfo.unreg_chan = NULL;
4723 ldcssp->cinfo.add_intr = NULL;
4724 ldcssp->cinfo.rem_intr = NULL;
4725 ldcssp->cinfo.clr_intr = NULL;
4727 mutex_exit(&ldcssp->lock);
4759 * ldcssp->mapin_size is the max amount of shared memory supported by
4769 if (ldcssp->mapin_size <= ldc_dring_direct_map_rsvd) {
4774 avail = ldcssp->mapin_size - ldc_dring_direct_map_rsvd;