Lines Matching refs:suip

265 static	void	tonga_slotnum_check(scsb_state_t *scsb, scsb_uinfo_t *suip);
1607 scsb_uinfo_t *suip; in smf_ioctl() local
1613 suip = (scsb_uinfo_t *)mp->b_cont->b_rptr; in smf_ioctl()
1616 iocp->ioc_error = scsb_led_get(scsb, suip, OK); in smf_ioctl()
1619 iocp->ioc_error = scsb_led_get(scsb, suip, NOK); in smf_ioctl()
1622 iocp->ioc_error = scsb_led_set(scsb, suip, OK); in smf_ioctl()
1625 iocp->ioc_error = scsb_led_set(scsb, suip, NOK); in smf_ioctl()
1628 iocp->ioc_error = scsb_bhealthy_slot(scsb, suip); in smf_ioctl()
1631 iocp->ioc_error = scsb_slot_occupancy(scsb, suip); in smf_ioctl()
1634 iocp->ioc_error = scsb_reset_unit(scsb, suip); in smf_ioctl()
1637 if (suip->unit_type != DISK) { in smf_ioctl()
1641 iocp->ioc_error = scsb_led_get(scsb, suip, NOUSE); in smf_ioctl()
1644 if (suip->unit_type != DISK) { in smf_ioctl()
1648 iocp->ioc_error = scsb_led_set(scsb, suip, NOUSE); in smf_ioctl()
1655 iocp->ioc_error = scsb_led_set(scsb, suip, NOUSE); in smf_ioctl()
2114 scsb_uinfo_t *suip, in scsb_get_led_regnum() argument
2129 suip->unit_type, suip->unit_number, in scsb_get_led_regnum()
2130 led_type, suip->unit_state); in scsb_get_led_regnum()
2139 switch (suip->unit_type) { in scsb_get_led_regnum()
2141 if (suip->unit_number < 1 || suip->unit_number > in scsb_get_led_regnum()
2147 code = FRU_UNIT_TO_EVCODE(SLOT, suip->unit_number); in scsb_get_led_regnum()
2151 if (suip->unit_number < 1 || suip->unit_number > in scsb_get_led_regnum()
2157 "is out of range", suip->unit_number); in scsb_get_led_regnum()
2162 code = FRU_UNIT_TO_EVCODE(PDU, suip->unit_number); in scsb_get_led_regnum()
2166 if ((suip->unit_number < 1 || suip->unit_number > in scsb_get_led_regnum()
2172 "is out of range", suip->unit_number); in scsb_get_led_regnum()
2177 code = FRU_UNIT_TO_EVCODE(PS, suip->unit_number); in scsb_get_led_regnum()
2181 if ((suip->unit_number < 1 || suip->unit_number > in scsb_get_led_regnum()
2187 "is out of range", suip->unit_number); in scsb_get_led_regnum()
2194 code = FRU_UNIT_TO_EVCODE(DISK, suip->unit_number); in scsb_get_led_regnum()
2198 if (suip->unit_number < 1 || suip->unit_number > in scsb_get_led_regnum()
2204 "is out of range", suip->unit_number); in scsb_get_led_regnum()
2209 code = FRU_UNIT_TO_EVCODE(FAN, suip->unit_number); in scsb_get_led_regnum()
2213 if (suip->unit_number < 1 || suip->unit_number > in scsb_get_led_regnum()
2219 "is out of range", suip->unit_number); in scsb_get_led_regnum()
2224 code = FRU_UNIT_TO_EVCODE(CFTM, suip->unit_number); in scsb_get_led_regnum()
2228 if (suip->unit_number < 1 || suip->unit_number > in scsb_get_led_regnum()
2234 "is out of range", suip->unit_number); in scsb_get_led_regnum()
2239 code = FRU_UNIT_TO_EVCODE(SCB, suip->unit_number); in scsb_get_led_regnum()
2250 suip->unit_type); in scsb_get_led_regnum()
2331 tonga_slotnum_check(scsb_state_t *scsb, scsb_uinfo_t *suip) in tonga_slotnum_check() argument
2337 if (suip->unit_number < 1 || suip->unit_number > TG_MAX_SLOTS) { in tonga_slotnum_check()
2343 suip->unit_number, psl2ssl[suip->unit_number]); in tonga_slotnum_check()
2346 suip->unit_number = psl2ssl[suip->unit_number]; in tonga_slotnum_check()
2451 scsb_led_get(scsb_state_t *scsb, scsb_uinfo_t *suip, scsb_led_t led_type) in scsb_led_get() argument
2465 if (suip == NULL) { in scsb_led_get()
2469 led_type = suip->led_type; in scsb_led_get()
2479 led_name[led_type], unit_type_name[suip->unit_type], in scsb_led_get()
2480 suip->unit_number); in scsb_led_get()
2486 if (suip->unit_type == SLOT && !(scsb->scsb_state & SCSB_P10_PROM)) { in scsb_led_get()
2487 tonga_slotnum_check(scsb, suip); in scsb_led_get()
2490 if ((error = scsb_get_led_regnum(scsb, suip, &reg, &unit_number, in scsb_led_get()
2495 suip->unit_state = ON; in scsb_led_get()
2497 int code = FRU_UNIT_TO_EVCODE(suip->unit_type, in scsb_led_get()
2498 suip->unit_number); in scsb_led_get()
2503 suip->unit_state = BLINK; in scsb_led_get()
2506 suip->unit_state = OFF; in scsb_led_get()
2514 scsb_led_set(scsb_state_t *scsb, scsb_uinfo_t *suip, scsb_led_t led_type) in scsb_led_set() argument
2525 if (suip == NULL) { in scsb_led_set()
2535 led_type = suip->led_type; in scsb_led_set()
2536 } else if (suip->unit_type == SLOT && in scsb_led_set()
2550 if (suip->unit_state != OFF && suip->unit_state != ON && in scsb_led_set()
2551 suip->unit_state != BLINK) { in scsb_led_set()
2554 if (suip->unit_state == BLINK) { in scsb_led_set()
2557 if (suip->unit_type != SLOT && scsb->scsb_state & in scsb_led_set()
2565 unit_type_name[suip->unit_type], suip->unit_number, in scsb_led_set()
2566 suip->unit_state == ON ? "ON": in scsb_led_set()
2567 suip->unit_state == OFF ? "OFF": "BLINK"); in scsb_led_set()
2573 if (suip->unit_type == SLOT && !(scsb->scsb_state & SCSB_P10_PROM)) { in scsb_led_set()
2574 tonga_slotnum_check(scsb, suip); in scsb_led_set()
2579 if ((error = scsb_get_led_regnum(scsb, suip, &reg, &unit_number, in scsb_led_set()
2583 if (suip->unit_state == ON || suip->unit_state == BLINK) in scsb_led_set()
2602 (IS_SCB_P10 && suip->unit_type != SLOT) || in scsb_led_set()
2603 suip->unit_type == ALARM || in scsb_led_set()
2604 suip->unit_type == SSB || in scsb_led_set()
2605 suip->unit_type == CRTM || in scsb_led_set()
2606 suip->unit_type == PRTM) { in scsb_led_set()
2609 code = FRU_UNIT_TO_EVCODE(suip->unit_type, suip->unit_number); in scsb_led_set()
2612 if (suip->unit_state == BLINK) in scsb_led_set()
3758 scsb_bhealthy_slot(scsb_state_t *scsb, scsb_uinfo_t *suip) in scsb_bhealthy_slot() argument
3769 if (suip == NULL || suip->unit_type != SLOT) { in scsb_bhealthy_slot()
3775 suip->unit_number); in scsb_bhealthy_slot()
3776 if (suip->unit_number > mct_system_info.max_units[SLOT]) { in scsb_bhealthy_slot()
3782 tonga_slotnum_check(scsb, suip); in scsb_bhealthy_slot()
3784 code = FRU_UNIT_TO_EVCODE(suip->unit_type, suip->unit_number); in scsb_bhealthy_slot()
3796 suip->unit_state = ON; in scsb_bhealthy_slot()
3798 suip->unit_state = OFF; in scsb_bhealthy_slot()
3808 scsb_reset_unit(scsb_state_t *scsb, scsb_uinfo_t *suip) in scsb_reset_unit() argument
3819 scsb->scsb_instance, suip->unit_number, in scsb_reset_unit()
3820 suip->unit_state); in scsb_reset_unit()
3822 if (suip->unit_type != ALARM && !(scsb->scsb_state & in scsb_reset_unit()
3826 if (suip->unit_state != ON && suip->unit_state != OFF) { in scsb_reset_unit()
3830 switch (suip->unit_type) { in scsb_reset_unit()
3834 if (suip->unit_number != 1) in scsb_reset_unit()
3836 code = FRU_UNIT_TO_EVCODE(suip->unit_type, suip->unit_number); in scsb_reset_unit()
3843 slotnum = suip->unit_number; in scsb_reset_unit()
3844 reset_state = (suip->unit_state == ON) ? SCSB_RESET_SLOT : in scsb_reset_unit()
3865 if (suip->unit_state == ON) in scsb_reset_unit()
3886 scsb_slot_occupancy(scsb_state_t *scsb, scsb_uinfo_t *suip) in scsb_slot_occupancy() argument
3897 switch (suip->unit_type) { in scsb_slot_occupancy()
3899 if (suip->unit_number != in scsb_slot_occupancy()
3909 if (suip->unit_number < 1 || suip->unit_number > in scsb_slot_occupancy()
3915 saved_unit_number = suip->unit_number; in scsb_slot_occupancy()
3916 tonga_slotnum_check(scsb, suip); in scsb_slot_occupancy()
3926 if (suip->unit_state == ON) { in scsb_slot_occupancy()