Lines Matching defs:unit
125 PR_MEM("%s: memlist for mem-unit (%d.%d), dip 0x%p:\n",
151 int unit;
160 unit = sbdp_get_unit_num(hdp, dip);
161 if (unit == -1) {
171 mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
174 ASSERT(unit == mp->sbm_cm.sbdev_unum);
176 PR_MEM("sbd: OS attach mem-unit (%d.%d)\n",
186 " mem-unit (%d.%d)\n",
204 PR_MEM("%s: mem-unit (%d.%d)"
240 "%s: unexpected state (%d) for mem-unit "
277 int unit;
284 unit = sbdp_get_unit_num(hdp, dip);
285 if (unit == -1) {
294 mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
299 "%s: no memlist for mem-unit (%d.%d)",
306 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
322 "%s: mem-unit (%d.%d) memlist not in"
328 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
371 int unit;
386 unit = sbdp_get_unit_num(hdp, dip);
387 if (unit == -1) {
397 mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
401 ASSERT(unit == mp->sbm_cm.sbdev_unum);
403 PR_MEM("sbd: OS detach mem-unit (%d.%d)\n",
431 int unit;
443 unit = sbdp_get_unit_num(hdp, dip);
444 if (unit == -1) {
454 s_mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
462 /* this is no target unit */
556 "sbd:%s: no alignment for mem-unit (%d.%d)",
588 /* this is no target unit */
612 "%s: %smem-unit (%d.%d) memlist still in phys_install",
695 " of mem-unit (%d.%d), memlist:\n",
751 /* clean up target mem unit */
789 * clean up (source) board's mem unit structure.
812 * handle in sbp->sb_dev[..mem-unit...].sbm_memhandle allocated
852 * If all the mem unit is marked as failed then don't allow the
888 "%s: ineligible mem-unit (%d.%d) for detach",
911 " mem-unit (%d.%d), dip 0x%p",
1015 "mem-unit (%d.%d)",
1070 sbd_release_mem_done(sbd_handle_t *hp, int unit)
1078 s_mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
1082 * This unit will be flagged with SBD_MFLAG_SOURCE, if it
1083 * has a target unit.
1092 /* this is no target unit */
1113 * the source (and target, if present) unit data.
1117 PR_MEM("%s: unit %d.%d: error %d noted\n",
1128 SBD_DEV_SET_RELEASED(sbp, SBD_COMP_MEM, unit);
1129 SBD_DEVICE_TRANSITION(sbp, SBD_COMP_MEM, unit, SBD_STATE_RELEASE);
1147 * even if the mem-unit was the last configure
1148 * unit of the board. When copy/rename completes
1149 * this mem-unit will transitioned back to
1170 cmn_err(CE_WARN, "sbd:%s: %smem-unit (%d.%d): "
1190 SBD_DEV_SET_UNREFERENCED(sbp, SBD_COMP_MEM, unit);
1191 SBD_DEVICE_TRANSITION(sbp, SBD_COMP_MEM, unit, SBD_STATE_UNREFERENCED);
1193 PR_MEM("%s: marking mem-unit (%d.%d) release DONE\n",
1210 PR_MEM("%s: marking mem-unit (%d.%d) release DONE\n",
1219 sbd_disconnect_mem(sbd_handle_t *hp, int unit)
1225 mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
1245 sbd_cancel_mem(sbd_handle_t *hp, int unit)
1254 s_mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
1261 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
1272 /* this is no target unit */
1343 "mem-unit %d.%d\n",
1355 sbd_init_mem_unit(sbd_board_t *sbp, int unit, sbderror_t *ep)
1364 mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
1366 if (SBD_DEV_IS_ATTACHED(sbp, SBD_COMP_MEM, unit)) {
1368 } else if (SBD_DEV_IS_PRESENT(sbp, SBD_COMP_MEM, unit)) {
1412 * Any changes to this memory unit should be performed above
1413 * this call to ensure the unit is fully initialized
1416 SBD_DEVICE_TRANSITION(sbp, SBD_COMP_MEM, unit, new_state);
1438 /* get basepfn of mem unit */
1441 " for mem-unit (%d.%d)",
1466 "sbd:%s: no alignment for mem-unit (%d.%d)",
1639 "sbd:%s: no alignment for mem-unit (%d.%d)",
1680 /* source unit can not be its own target */
1745 /* get candidate target board mem unit */
1756 " mem-unit %d, board %d",
2236 int err, unit;
2288 unit = sbdp_get_unit_num(hdp, dip);
2289 if (unit < 0) {
2295 ASSERT(sbp->sb_mempath[unit] != NULL);
2298 (void) ddi_pathname(dip, sbp->sb_mempath[unit]);
2300 mp = SBD_GET_BOARD_MEMUNIT(sbp, unit);
2311 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
2375 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
2391 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
2410 sbd_release_mem(sbd_handle_t *hp, dev_info_t *dip, int unit)
2506 SBD_SET_ERRSTR(SBD_HD2ERR(hp), sbp->sb_mempath[unit]);
2535 int unit)
2547 /* lookup target mem unit and target board structure, if any */
2557 /* verify mem unit's state is UNREFERENCED */
2561 " mem-unit (%d.%d)",
2566 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
2570 /* verify target mem unit's state is UNREFERENCED, if any */
2575 " target mem-unit (%d.%d)",
2580 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
2607 "%s: failed to deprogram mem-unit (%d.%d),"
2618 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
2636 SBD_SET_ERRSTR(ep, sbp->sb_mempath[unit]);
2644 int unit;
2652 unit = sbdp_get_unit_num(hdp, dip);
2659 if (unit == -1) {
2662 if (sbd_cancel_mem(hp, unit) != 0)
2676 unit, SBD_STATE_CONFIGURED);