Lines Matching defs:code

1129 		 * See the minor device code below.
2119 int code, base, error;
2147 code = FRU_UNIT_TO_EVCODE(SLOT, suip->unit_number);
2162 code = FRU_UNIT_TO_EVCODE(PDU, suip->unit_number);
2177 code = FRU_UNIT_TO_EVCODE(PS, suip->unit_number);
2194 code = FRU_UNIT_TO_EVCODE(DISK, suip->unit_number);
2209 code = FRU_UNIT_TO_EVCODE(FAN, suip->unit_number);
2224 code = FRU_UNIT_TO_EVCODE(CFTM, suip->unit_number);
2239 code = FRU_UNIT_TO_EVCODE(SCB, suip->unit_number);
2256 *unitptr = FRU_OFFSET(code, base);
2257 *regptr = FRU_REG_ADDR(code, base);
2260 "regptr=%x, code = %x\n",
2261 *unitptr, *regptr, code);
2497 int code = FRU_UNIT_TO_EVCODE(suip->unit_type,
2499 reg = FRU_REG_ADDR(code, SCTRL_BLINK_OK_BASE);
2519 int code, index;
2609 code = FRU_UNIT_TO_EVCODE(suip->unit_type, suip->unit_number);
2610 reg = FRU_REG_ADDR(code, SCTRL_BLINK_OK_BASE);
2755 * The code is tested on PSUs:
3015 * Get the slot event code (t), then use it to get the
3018 * find the event code.
3081 * get the FRU event code (t), then use it to get the
3139 * get the FRU event code (t), then use it to get the
3198 * get the FRU event code (t), then use it to get the
3257 * get the FRU event code (t), then use it to get the
3317 * get the FRU event code (t), then use it to get the
3374 * get the FRU event code (t), then use it to get the
3427 * get the FRU event code (t), then use it to get the
3471 * get the FRU event code (t), then use it to get the
3532 * get the FRU event code (t), then use it to get the
3576 * get the FRU event code (t), then use it to get the
3761 int base, code, unit_number;
3784 code = FRU_UNIT_TO_EVCODE(suip->unit_type, suip->unit_number);
3785 unit_number = FRU_OFFSET(code, base);
3786 index = FRU_REG_INDEX(code, base);
3833 int i, code;
3836 code = FRU_UNIT_TO_EVCODE(suip->unit_type, suip->unit_number);
3837 unit_number = FRU_OFFSET(code, SCTRL_RESET_BASE);
3838 i = ALARM_RESET_REG_INDEX(code, SCTRL_RESET_BASE);
4005 int tmp, idx, code, unit, offset, mbid;
4028 code = FRU_UNIT_TO_EVCODE(fru_type, unit);
4029 offset = FRU_OFFSET(code, SCTRL_INTMSK_BASE);
4030 reg = FRU_REG_ADDR(code, SCTRL_INTMSK_BASE);
4044 reg = FRU_REG_ADDR(code,
4066 code = SCTRL_EVENT_PWRDWN;
4067 offset = FRU_OFFSET(code, SCTRL_INTMSK_BASE);
4068 reg = FRU_REG_ADDR(code, SCTRL_INTMSK_BASE);
4073 code = SCTRL_EVENT_SCB;
4074 offset = FRU_OFFSET(code, SCTRL_INTMSK_BASE);
4075 reg = FRU_REG_ADDR(code, SCTRL_INTMSK_BASE) + SCB_INT_OFFSET;
4079 code = SCTRL_EVENT_ALARM_INT;
4080 offset = FRU_OFFSET(code, SCTRL_INTMSK_BASE);
4081 reg = FRU_REG_ADDR(code, SCTRL_INTMSK_BASE);
4168 uint32_t code;
4193 code = FRU_UNIT_TO_EVCODE(SLOT, slotnum);
4194 offset = FRU_OFFSET(code, SCTRL_RESET_BASE);
4195 reg = FRU_REG_ADDR(code, SCTRL_RESET_BASE);
4211 uint32_t code;
4225 code = SCTRL_EVENT_SCB;
4227 scsb_event_code = code;
4228 check_fru_info(scsb, code);
4229 add_event_code(scsb, code);
4230 (void) scsb_queue_ops(scsb, QPUT_INT32, 1, &code, "scsb_freeze");
4374 uint32_t code;
4402 * code to set the scsb_state PROM ID bits and to set up the
4483 * Theoretically, this code could be moved back to the check for
4509 * report the event code as we check for other
4645 * Clear the event code,
4668 * The scb_fru_offset[] index is now the SCTRL_EVENT code.
4669 * The code is then compared to type_to_code1[] entries to find the
4684 * the bit-number of the current event code
4685 * code: manufactured event code for current INT event
4697 code = (1 << idx); /* back to bit mask */
4698 clr_bits |= code;
4699 intr_reg = intr_reg & ~code; /* clear this one */
4728 * to get the event code.
4730 code = (uint32_t)(1 << j);
4732 cmn_err(CE_NOTE, "scsb_intr: code=0x%x", code);
4737 if (code == SCTRL_EVENT_PWRDWN) {
4743 scsb_event_code |= code;
4749 * event code to EnvMon scsb policy
4757 } else if (code == SCTRL_EVENT_REPLACE) {
4766 scsb_event_code |= code;
4769 } else if (code == SCTRL_EVENT_SCB) {
4782 * set the event code bit here in order to
4792 scsb_event_code |= code;
4795 } else if (code == SCTRL_EVENT_ALARM_INT) {
4808 scsb_event_code |= code;
4818 } else if ((ui = event_to_type(code)) == 0xffff) {
4832 "FRU type/unit/code %d/%d/0x%x",
4833 fru_type, unit, code);
4876 * the code corresponding to the
4879 code = FRU_UNIT_TO_EVCODE(SLOT,
5030 scsb_event_code |= code;
5075 code = (1 << idx);
5076 clr_bits |= code;
5077 intr_reg = intr_reg & ~code;
5101 code = scsb_event_code;
5104 check_fru_info(scsb, code);
5105 add_event_code(scsb, code);
5153 * and we're retrieving the event code from the event FIFO.
6200 * Convert EVENT code to FRU index
6231 * event code functions to deliver event codes
6233 * the event code fifo
6238 * Send signal to processes registered for event code delivery
6292 * Called from scsb_intr() when a new event occurs, to put new code in FIFO,
6336 * called from check_event_procs() to retrieve the current event code
6492 * registered for event code delivery.
6642 int tmp, idx, code, offset;
6649 /* get the event code based on which we get the reg and bit offsets */
6650 code = FRU_UNIT_TO_EVCODE(fru_type, unit);
6652 offset = FRU_OFFSET(code, base);
6653 /* register offset from the base register, based on the event code */
6655 tmp = ALARM_RESET_REG_INDEX(code, base);
6657 tmp = FRU_REG_INDEX(code, base);
6662 DEBUG4("scsb_fru_op(start): code=%x, offset=%x, tmp=%x, reg=%x\n",
6663 code, offset, tmp, reg);