require '_h2ph_pre.ph';

unless(defined(&_ISP_TARGET_H)) {
    eval 'sub _ISP_TARGET_H () {1;}' unless defined(&_ISP_TARGET_H);
    eval 'sub QLTM_SVALID () {0x80;}' unless defined(&QLTM_SVALID);
    eval 'sub QLTM_SENSELEN () {18;}' unless defined(&QLTM_SENSELEN);
    eval 'sub LUN_TQAE () {0x00000002;}' unless defined(&LUN_TQAE);
    eval 'sub LUN_DSSM () {0x01000000;}' unless defined(&LUN_DSSM);
    eval 'sub LUN_DISAD () {0x02000000;}' unless defined(&LUN_DISAD);
    eval 'sub LUN_DM () {0x40000000;}' unless defined(&LUN_DM);
    eval 'sub LUN_CCINCR () {0x01;}' unless defined(&LUN_CCINCR);
    eval 'sub LUN_CCDECR () {0x02;}' unless defined(&LUN_CCDECR);
    eval 'sub LUN_ININCR () {0x40;}' unless defined(&LUN_ININCR);
    eval 'sub LUN_INDECR () {0x80;}' unless defined(&LUN_INDECR);
    eval 'sub LUN_OK () {0x01;}' unless defined(&LUN_OK);
    eval 'sub LUN_ERR () {0x04;}' unless defined(&LUN_ERR);
    eval 'sub LUN_INVAL () {0x06;}' unless defined(&LUN_INVAL);
    eval 'sub LUN_NOCAP () {0x16;}' unless defined(&LUN_NOCAP);
    eval 'sub LUN_ENABLED () {0x3e;}' unless defined(&LUN_ENABLED);
    eval 'sub IN_MSGLEN () {8;}' unless defined(&IN_MSGLEN);
    eval 'sub IN_RSVDLEN () {8;}' unless defined(&IN_RSVDLEN);
    eval 'sub IN_REJECT () {0x0d;}' unless defined(&IN_REJECT);
    eval 'sub IN_RESET () {0x0e;}' unless defined(&IN_RESET);
    eval 'sub IN_NO_RCAP () {0x16;}' unless defined(&IN_NO_RCAP);
    eval 'sub IN_IDE_RECEIVED () {0x33;}' unless defined(&IN_IDE_RECEIVED);
    eval 'sub IN_RSRC_UNAVAIL () {0x34;}' unless defined(&IN_RSRC_UNAVAIL);
    eval 'sub IN_MSG_RECEIVED () {0x36;}' unless defined(&IN_MSG_RECEIVED);
    eval 'sub IN_ABORT_TASK () {0x20;}' unless defined(&IN_ABORT_TASK);
    eval 'sub IN_PORT_LOGOUT () {0x29;}' unless defined(&IN_PORT_LOGOUT);
    eval 'sub IN_PORT_CHANGED () {0x2a;}' unless defined(&IN_PORT_CHANGED);
    eval 'sub IN_GLOBAL_LOGO () {0x2e;}' unless defined(&IN_GLOBAL_LOGO);
    eval 'sub IN_NO_NEXUS () {0x3b;}' unless defined(&IN_NO_NEXUS);
    eval 'sub TASK_FLAGS_ABORT_TASK () {(1<<9);}' unless defined(&TASK_FLAGS_ABORT_TASK);
    eval 'sub TASK_FLAGS_CLEAR_TASK_SET () {(1<<10);}' unless defined(&TASK_FLAGS_CLEAR_TASK_SET);
    eval 'sub TASK_FLAGS_TARGET_RESET () {(1<<13);}' unless defined(&TASK_FLAGS_TARGET_RESET);
    eval 'sub TASK_FLAGS_CLEAR_ACA () {(1<<14);}' unless defined(&TASK_FLAGS_CLEAR_ACA);
    eval 'sub TASK_FLAGS_TERMINATE_TASK () {(1<<15);}' unless defined(&TASK_FLAGS_TERMINATE_TASK);
    unless(defined(&MSG_ABORT_TAG)) {
	eval 'sub MSG_ABORT_TAG () {0x06;}' unless defined(&MSG_ABORT_TAG);
    }
    unless(defined(&MSG_CLEAR_QUEUE)) {
	eval 'sub MSG_CLEAR_QUEUE () {0x0e;}' unless defined(&MSG_CLEAR_QUEUE);
    }
    unless(defined(&MSG_BUS_DEV_RESET)) {
	eval 'sub MSG_BUS_DEV_RESET () {0x0b;}' unless defined(&MSG_BUS_DEV_RESET);
    }
    unless(defined(&MSG_REL_RECOVERY)) {
	eval 'sub MSG_REL_RECOVERY () {0x10;}' unless defined(&MSG_REL_RECOVERY);
    }
    unless(defined(&MSG_TERM_IO_PROC)) {
	eval 'sub MSG_TERM_IO_PROC () {0x11;}' unless defined(&MSG_TERM_IO_PROC);
    }
    eval 'sub NA_RSVDLEN () {22;}' unless defined(&NA_RSVDLEN);
    eval 'sub NA_RST_CLRD () {0x80;}' unless defined(&NA_RST_CLRD);
    eval 'sub NA_OK () {0x01;}' unless defined(&NA_OK);
    eval 'sub NA_INVALID () {0x06;}' unless defined(&NA_INVALID);
    eval 'sub NA2_RSVDLEN () {21;}' unless defined(&NA2_RSVDLEN);
    eval 'sub NAFC_RCOUNT () {0x80;}' unless defined(&NAFC_RCOUNT);
    eval 'sub NAFC_RST_CLRD () {0x20;}' unless defined(&NAFC_RST_CLRD);
    eval 'sub ATIO_CDBLEN () {26;}' unless defined(&ATIO_CDBLEN);
    eval 'sub AT_NODISC () {0x00008000;}' unless defined(&AT_NODISC);
    eval 'sub AT_TQAE () {0x00000002;}' unless defined(&AT_TQAE);
    eval 'sub AT_PATH_INVALID () {0x07;}' unless defined(&AT_PATH_INVALID);
    eval 'sub AT_RESET () {0x0e;}' unless defined(&AT_RESET);
    eval 'sub AT_PHASE_ERROR () {0x14;}' unless defined(&AT_PHASE_ERROR);
    eval 'sub AT_NOCAP () {0x16;}' unless defined(&AT_NOCAP);
    eval 'sub AT_BDR_MSG () {0x17;}' unless defined(&AT_BDR_MSG);
    eval 'sub AT_CDB () {0x3d;}' unless defined(&AT_CDB);
    eval 'sub AT_MAKE_TAGID {
        local($tid, $aep) = @_;
	    eval q($tid = (($aep)-> &at_handle << 16);  &if (($aep)-> &at_flags &  &AT_TQAE) ($tid) |= (($aep)-> &at_tag_val + 1));
    }' unless defined(&AT_MAKE_TAGID);
    eval 'sub CT_MAKE_TAGID {
        local($tid, $ct) = @_;
	    eval q($tid = (($ct)-> &ct_fwhandle << 16);  &if (($ct)-> &ct_flags &  &CT_TQAE) ($tid) |= (($ct)-> &ct_tag_val + 1));
    }' unless defined(&CT_MAKE_TAGID);
    eval 'sub AT_HAS_TAG {
        local($val) = @_;
	    eval q((($val) & 0xffff));
    }' unless defined(&AT_HAS_TAG);
    eval 'sub AT_GET_TAG {
        local($val) = @_;
	    eval q( &AT_HAS_TAG($val) - 1);
    }' unless defined(&AT_GET_TAG);
    eval 'sub AT_GET_HANDLE {
        local($val) = @_;
	    eval q((($val) >> 16));
    }' unless defined(&AT_GET_HANDLE);
    eval 'sub ATIO2_CDBLEN () {16;}' unless defined(&ATIO2_CDBLEN);
    eval 'sub ATIO2_WWPN_OFFSET () {0x2a;}' unless defined(&ATIO2_WWPN_OFFSET);
    eval 'sub ATIO2_OXID_OFFSET () {0x3e;}' unless defined(&ATIO2_OXID_OFFSET);
    eval 'sub ATIO2_TC_ATTR_MASK () {0x7;}' unless defined(&ATIO2_TC_ATTR_MASK);
    eval 'sub ATIO2_TC_ATTR_SIMPLEQ () {0;}' unless defined(&ATIO2_TC_ATTR_SIMPLEQ);
    eval 'sub ATIO2_TC_ATTR_HEADOFQ () {1;}' unless defined(&ATIO2_TC_ATTR_HEADOFQ);
    eval 'sub ATIO2_TC_ATTR_ORDERED () {2;}' unless defined(&ATIO2_TC_ATTR_ORDERED);
    eval 'sub ATIO2_TC_ATTR_ACAQ () {4;}' unless defined(&ATIO2_TC_ATTR_ACAQ);
    eval 'sub ATIO2_TC_ATTR_UNTAGGED () {5;}' unless defined(&ATIO2_TC_ATTR_UNTAGGED);
    eval 'sub ct_syshandle () { &ct_reserved;}' unless defined(&ct_syshandle);
    eval 'sub GET_IID_VAL {
        local($x) = @_;
	    eval q(($x & 0x3f));
    }' unless defined(&GET_IID_VAL);
    eval 'sub GET_BUS_VAL {
        local($x) = @_;
	    eval q((($x >> 7) & 0x1));
    }' unless defined(&GET_BUS_VAL);
    eval 'sub SET_IID_VAL {
        local($y, $x) = @_;
	    eval q(($y | ($x & 0x3f)));
    }' unless defined(&SET_IID_VAL);
    eval 'sub SET_BUS_VAL {
        local($y, $x) = @_;
	    eval q(($y | (($x & 0x1) << 7)));
    }' unless defined(&SET_BUS_VAL);
    eval 'sub CT_TQAE () {0x00000002;}' unless defined(&CT_TQAE);
    eval 'sub CT_DATA_IN () {0x00000040;}' unless defined(&CT_DATA_IN);
    eval 'sub CT_DATA_OUT () {0x00000080;}' unless defined(&CT_DATA_OUT);
    eval 'sub CT_NO_DATA () {0x000000c0;}' unless defined(&CT_NO_DATA);
    eval 'sub CT_CCINCR () {0x00000100;}' unless defined(&CT_CCINCR);
    eval 'sub CT_DATAMASK () {0x000000c0;}' unless defined(&CT_DATAMASK);
    eval 'sub CT_INISYNCWIDE () {0x00004000;}' unless defined(&CT_INISYNCWIDE);
    eval 'sub CT_NODISC () {0x00008000;}' unless defined(&CT_NODISC);
    eval 'sub CT_DSDP () {0x01000000;}' unless defined(&CT_DSDP);
    eval 'sub CT_SENDRDP () {0x04000000;}' unless defined(&CT_SENDRDP);
    eval 'sub CT_SENDSTATUS () {0x80000000;}' unless defined(&CT_SENDSTATUS);
    eval 'sub CT_OK () {0x01;}' unless defined(&CT_OK);
    eval 'sub CT_ABORTED () {0x02;}' unless defined(&CT_ABORTED);
    eval 'sub CT_ERR () {0x04;}' unless defined(&CT_ERR);
    eval 'sub CT_INVAL () {0x06;}' unless defined(&CT_INVAL);
    eval 'sub CT_NOPATH () {0x07;}' unless defined(&CT_NOPATH);
    eval 'sub CT_INVRXID () {0x08;}' unless defined(&CT_INVRXID);
    eval 'sub CT_RSELTMO () {0x0a;}' unless defined(&CT_RSELTMO);
    eval 'sub CT_TIMEOUT () {0x0b;}' unless defined(&CT_TIMEOUT);
    eval 'sub CT_RESET () {0x0e;}' unless defined(&CT_RESET);
    eval 'sub CT_PARITY () {0x0f;}' unless defined(&CT_PARITY);
    eval 'sub CT_PANIC () {0x13;}' unless defined(&CT_PANIC);
    eval 'sub CT_PHASE_ERROR () {0x14;}' unless defined(&CT_PHASE_ERROR);
    eval 'sub CT_BDR_MSG () {0x17;}' unless defined(&CT_BDR_MSG);
    eval 'sub CT_TERMINATED () {0x19;}' unless defined(&CT_TERMINATED);
    eval 'sub CT_PORTNOTAVAIL () {0x28;}' unless defined(&CT_PORTNOTAVAIL);
    eval 'sub CT_LOGOUT () {0x29;}' unless defined(&CT_LOGOUT);
    eval 'sub CT_PORTCHANGED () {0x2a;}' unless defined(&CT_PORTCHANGED);
    eval 'sub CT_IDE () {0x33;}' unless defined(&CT_IDE);
    eval 'sub CT_NOACK () {0x35;}' unless defined(&CT_NOACK);
    eval 'sub CTIO_SENSE_OFFSET () {0x2e;}' unless defined(&CTIO_SENSE_OFFSET);
    eval 'sub UINT32_ENTRY_SIZE () {($sizeof{ &at_entry_t}/$sizeof{ &u_int32_t});}' unless defined(&UINT32_ENTRY_SIZE);
    eval 'sub MAXRESPLEN () {26;}' unless defined(&MAXRESPLEN);
    eval 'sub CT2_FLAG_MMASK () {0x0003;}' unless defined(&CT2_FLAG_MMASK);
    eval 'sub CT2_FLAG_MODE0 () {0x0000;}' unless defined(&CT2_FLAG_MODE0);
    eval 'sub CT2_FLAG_MODE1 () {0x0001;}' unless defined(&CT2_FLAG_MODE1);
    eval 'sub CT2_FLAG_MODE2 () {0x0002;}' unless defined(&CT2_FLAG_MODE2);
    eval 'sub CT2_DATA_IN () { &CT_DATA_IN;}' unless defined(&CT2_DATA_IN);
    eval 'sub CT2_DATA_OUT () { &CT_DATA_OUT;}' unless defined(&CT2_DATA_OUT);
    eval 'sub CT2_NO_DATA () { &CT_NO_DATA;}' unless defined(&CT2_NO_DATA);
    eval 'sub CT2_DATAMASK () { &CT_DATAMASK;}' unless defined(&CT2_DATAMASK);
    eval 'sub CT2_CCINCR () {0x0100;}' unless defined(&CT2_CCINCR);
    eval 'sub CT2_FASTPOST () {0x0200;}' unless defined(&CT2_FASTPOST);
    eval 'sub CT2_SENDSTATUS () {0x8000;}' unless defined(&CT2_SENDSTATUS);
    eval 'sub CT2_RSPLEN_VALID () {0x0100;}' unless defined(&CT2_RSPLEN_VALID);
    eval 'sub CT2_SNSLEN_VALID () {0x0200;}' unless defined(&CT2_SNSLEN_VALID);
    eval 'sub CT2_DATA_OVER () {0x0400;}' unless defined(&CT2_DATA_OVER);
    eval 'sub CT2_DATA_UNDER () {0x0800;}' unless defined(&CT2_DATA_UNDER);
    if(defined(&__sparc__)) {
	eval 'sub ISP_SBUS_SWOZZLE {
	    local($isp, $src, $dst, $taga, $tagb) = @_;
    	    eval q( &if ( ($isp->{isp_bustype}) ==  &ISP_BT_SBUS) {  &u_int8_t  &tmp = $src -> $taga; $dst -> $taga = $dst -> $tagb; $src -> $tagb =  &tmp; }  &else { $dst -> $taga = $src -> $taga; $dst -> $tagb = $src -> $taga; });
	}' unless defined(&ISP_SBUS_SWOZZLE);
    } else {
	eval 'sub ISP_SBUS_SWOZZLE {
	    local($isp, $src, $dst, $taga, $tagb) = @_;
    	    eval q($dst -> $taga = $src -> $taga; $dst -> $tagb = $src -> $taga);
	}' unless defined(&ISP_SBUS_SWOZZLE);
    }
    eval 'sub MCIDF {
        local($d, $s) = @_;
	    eval q( &if ( $d != $s)  &MEMCPY($d, $s,  &QENTRY_LEN));
    }' unless defined(&MCIDF);
    if(defined(&__sparc__)) {
	eval 'sub ISP_SWIZ_ATIO {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &at_entry_t * &src = $vsrc;  &at_entry_t * &dst = $vdst;  ($dst->{at_header}) =  ($src->{at_header});  ($dst->{at_reserved}) =  ($src->{at_reserved});  ($dst->{at_handle}) =  ($src->{at_handle});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &at_lun,  &at_iid);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &at_cdblen,  &at_tgt);  ($dst->{at_flags}) =  ($src->{at_flags});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &at_status,  &at_scsi_status);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &at_tag_val,  &at_tag_type);  &MEMCPY( ($dst->{at_cdb}),  ($src->{at_cdb}),  &ATIO_CDBLEN);  &MEMCPY( ($dst->{at_sense}),  ($src->{at_sense}),  &QLTM_SENSELEN); });
	}' unless defined(&ISP_SWIZ_ATIO);
	eval 'sub ISP_SWIZ_ATIO2 {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &at2_entry_t * &src = $vsrc;  &at2_entry_t * &dst = $vdst;  ($dst->{at_reserved}) =  ($src->{at_reserved});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &at_lun,  &at_iid);  ($dst->{at_rxid}) =  ($src->{at_rxid});  ($dst->{at_flags}) =  ($src->{at_flags});  ($dst->{at_status}) =  ($src->{at_status});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &at_reserved1,  &at_taskcodes);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &at_taskflags,  &at_execodes);  &MEMCPY( ($dst->{at_cdb}),  ($src->{at_cdb}),  &ATIO2_CDBLEN);  ($dst->{at_datalen}) =  ($src->{at_datalen});  ($dst->{at_scclun}) =  ($src->{at_scclun});  &MEMCPY( ($dst->{at_reserved2}),  ($src->{at_reserved2}),  &sizeof  ($dst->{at_reserved2}));  ($dst->{at_oxid}) =  ($src->{at_oxid}); });
	}' unless defined(&ISP_SWIZ_ATIO2);
	eval 'sub ISP_SWIZ_CTIO {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &ct_entry_t * &src = $vsrc;  &ct_entry_t * &dst = $vdst;  ($dst->{ct_header}) =  ($src->{ct_header});  ($dst->{ct_syshandle}) =  ($src->{ct_syshandle});  ($dst->{ct_fwhandle}) =  ($src->{ct_fwhandle});  ($dst->{ct_fwhandle}) =  ($src->{ct_fwhandle});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &ct_lun,  &ct_iid);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &ct_reserved2,  &ct_tgt);  ($dst->{ct_flags}) =  ($src->{ct_flags});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &ct_status,  &ct_scsi_status);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &ct_tag_val,  &ct_tag_type);  ($dst->{ct_xfrlen}) =  ($src->{ct_xfrlen});  ($dst->{ct_resid}) =  ($src->{ct_resid});  ($dst->{ct_timeout}) =  ($src->{ct_timeout});  ($dst->{ct_seg_count}) =  ($src->{ct_seg_count});  &MEMCPY( ($dst->{ct_dataseg}),  ($src->{ct_dataseg}), $sizeof{ ($dst->{ct_dataseg})}); });
	}' unless defined(&ISP_SWIZ_CTIO);
	eval 'sub ISP_SWIZ_CTIO2 {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &ct2_entry_t * &src = $vsrc;  &ct2_entry_t * &dst = $vdst;  ($dst->{ct_header}) =  ($src->{ct_header});  ($dst->{ct_syshandle}) =  ($src->{ct_syshandle});  ($dst->{ct_fwhandle}) =  ($src->{ct_fwhandle});  ($dst->{ct_fwhandle}) =  ($src->{ct_fwhandle});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &ct_lun,  &ct_iid);  ($dst->{ct_rxid}) =  ($src->{ct_rxid});  ($dst->{ct_flags}) =  ($src->{ct_flags});  ($dst->{ct_status}) =  ($src->{ct_status});  ($dst->{ct_timeout}) =  ($src->{ct_timeout});  ($dst->{ct_seg_count}) =  ($src->{ct_seg_count});  ($dst->{ct_reloff}) =  ($src->{ct_reloff});  ($dst->{ct_resid}) =  ($src->{ct_resid});  ($dst->{rsp}) =  ($src->{rsp}); });
	}' unless defined(&ISP_SWIZ_CTIO2);
	eval 'sub ISP_SWIZ_ENABLE_LUN {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &lun_entry_t * &src = $vsrc;  &lun_entry_t * &dst = $vdst;  ($dst->{le_header}) =  ($src->{le_header});  ($dst->{le_reserved2}) =  ($src->{le_reserved2});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &le_lun,  &le_rsvd);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &le_ops,  &le_tgt);  ($dst->{le_flags}) =  ($src->{le_flags});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &le_status,  &le_reserved2);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &le_cmd_count,  &le_in_count);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &le_cdb6len,  &le_cdb7len);  ($dst->{le_timeout}) =  ($src->{le_timeout});  ($dst->{le_reserved}) =  ($src->{le_reserved}); });
	}' unless defined(&ISP_SWIZ_ENABLE_LUN);
	eval 'sub ISP_SWIZ_NOTIFY {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &in_entry_type * &src = $vsrc;  &in_entry_type * &dst = $vdst;  ($dst->{in_header}) =  ($src->{in_header});  ($dst->{in_reserved2}) =  ($src->{in_reserved2});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &in_lun,  &in_iid);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &in_reserved2,  &in_tgt);  ($dst->{in_flags}) =  ($src->{in_flags});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &in_status,  &in_rsvd2);  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &in_tag_val,  &in_tag_type);  ($dst->{in_seqid}) =  ($src->{in_seqid});  &MEMCPY( ($dst->{in_msg}),  ($src->{in_msg}),  &IN_MSGLEN);  &MEMCPY( ($dst->{in_reserved}),  ($src->{in_reserved}),  &IN_RESERVED);  &MEMCPY( ($dst->{in_sense}),  ($src->{in_sense}),  &QLTM_SENSELEN); });
	}' unless defined(&ISP_SWIZ_NOTIFY);
	eval 'sub ISP_SWIZ_NOTIFY_FC {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &in_fcentry_type * &src = $vsrc;  &in_fcentry_type * &dst = $vdst;  ($dst->{in_header}) =  ($src->{in_header});  ($dst->{in_reserved2}) =  ($src->{in_reserved2});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &in_lun,  &in_iid);  ($dst->{in_scclun}) =  ($src->{in_scclun});  ($dst->{in_reserved2}) =  ($src->{in_reserved2});  ($dst->{in_status}) =  ($src->{in_status});  ($dst->{in_task_flags}) =  ($src->{in_task_flags});  ($dst->{in_seqid}) =  ($src->{in_seqid}); });
	}' unless defined(&ISP_SWIZ_NOTIFY_FC);
	eval 'sub ISP_SWIZ_NOT_ACK {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &na_entry_t * &src = $vsrc;  &na_entry_t * &dst = $vdst;  ($dst->{na_header}) =  ($src->{na_header});  ($dst->{na_reserved}) =  ($src->{na_reserved});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &na_lun,  &na_iid);  ($dst->{na_reserved2}) =  ($src->{na_reserved2});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &na_reserved,  &na_tgt);  ($dst->{na_flags}) =  ($src->{na_flags});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &na_status,  &na_event);  ($dst->{na_seqid}) =  ($src->{na_seqid});  &MEMCPY( ($dst->{na_reserved3}),  ($src->{na_reserved3}),  &NA_RSVDLEN); });
	}' unless defined(&ISP_SWIZ_NOT_ACK);
	eval 'sub ISP_SWIZ_NOT_ACK_FC {
	    local($isp, $vdst, $vsrc) = @_;
    	    eval q({  &na_fcentry_t * &src = $vsrc;  &na_fcentry_t * &dst = $vdst;  ($dst->{na_header}) =  ($src->{na_header});  ($dst->{na_reserved}) =  ($src->{na_reserved});  &ISP_SBUS_SWOZZLE($isp,  &src,  &dst,  &na_lun,  &na_iid);  ($dst->{na_scclun}) =  ($src->{na_scclun});  ($dst->{na_flags}) =  ($src->{na_flags});  ($dst->{na_reserved2}) =  ($src->{na_reserved2});  ($dst->{na_status}) =  ($src->{na_status});  ($dst->{na_task_flags}) =  ($src->{na_task_flags});  ($dst->{na_seqid}) =  ($src->{na_seqid});  &MEMCPY( ($dst->{na_reserved3}),  ($src->{na_reserved3}),  &NA2_RSVDLEN); });
	}' unless defined(&ISP_SWIZ_NOT_ACK_FC);
    } else {
	eval 'sub ISP_SWIZ_ATIO {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_ATIO);
	eval 'sub ISP_SWIZ_ATIO2 {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_ATIO2);
	eval 'sub ISP_SWIZ_CTIO {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_CTIO);
	eval 'sub ISP_SWIZ_CTIO2 {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_CTIO2);
	eval 'sub ISP_SWIZ_ENABLE_LUN {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_ENABLE_LUN);
	eval 'sub ISP_SWIZ_ATIO2 {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_ATIO2);
	eval 'sub ISP_SWIZ_CTIO2 {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_CTIO2);
	eval 'sub ISP_SWIZ_NOTIFY {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_NOTIFY);
	eval 'sub ISP_SWIZ_NOTIFY_FC {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_NOTIFY_FC);
	eval 'sub ISP_SWIZ_NOT_ACK {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_NOT_ACK);
	eval 'sub ISP_SWIZ_NOT_ACK_FC {
	    local($isp, $d, $s) = @_;
    	    eval q( &MCIDF($d, $s));
	}' unless defined(&ISP_SWIZ_NOT_ACK_FC);
    }
    eval 'sub ISP_TDQE {
        local($isp, $msg, $idx, $arg) = @_;
	    eval q( &if ( ($isp->{isp_dblev}) &  &ISP_LOGTDEBUG2)  &isp_print_qentry($isp, $msg, $idx, $arg));
    }' unless defined(&ISP_TDQE);
    eval 'sub DFLT_CMD_CNT () {32;}' unless defined(&DFLT_CMD_CNT);
    eval 'sub DFLT_INOTIFY () {(4);}' unless defined(&DFLT_INOTIFY);
    eval 'sub ECMD_SVALID () {0x100;}' unless defined(&ECMD_SVALID);
}
1;
