1/*- 2 * Copyright (c) 1997-2009 by Matthew Jacob 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 14 unchanged lines hidden (view full) --- 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 */ 26 27/* 28 * Platform (FreeBSD) dependent common attachment code for Qlogic adapters. 29 */ 30#include <sys/cdefs.h> |
31__FBSDID("$FreeBSD: head/sys/dev/isp/isp_freebsd.c 291188 2015-11-23 10:06:19Z mav $"); |
32 33#include <dev/isp/isp_freebsd.h> 34#include <sys/unistd.h> 35#include <sys/kthread.h> 36#include <sys/conf.h> 37#include <sys/module.h> 38#include <sys/ioccom.h> 39#include <dev/isp/isp_ioctl.h> --- 396 unchanged lines hidden (view full) --- 436 chan = *(int *)addr; 437 if (chan < 0 || chan >= isp->isp_nchan) { 438 retval = -ENXIO; 439 break; 440 } 441 if (IS_FC(isp)) { 442 *(int *)addr = FCPARAM(isp, chan)->role; 443 } else { |
444 *(int *)addr = ISP_ROLE_INITIATOR; |
445 } 446 retval = 0; 447 break; 448 case ISP_SETROLE: |
449 if (IS_SCSI(isp)) 450 break; |
451 nr = *(int *)addr; 452 chan = nr >> 8; 453 if (chan < 0 || chan >= isp->isp_nchan) { 454 retval = -ENXIO; 455 break; 456 } 457 nr &= 0xff; 458 if (nr & ~(ISP_ROLE_INITIATOR|ISP_ROLE_TARGET)) { 459 retval = EINVAL; 460 break; 461 } 462 ISP_LOCK(isp); |
463 *(int *)addr = FCPARAM(isp, chan)->role; |
464 retval = isp_control(isp, ISPCTL_CHANGE_ROLE, chan, nr); 465 ISP_UNLOCK(isp); 466 retval = 0; 467 break; 468 469 case ISP_RESETHBA: 470 ISP_LOCK(isp); 471 isp_reinit(isp, 0); --- 296 unchanged lines hidden (view full) --- 768} 769 770static void 771isp_intr_enable(void *arg) 772{ 773 int chan; 774 ispsoftc_t *isp = arg; 775 ISP_LOCK(isp); |
776 if (IS_FC(isp)) { 777 for (chan = 0; chan < isp->isp_nchan; chan++) { |
778 if (FCPARAM(isp, chan)->role != ISP_ROLE_NONE) { 779 ISP_ENABLE_INTS(isp); 780 break; 781 } |
782 } |
783 } else { 784 ISP_ENABLE_INTS(isp); |
785 } 786 isp->isp_osinfo.ehook_active = 0; 787 ISP_UNLOCK(isp); 788 /* Release our hook so that the boot can continue. */ 789 config_intrhook_disestablish(&isp->isp_osinfo.ehook); 790} 791 792/* --- 29 unchanged lines hidden (view full) --- 822 ISP_PCMD(ccb) = NULL; 823 } 824} 825 826/* 827 * Put the target mode functions here, because some are inlines 828 */ 829#ifdef ISP_TARGET_MODE |
830static ISP_INLINE int is_lun_enabled(ispsoftc_t *, int, lun_id_t); 831static ISP_INLINE tstate_t *get_lun_statep(ispsoftc_t *, int, lun_id_t); 832static ISP_INLINE tstate_t *get_lun_statep_from_tag(ispsoftc_t *, int, uint32_t); 833static ISP_INLINE void rls_lun_statep(ispsoftc_t *, tstate_t *); 834static ISP_INLINE inot_private_data_t *get_ntp_from_tagdata(ispsoftc_t *, uint32_t, uint32_t, tstate_t **); 835static ISP_INLINE atio_private_data_t *isp_get_atpd(ispsoftc_t *, tstate_t *, uint32_t); 836static ISP_INLINE atio_private_data_t *isp_find_atpd(ispsoftc_t *, tstate_t *, uint32_t); 837static ISP_INLINE void isp_put_atpd(ispsoftc_t *, tstate_t *, atio_private_data_t *); 838static ISP_INLINE inot_private_data_t *isp_get_ntpd(ispsoftc_t *, tstate_t *); 839static ISP_INLINE inot_private_data_t *isp_find_ntpd(ispsoftc_t *, tstate_t *, uint32_t, uint32_t); 840static ISP_INLINE void isp_put_ntpd(ispsoftc_t *, tstate_t *, inot_private_data_t *); 841static cam_status create_lun_state(ispsoftc_t *, int, struct cam_path *, tstate_t **); 842static void destroy_lun_state(ispsoftc_t *, tstate_t *); 843static void isp_enable_lun(ispsoftc_t *, union ccb *); |
844static void isp_disable_lun(ispsoftc_t *, union ccb *); |
845static timeout_t isp_refire_putback_atio; 846static timeout_t isp_refire_notify_ack; 847static void isp_complete_ctio(union ccb *); 848static void isp_target_putback_atio(union ccb *); 849enum Start_Ctio_How { FROM_CAM, FROM_TIMER, FROM_SRR, FROM_CTIO_DONE }; 850static void isp_target_start_ctio(ispsoftc_t *, union ccb *, enum Start_Ctio_How); |
851static void isp_handle_platform_atio2(ispsoftc_t *, at2_entry_t *); 852static void isp_handle_platform_atio7(ispsoftc_t *, at7_entry_t *); 853static void isp_handle_platform_ctio(ispsoftc_t *, void *); |
854static void isp_handle_platform_notify_fc(ispsoftc_t *, in_fcentry_t *); 855static void isp_handle_platform_notify_24xx(ispsoftc_t *, in_fcentry_24xx_t *); 856static int isp_handle_platform_target_notify_ack(ispsoftc_t *, isp_notify_t *); 857static void isp_handle_platform_target_tmf(ispsoftc_t *, isp_notify_t *); 858static void isp_target_mark_aborted(ispsoftc_t *, union ccb *); 859static void isp_target_mark_aborted_early(ispsoftc_t *, tstate_t *, uint32_t); 860 |
861static ISP_INLINE int |
862is_lun_enabled(ispsoftc_t *isp, int bus, lun_id_t lun) 863{ 864 tstate_t *tptr; 865 struct tslist *lhp; 866 867 ISP_GET_PC_ADDR(isp, bus, lun_hash[LUN_HASH_FUNC(lun)], lhp); 868 SLIST_FOREACH(tptr, lhp, next) { 869 if (tptr->ts_lun == lun) { --- 299 unchanged lines hidden (view full) --- 1169 } while (ccb); 1170 ISP_GET_PC_ADDR(isp, cam_sim_bus(xpt_path_sim(tptr->owner)), lun_hash[LUN_HASH_FUNC(tptr->ts_lun)], lhp); 1171 SLIST_REMOVE(lhp, tptr, tstate, next); 1172 ISP_PATH_PRT(isp, ISP_LOGTDEBUG0, tptr->owner, "destroyed tstate\n"); 1173 xpt_free_path(tptr->owner); 1174 free(tptr, M_DEVBUF); 1175} 1176 |
1177static void 1178isp_enable_lun(ispsoftc_t *isp, union ccb *ccb) 1179{ |
1180 tstate_t *tptr; 1181 int bus; |
1182 target_id_t target; 1183 lun_id_t lun; 1184 |
1185 if (!IS_FC(isp) || !ISP_CAP_TMODE(isp) || !ISP_CAP_SCCFW(isp)) { 1186 xpt_print(ccb->ccb_h.path, "Target mode is not supported\n"); 1187 ccb->ccb_h.status = CAM_FUNC_NOTAVAIL; 1188 xpt_done(ccb); 1189 return; 1190 } |
1191 1192 /* |
1193 * We only support either target and lun both wildcard 1194 * or target and lun both non-wildcard. |
1195 */ 1196 bus = XS_CHANNEL(ccb); 1197 target = ccb->ccb_h.target_id; 1198 lun = ccb->ccb_h.target_lun; 1199 ISP_PATH_PRT(isp, ISP_LOGTDEBUG0|ISP_LOGCONFIG, ccb->ccb_h.path, 1200 "enabling lun %jx\n", (uintmax_t)lun); |
1201 if ((target == CAM_TARGET_WILDCARD) != (lun == CAM_LUN_WILDCARD)) { |
1202 ccb->ccb_h.status = CAM_LUN_INVALID; 1203 xpt_done(ccb); 1204 return; 1205 } 1206 |
1207 /* Create the state pointer. It should not already exist. */ |
1208 tptr = get_lun_statep(isp, bus, lun); 1209 if (tptr) { 1210 ccb->ccb_h.status = CAM_LUN_ALRDY_ENA; |
1211 xpt_done(ccb); 1212 return; |
1213 } 1214 ccb->ccb_h.status = create_lun_state(isp, bus, ccb->ccb_h.path, &tptr); 1215 if (ccb->ccb_h.status != CAM_REQ_CMP) { |
1216 xpt_done(ccb); 1217 return; |
1218 } 1219 |
1220 rls_lun_statep(isp, tptr); 1221 ccb->ccb_h.status = CAM_REQ_CMP; |
1222 xpt_done(ccb); 1223} 1224 |
1225static void 1226isp_disable_lun(ispsoftc_t *isp, union ccb *ccb) 1227{ 1228 tstate_t *tptr = NULL; 1229 int bus; |
1230 target_id_t target; 1231 lun_id_t lun; 1232 1233 bus = XS_CHANNEL(ccb); 1234 target = ccb->ccb_h.target_id; 1235 lun = ccb->ccb_h.target_lun; 1236 ISP_PATH_PRT(isp, ISP_LOGTDEBUG0|ISP_LOGCONFIG, ccb->ccb_h.path, 1237 "disabling lun %jx\n", (uintmax_t)lun); |
1238 if ((target == CAM_TARGET_WILDCARD) != (lun == CAM_LUN_WILDCARD)) { |
1239 ccb->ccb_h.status = CAM_LUN_INVALID; 1240 xpt_done(ccb); 1241 return; 1242 } 1243 |
1244 /* Find the state pointer. */ 1245 if ((tptr = get_lun_statep(isp, bus, lun)) == NULL) { 1246 ccb->ccb_h.status = CAM_PATH_INVALID; |
1247 xpt_done(ccb); 1248 return; 1249 } 1250 |
1251 destroy_lun_state(isp, tptr); 1252 ccb->ccb_h.status = CAM_REQ_CMP; |
1253 xpt_done(ccb); 1254} 1255 |
1256static void |
1257isp_target_start_ctio(ispsoftc_t *isp, union ccb *ccb, enum Start_Ctio_How how) 1258{ 1259 int fctape, sendstatus, resid; 1260 tstate_t *tptr; 1261 fcparam *fcp; 1262 atio_private_data_t *atp; 1263 struct ccb_scsiio *cso; 1264 uint32_t dmaresult, handle, xfrlen, sense_length, tmp; --- 280 unchanged lines hidden (view full) --- 1545 atp->state = ATPD_STATE_CTIO; 1546 } 1547 } else { 1548 atp->state = ATPD_STATE_CTIO; 1549 } 1550 isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO7[0x%x] seq %u nc %d CDB0=%x sstatus=0x%x flags=0x%x xfrlen=%u off=%u", __func__, 1551 cto->ct_rxid, ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cto->ct_scsi_status, cto->ct_flags, xfrlen, atp->bytes_xfered); 1552 } |
1553 } else { |
1554 ct2_entry_t *cto = (ct2_entry_t *) local; 1555 1556 if (isp->isp_osinfo.sixtyfourbit) 1557 cto->ct_header.rqs_entry_type = RQSTYPE_CTIO3; 1558 else 1559 cto->ct_header.rqs_entry_type = RQSTYPE_CTIO2; 1560 cto->ct_header.rqs_entry_count = 1; 1561 cto->ct_header.rqs_seqno |= ATPD_SEQ_NOTIFY_CAM; --- 132 unchanged lines hidden (view full) --- 1694 atp->state = ATPD_STATE_CTIO; 1695 } 1696 } else { 1697 atp->state = ATPD_STATE_CTIO; 1698 } 1699 } 1700 isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO2[%x] seq %u nc %d CDB0=%x scsi status %x flags %x resid %d xfrlen %u offset %u", __func__, cto->ct_rxid, 1701 ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cso->scsi_status, cto->ct_flags, cto->ct_resid, cso->dxfer_len, atp->bytes_xfered); |
1702 } 1703 1704 if (isp_get_pcmd(isp, ccb)) { 1705 ISP_PATH_PRT(isp, ISP_LOGWARN, ccb->ccb_h.path, "out of PCMDs\n"); 1706 TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); 1707 break; 1708 } 1709 if (isp_allocate_xs_tgt(isp, ccb, &handle)) { --- 13 unchanged lines hidden (view full) --- 1723 * any swizzling is done in the machine dependent layer. Because 1724 * of this, we put the request onto the queue area first in native 1725 * format. 1726 */ 1727 1728 if (IS_24XX(isp)) { 1729 ct7_entry_t *cto = (ct7_entry_t *) local; 1730 cto->ct_syshandle = handle; |
1731 } else { |
1732 ct2_entry_t *cto = (ct2_entry_t *) local; 1733 cto->ct_syshandle = handle; |
1734 } 1735 1736 dmaresult = ISP_DMASETUP(isp, cso, (ispreq_t *) local); 1737 if (dmaresult != CMD_QUEUED) { 1738 isp_destroy_tgt_handle(isp, handle); 1739 isp_free_pcmd(isp, ccb); 1740 if (dmaresult == CMD_EAGAIN) { 1741 TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); --- 41 unchanged lines hidden (view full) --- 1783 1784 1785static void 1786isp_target_putback_atio(union ccb *ccb) 1787{ 1788 ispsoftc_t *isp; 1789 struct ccb_scsiio *cso; 1790 void *qe; |
1791 at2_entry_t local, *at = &local; |
1792 1793 isp = XS_ISP(ccb); 1794 1795 qe = isp_getrqentry(isp); 1796 if (qe == NULL) { 1797 xpt_print(ccb->ccb_h.path, 1798 "%s: Request Queue Overflow\n", __func__); 1799 callout_reset(&PISP_PCMD(ccb)->wdog, 10, 1800 isp_refire_putback_atio, ccb); 1801 return; 1802 } 1803 memset(qe, 0, QENTRY_LEN); 1804 cso = &ccb->csio; |
1805 ISP_MEMZERO(at, sizeof (at2_entry_t)); 1806 at->at_header.rqs_entry_type = RQSTYPE_ATIO2; 1807 at->at_header.rqs_entry_count = 1; 1808 if (ISP_CAP_SCCFW(isp)) { 1809 at->at_scclun = (uint16_t) ccb->ccb_h.target_lun; |
1810#if __FreeBSD_version < 1000700 |
1811 if (at->at_scclun >= 256) 1812 at->at_scclun |= 0x4000; |
1813#endif |
1814 } else { |
1815 at->at_lun = (uint8_t) ccb->ccb_h.target_lun; |
1816 } |
1817 at->at_status = CT_OK; 1818 at->at_rxid = cso->tag_id; 1819 at->at_iid = cso->ccb_h.target_id; 1820 isp_put_atio2(isp, at, qe); |
1821 ISP_TDQE(isp, "isp_target_putback_atio", isp->isp_reqidx, qe); 1822 ISP_SYNC_REQUEST(isp); 1823 isp_complete_ctio(ccb); 1824} 1825 1826static void 1827isp_complete_ctio(union ccb *ccb) 1828{ 1829 if ((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_INPROG) { 1830 ccb->ccb_h.status &= ~CAM_SIM_QUEUED; 1831 xpt_done(ccb); 1832 } 1833} 1834 |
1835static void |
1836isp_handle_platform_atio2(ispsoftc_t *isp, at2_entry_t *aep) 1837{ 1838 fcparam *fcp; 1839 lun_id_t lun; 1840 fcportdb_t *lp; 1841 tstate_t *tptr; 1842 struct ccb_accept_tio *atiop; 1843 uint16_t nphdl; --- 542 unchanged lines hidden (view full) --- 2386{ 2387 union ccb *ccb; 2388 int sentstatus = 0, ok = 0, notify_cam = 0, resid = 0, failure = 0; 2389 tstate_t *tptr = NULL; 2390 atio_private_data_t *atp = NULL; 2391 int bus; 2392 uint32_t handle, moved_data = 0, data_requested; 2393 |
2394 handle = ((ct2_entry_t *)arg)->ct_syshandle; |
2395 ccb = isp_find_xs_tgt(isp, handle); 2396 if (ccb == NULL) { 2397 isp_print_bytes(isp, "null ccb in isp_handle_platform_ctio", QENTRY_LEN, arg); 2398 return; 2399 } 2400 isp_destroy_tgt_handle(isp, handle); 2401 data_requested = PISP_PCMD(ccb)->datalen; 2402 isp_free_pcmd(isp, ccb); --- 8 unchanged lines hidden (view full) --- 2411 } 2412 if (tptr == NULL) { 2413 isp_prt(isp, ISP_LOGERR, "%s: cannot find tptr for tag %x after I/O", __func__, ccb->csio.tag_id); 2414 return; 2415 } 2416 2417 if (IS_24XX(isp)) { 2418 atp = isp_find_atpd(isp, tptr, ((ct7_entry_t *)arg)->ct_rxid); |
2419 } else { |
2420 atp = isp_find_atpd(isp, tptr, ((ct2_entry_t *)arg)->ct_rxid); |
2421 } 2422 if (atp == NULL) { 2423 /* 2424 * XXX: isp_clear_commands() generates fake CTIO with zero 2425 * ct_rxid value, filling only ct_syshandle. Workaround 2426 * that using tag_id from the CCB, pointed by ct_syshandle. 2427 */ 2428 atp = isp_find_atpd(isp, tptr, ccb->csio.tag_id); --- 26 unchanged lines hidden (view full) --- 2455 notify_cam = (ct->ct_header.rqs_seqno & ATPD_SEQ_NOTIFY_CAM) != 0; 2456 if ((ct->ct_flags & CT7_DATAMASK) != CT7_NO_DATA) { 2457 resid = ct->ct_resid; 2458 moved_data = data_requested - resid; 2459 } 2460 } 2461 isp_prt(isp, ok? ISP_LOGTDEBUG0 : ISP_LOGWARN, "%s: CTIO7[%x] seq %u nc %d sts 0x%x flg 0x%x sns %d resid %d %s", __func__, ct->ct_rxid, ATPD_GET_SEQNO(ct), 2462 notify_cam, ct->ct_nphdl, ct->ct_flags, (ccb->ccb_h.status & CAM_SENT_SENSE) != 0, resid, sentstatus? "FIN" : "MID"); |
2463 } else { |
2464 ct2_entry_t *ct = arg; 2465 if (ct->ct_status == CT_SRR) { 2466 atp->srr_ccb = ccb; 2467 if (atp->srr_notify_rcvd) 2468 isp_handle_srr_start(isp, tptr, atp); 2469 rls_lun_statep(isp, tptr); 2470 isp_target_putback_atio(ccb); 2471 return; --- 6 unchanged lines hidden (view full) --- 2478 notify_cam = (ct->ct_header.rqs_seqno & ATPD_SEQ_NOTIFY_CAM) != 0; 2479 if ((ct->ct_flags & CT2_DATAMASK) != CT2_NO_DATA) { 2480 resid = ct->ct_resid; 2481 moved_data = data_requested - resid; 2482 } 2483 } 2484 isp_prt(isp, ok? ISP_LOGTDEBUG0 : ISP_LOGWARN, "%s: CTIO2[%x] seq %u nc %d sts 0x%x flg 0x%x sns %d resid %d %s", __func__, ct->ct_rxid, ATPD_GET_SEQNO(ct), 2485 notify_cam, ct->ct_status, ct->ct_flags, (ccb->ccb_h.status & CAM_SENT_SENSE) != 0, resid, sentstatus? "FIN" : "MID"); |
2486 } 2487 if (ok) { 2488 if (moved_data) { 2489 atp->bytes_xfered += moved_data; 2490 ccb->csio.resid = atp->orig_datalen - atp->bytes_xfered - atp->bytes_in_transit; 2491 } 2492 if (sentstatus && (ccb->ccb_h.flags & CAM_SEND_SENSE)) { 2493 ccb->ccb_h.status |= CAM_SENT_SENSE; --- 37 unchanged lines hidden (view full) --- 2531 if (ok || IS_24XX(isp)) { 2532 isp_complete_ctio(ccb); 2533 } else { 2534 isp_target_putback_atio(ccb); 2535 } 2536} 2537 2538static void |
2539isp_handle_platform_notify_fc(ispsoftc_t *isp, in_fcentry_t *inp) 2540{ 2541 int needack = 1; 2542 switch (inp->in_status) { 2543 case IN_PORT_LOGOUT: 2544 /* 2545 * XXX: Need to delete this initiator's WWN from the database 2546 * XXX: Need to send this LOGOUT upstream --- 514 unchanged lines hidden (view full) --- 3061 switch (code) { 3062 case AC_LOST_DEVICE: 3063 if (IS_SCSI(isp)) { 3064 uint16_t oflags, nflags; 3065 sdparam *sdp = SDPARAM(isp, bus); 3066 3067 if (tgt >= 0) { 3068 nflags = sdp->isp_devparam[tgt].nvrm_flags; |
3069 nflags &= DPARM_SAFE_DFLT; 3070 if (isp->isp_loaded_fw) { 3071 nflags |= DPARM_NARROW | DPARM_ASYNC; 3072 } |
3073 oflags = sdp->isp_devparam[tgt].goal_flags; 3074 sdp->isp_devparam[tgt].goal_flags = nflags; 3075 sdp->isp_devparam[tgt].dev_update = 1; 3076 sdp->update = 1; 3077 (void) isp_control(isp, ISPCTL_UPDATE_PARAMS, bus); 3078 sdp->isp_devparam[tgt].goal_flags = oflags; 3079 } 3080 } --- 899 unchanged lines hidden (view full) --- 3980 if (fcp->role != ISP_ROLE_BOTH) { 3981 rchange = 1; 3982 newrole = ISP_ROLE_BOTH; 3983 } 3984 break; 3985 } 3986 if (rchange) { 3987 ISP_PATH_PRT(isp, ISP_LOGCONFIG, ccb->ccb_h.path, "changing role on from %d to %d\n", fcp->role, newrole); |
3988 if (isp_control(isp, ISPCTL_CHANGE_ROLE, 3989 bus, newrole) != 0) { 3990 ccb->ccb_h.status = CAM_REQ_CMP_ERR; 3991 xpt_done(ccb); 3992 break; 3993 } |
3994 } 3995 } 3996 xpt_done(ccb); 3997 break; 3998 } 3999 case XPT_GET_SIM_KNOB: /* Get SIM knobs */ 4000 { 4001 struct ccb_sim_knob *kp = &ccb->knob; --- 29 unchanged lines hidden (view full) --- 4031 break; 4032 } 4033 case XPT_PATH_INQ: /* Path routing inquiry */ 4034 { 4035 struct ccb_pathinq *cpi = &ccb->cpi; 4036 4037 cpi->version_num = 1; 4038#ifdef ISP_TARGET_MODE |
4039 if (IS_FC(isp) && ISP_CAP_TMODE(isp) && ISP_CAP_SCCFW(isp)) 4040 cpi->target_sprt = PIT_PROCESSOR | PIT_DISCONNECT | PIT_TERM_IO; 4041 else |
4042#endif |
4043 cpi->target_sprt = 0; |
4044 cpi->hba_eng_cnt = 0; 4045 cpi->max_target = ISP_MAX_TARGETS(isp) - 1; 4046 cpi->max_lun = ISP_MAX_LUNS(isp) == 0 ? 4047 255 : ISP_MAX_LUNS(isp) - 1; 4048 cpi->bus_id = cam_sim_bus(sim); 4049 if (isp->isp_osinfo.sixtyfourbit) 4050 cpi->maxio = (ISP_NSEG64_MAX - 1) * PAGE_SIZE; 4051 else --- 473 unchanged lines hidden (view full) --- 4525 va_start(ap, cmd); 4526 hp = va_arg(ap, isphdr_t *); 4527 va_end(ap); 4528 switch (hp->rqs_entry_type) { 4529 default: 4530 isp_prt(isp, ISP_LOGWARN, "%s: unhandled target action 0x%x", __func__, hp->rqs_entry_type); 4531 break; 4532 case RQSTYPE_NOTIFY: |
4533 if (IS_24XX(isp)) { |
4534 isp_handle_platform_notify_24xx(isp, (in_fcentry_24xx_t *) hp); 4535 } else { 4536 isp_handle_platform_notify_fc(isp, (in_fcentry_t *) hp); 4537 } 4538 break; 4539 case RQSTYPE_ATIO: |
4540 isp_handle_platform_atio7(isp, (at7_entry_t *) hp); |
4541 break; 4542 case RQSTYPE_ATIO2: 4543 isp_handle_platform_atio2(isp, (at2_entry_t *) hp); 4544 break; 4545 case RQSTYPE_CTIO7: 4546 case RQSTYPE_CTIO3: 4547 case RQSTYPE_CTIO2: 4548 case RQSTYPE_CTIO: --- 48 unchanged lines hidden (view full) --- 4597 abts->abts_rxid_abts, abts->abts_nphdl, sid, abts->abts_rxid_task, abts->abts_rx_id, abts->abts_ox_id); 4598 } 4599 nt->nt_channel = chan; 4600 nt->nt_ncode = NT_ABORT_TASK; 4601 nt->nt_lreserved = hp; 4602 isp_handle_platform_target_tmf(isp, nt); 4603 break; 4604 } |
4605 } 4606 break; 4607 } 4608#endif 4609 case ISPASYNC_FW_CRASH: 4610 { 4611 uint16_t mbox1, mbox6; 4612 mbox1 = ISP_READ(isp, OUTMAILBOX1); --- 403 unchanged lines hidden --- |