Lines Matching refs:softsp

121 ssm_fm_init(struct ssm_soft_state *softsp);
124 ssm_fm_fini(struct ssm_soft_state *softsp);
337 struct ssm_soft_state *softsp; in ssm_attach() local
358 softsp = ddi_get_soft_state(ssm_softstates, instance); in ssm_attach()
361 softsp->dip = devi; in ssm_attach()
362 softsp->top_node = devi; in ssm_attach()
363 mutex_init(&softsp->ssm_sft_lock, NULL, MUTEX_DRIVER, NULL); in ssm_attach()
366 instance, (void *)devi, (void *)softsp)); in ssm_attach()
368 if ((softsp->ssm_nodeid = (int)ddi_getprop(DDI_DEV_T_ANY, softsp->dip, in ssm_attach()
389 if (ssm_make_nodes(devi, instance, softsp->ssm_nodeid)) { in ssm_attach()
396 ssm_fm_init(softsp); in ssm_attach()
427 ASSERT(sp->nodeid != softsp->ssm_nodeid); in ssm_attach()
440 sp->nodeid = softsp->ssm_nodeid; in ssm_attach()
460 struct ssm_soft_state *softsp; in ssm_detach() local
464 softsp = ddi_get_soft_state(ssm_softstates, instance); in ssm_detach()
466 if (softsp == NULL) { in ssm_detach()
487 sbdp_info.wnode = softsp->ssm_nodeid; in ssm_detach()
494 ssm_fm_fini(softsp); in ssm_detach()
495 mutex_destroy(&softsp->ssm_sft_lock); in ssm_detach()
708 struct ssm_soft_state *softsp; in ssm_open() local
716 softsp = ddi_get_soft_state(ssm_softstates, instance); in ssm_open()
717 if (softsp == NULL) { in ssm_open()
740 mutex_enter(&softsp->ssm_sft_lock); in ssm_open()
741 if (softsp->initialized == FALSE) { in ssm_open()
743 if (softsp->top_node == NULL) { in ssm_open()
745 mutex_exit(&softsp->ssm_sft_lock); in ssm_open()
754 mutex_exit(&softsp->ssm_sft_lock); in ssm_open()
759 sbdp_info.wnode = softsp->ssm_nodeid; in ssm_open()
761 rv = (*sbd_setup_instance)(instance, softsp->top_node, in ssm_open()
762 plat_max_boards(), softsp->ssm_nodeid, in ssm_open()
766 mutex_exit(&softsp->ssm_sft_lock); in ssm_open()
769 softsp->initialized = TRUE; in ssm_open()
771 mutex_exit(&softsp->ssm_sft_lock); in ssm_open()
781 struct ssm_soft_state *softsp; in ssm_close() local
786 softsp = ddi_get_soft_state(ssm_softstates, instance); in ssm_close()
787 if (softsp == NULL) in ssm_close()
803 struct ssm_soft_state *softsp; in ssm_ioctl() local
810 softsp = ddi_get_soft_state(ssm_softstates, instance); in ssm_ioctl()
811 if (softsp == NULL) in ssm_ioctl()
852 sbdp_info.wnode = softsp->ssm_nodeid; in ssm_ioctl()
860 softsp->initialized = FALSE; in ssm_ioctl()
894 (void) ssm_generate_event(softsp->ssm_nodeid, slot, in ssm_ioctl()
1056 ssm_fm_init(struct ssm_soft_state *softsp) in ssm_fm_init() argument
1058 softsp->ssm_fm_cap = DDI_FM_EREPORT_CAPABLE | DDI_FM_ERRCB_CAPABLE | in ssm_fm_init()
1065 ddi_fm_init(softsp->dip, &softsp->ssm_fm_cap, &softsp->ssm_fm_ibc); in ssm_fm_init()
1066 ASSERT((softsp->ssm_fm_cap & DDI_FM_EREPORT_CAPABLE) && in ssm_fm_init()
1067 (softsp->ssm_fm_cap & DDI_FM_ERRCB_CAPABLE)); in ssm_fm_init()
1071 ddi_fm_handler_register(softsp->dip, ssm_err_callback, NULL); in ssm_fm_init()
1078 ssm_fm_fini(struct ssm_soft_state *softsp) in ssm_fm_fini() argument
1083 ASSERT(softsp->ssm_fm_cap & DDI_FM_EREPORT_CAPABLE); in ssm_fm_fini()
1084 ddi_fm_handler_unregister(softsp->dip); in ssm_fm_fini()
1085 ddi_fm_fini(softsp->dip); in ssm_fm_fini()
1097 struct ssm_soft_state *softsp = ddi_get_soft_state(ssm_softstates, in ssm_fm_init_child() local
1100 *ibc = softsp->ssm_fm_ibc; in ssm_fm_init_child()
1101 return (softsp->ssm_fm_cap); in ssm_fm_init_child()