The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/dev/ic/isp_target.h

Version: -  FREEBSD  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-2  -  FREEBSD-11-1  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-4  -  FREEBSD-10-3  -  FREEBSD-10-2  -  FREEBSD-10-1  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-3  -  FREEBSD-9-2  -  FREEBSD-9-1  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-4  -  FREEBSD-8-3  -  FREEBSD-8-2  -  FREEBSD-8-1  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-4  -  FREEBSD-7-3  -  FREEBSD-7-2  -  FREEBSD-7-1  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-4  -  FREEBSD-6-3  -  FREEBSD-6-2  -  FREEBSD-6-1  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-5  -  FREEBSD-5-4  -  FREEBSD-5-3  -  FREEBSD-5-2  -  FREEBSD-5-1  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  linux-2.6  -  linux-2.4.22  -  MK83  -  MK84  -  PLAN9  -  DFBSD  -  NETBSD  -  NETBSD5  -  NETBSD4  -  NETBSD3  -  NETBSD20  -  OPENBSD  -  xnu-517  -  xnu-792  -  xnu-792.6.70  -  xnu-1228  -  xnu-1456.1.26  -  xnu-1699.24.8  -  xnu-2050.18.24  -  OPENSOLARIS  -  minix-3-1-1 
SearchContext: -  none  -  3  -  10 

    1 /*      $OpenBSD: isp_target.h,v 1.13 2008/11/02 02:01:47 krw Exp $     */
    2 /* $FreeBSD: src/sys/dev/isp/isp_target.h,v 1.30 2007/03/10 02:39:54 mjacob Exp $ */
    3 /*
    4  * Copyright (c) 1997, 1998
    5  * Patrick Stirling
    6  * pms@psconsult.com
    7  * All rights reserved.
    8  *
    9  * Redistribution and use in source and binary forms, with or without
   10  * modification, are permitted provided that the following conditions
   11  * are met:
   12  * 1. Redistributions of source code must retain the above copyright
   13  *    notice immediately at the beginning of the file, without modification,
   14  *    this list of conditions, and the following disclaimer.
   15  * 2. The name of the author may not be used to endorse or promote products
   16  *    derived from this software without specific prior written permission.
   17  *
   18  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
   19  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
   20  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
   21  * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE FOR
   22  * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
   23  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
   24  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
   25  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   26  * SUCH DAMAGE.
   27  */
   28 /*-
   29  *  Copyright (c) 1997-2007 by Matthew Jacob
   30  *  All rights reserved.
   31  * 
   32  *  Redistribution and use in source and binary forms, with or without
   33  *  modification, are permitted provided that the following conditions
   34  *  are met:
   35  * 
   36  *  1. Redistributions of source code must retain the above copyright
   37  *     notice, this list of conditions and the following disclaimer.
   38  *  2. Redistributions in binary form must reproduce the above copyright
   39  *     notice, this list of conditions and the following disclaimer in the
   40  *     documentation and/or other materials provided with the distribution.
   41  * 
   42  *  THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND
   43  *  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
   44  *  IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
   45  *  ARE DISCLAIMED.  IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE
   46  *  FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
   47  *  DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
   48  *  OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
   49  *  HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
   50  *  LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
   51  *  OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
   52  *  SUCH DAMAGE.
   53  */
   54 /*
   55  * QLogic Target Mode Structure and Flag Definitions
   56  */
   57 #ifndef _ISP_TARGET_H
   58 #define _ISP_TARGET_H
   59 
   60 #define QLTM_SENSELEN   18      /* non-FC cards only */
   61 #define QLTM_SVALID     0x80
   62 
   63 /*
   64  * Structure for Enable Lun and Modify Lun queue entries
   65  */
   66 typedef struct {
   67         isphdr_t        le_header;
   68         u_int32_t       le_reserved;
   69         u_int8_t        le_lun;
   70         u_int8_t        le_rsvd;
   71         u_int8_t        le_ops;         /* Modify LUN only */
   72         u_int8_t        le_tgt;         /* Not for FC */
   73         u_int32_t       le_flags;       /* Not for FC */
   74         u_int8_t        le_status;
   75         u_int8_t        le_reserved2;
   76         u_int8_t        le_cmd_count;
   77         u_int8_t        le_in_count;
   78         u_int8_t        le_cdb6len;     /* Not for FC */
   79         u_int8_t        le_cdb7len;     /* Not for FC */
   80         u_int16_t       le_timeout;
   81         u_int16_t       le_reserved3[20];
   82 } lun_entry_t;
   83 
   84 /*
   85  * le_flags values
   86  */
   87 #define LUN_TQAE        0x00000002      /* bit1  Tagged Queue Action Enable */
   88 #define LUN_DSSM        0x01000000      /* bit24 Disable Sending SDP Message */
   89 #define LUN_DISAD       0x02000000      /* bit25 Disable autodisconnect */
   90 #define LUN_DM          0x40000000      /* bit30 Disconnects Mandatory */
   91 
   92 /*
   93  * le_ops values
   94  */
   95 #define LUN_CCINCR      0x01    /* increment command count */
   96 #define LUN_CCDECR      0x02    /* decrement command count */
   97 #define LUN_ININCR      0x40    /* increment immed. notify count */
   98 #define LUN_INDECR      0x80    /* decrement immed. notify count */
   99 
  100 /*
  101  * le_status values
  102  */
  103 #define LUN_OK          0x01    /* we be rockin' */
  104 #define LUN_ERR         0x04    /* request completed with error */
  105 #define LUN_INVAL       0x06    /* invalid request */
  106 #define LUN_NOCAP       0x16    /* can't provide requested capability */
  107 #define LUN_ENABLED     0x3E    /* LUN already enabled */
  108 
  109 /*
  110  * Immediate Notify Entry structure
  111  */
  112 #define IN_MSGLEN       8       /* 8 bytes */
  113 #define IN_RSVDLEN      8       /* 8 words */
  114 typedef struct {
  115         isphdr_t        in_header;
  116         u_int32_t       in_reserved;
  117         u_int8_t        in_lun;         /* lun */
  118         u_int8_t        in_iid;         /* initiator */
  119         u_int8_t        in_reserved2;
  120         u_int8_t        in_tgt;         /* target */
  121         u_int32_t       in_flags;
  122         u_int8_t        in_status;
  123         u_int8_t        in_rsvd2;
  124         u_int8_t        in_tag_val;     /* tag value */
  125         u_int8_t        in_tag_type;    /* tag type */
  126         u_int16_t       in_seqid;       /* sequence id */
  127         u_int8_t        in_msg[IN_MSGLEN];      /* SCSI message bytes */
  128         u_int16_t       in_reserved3[IN_RSVDLEN];
  129         u_int8_t        in_sense[QLTM_SENSELEN];/* suggested sense data */
  130 } in_entry_t;
  131 
  132 typedef struct {
  133         isphdr_t        in_header;
  134         u_int32_t       in_reserved;
  135         u_int8_t        in_lun;         /* lun */
  136         u_int8_t        in_iid;         /* initiator */
  137         u_int16_t       in_scclun;
  138         u_int32_t       in_reserved2;
  139         u_int16_t       in_status;
  140         u_int16_t       in_task_flags;
  141         u_int16_t       in_seqid;       /* sequence id */
  142 } in_fcentry_t;
  143 
  144 typedef struct {
  145         isphdr_t        in_header;
  146         u_int32_t       in_reserved;
  147         u_int16_t       in_iid;         /* initiator */
  148         u_int16_t       in_scclun;
  149         u_int32_t       in_reserved2;
  150         u_int16_t       in_status;
  151         u_int16_t       in_task_flags;
  152         u_int16_t       in_seqid;       /* sequence id */
  153 } in_fcentry_e_t;
  154 
  155 /*
  156  * Values for the in_status field
  157  */
  158 #define IN_REJECT       0x0D    /* Message Reject message received */
  159 #define IN_RESET        0x0E    /* Bus Reset occurred */
  160 #define IN_NO_RCAP      0x16    /* requested capability not available */
  161 #define IN_IDE_RECEIVED 0x33    /* Initiator Detected Error msg received */
  162 #define IN_RSRC_UNAVAIL 0x34    /* resource unavailable */
  163 #define IN_MSG_RECEIVED 0x36    /* SCSI message received */
  164 #define IN_ABORT_TASK   0x20    /* task named in RX_ID is being aborted (FC) */
  165 #define IN_PORT_LOGOUT  0x29    /* port has logged out (FC) */
  166 #define IN_PORT_CHANGED 0x2A    /* port changed */
  167 #define IN_GLOBAL_LOGO  0x2E    /* all ports logged out */
  168 #define IN_NO_NEXUS     0x3B    /* Nexus not established */
  169 
  170 /*
  171  * Values for the in_task_flags field- should only get one at a time!
  172  */
  173 #define TASK_FLAGS_ABORT_TASK           (1<<9)
  174 #define TASK_FLAGS_CLEAR_TASK_SET       (1<<10)
  175 #define TASK_FLAGS_TARGET_RESET         (1<<13)
  176 #define TASK_FLAGS_RESERVED_MASK        (0xe700)
  177 #define TASK_FLAGS_CLEAR_ACA            (1<<14)
  178 #define TASK_FLAGS_TERMINATE_TASK       (1<<15)
  179 #define TASK_FLAGS_TARGET_RESET         (1<<13)
  180 #define TASK_FLAGS_LUN_RESET            (1<<12)
  181 #define TASK_FLAGS_CLEAR_TASK_SET       (1<<10)
  182 #define TASK_FLAGS_ABORT_TASK_SET       (1<<9)
  183 
  184 #ifndef MSG_ABORT_TAG
  185 #define MSG_ABORT_TAG           0x06
  186 #endif
  187 #ifndef MSG_CLEAR_QUEUE
  188 #define MSG_CLEAR_QUEUE         0x0e
  189 #endif
  190 #ifndef MSG_BUS_DEV_RESET
  191 #define MSG_BUS_DEV_RESET       0x0b
  192 #endif
  193 #ifndef MSG_REL_RECOVERY
  194 #define MSG_REL_RECOVERY        0x10
  195 #endif
  196 #ifndef MSG_TERM_IO_PROC
  197 #define MSG_TERM_IO_PROC        0x11
  198 #endif
  199 
  200 /*
  201  * ISP24XX Immediate Notify
  202  */
  203 typedef struct {
  204         isphdr_t        in_header;
  205         u_int32_t       in_reserved;
  206         u_int16_t       in_nphdl;
  207         u_int16_t       in_reserved1;
  208         u_int16_t       in_flags;
  209         u_int16_t       in_srr_rxid;
  210         u_int16_t       in_status;
  211         u_int8_t        in_status_subcode;
  212         u_int8_t        in_reserved2;
  213         u_int32_t       in_rxid;
  214         u_int16_t       in_srr_reloff_lo;
  215         u_int16_t       in_srr_reloff_hi;
  216         u_int16_t       in_srr_iu;
  217         u_int16_t       in_srr_oxid;
  218         u_int8_t        in_reserved3[18];
  219         u_int8_t        in_reserved4;
  220         u_int8_t        in_vpindex;
  221         u_int32_t       in_reserved5;
  222         u_int16_t       in_portid_lo;
  223         u_int8_t        in_portid_hi;
  224         u_int8_t        in_reserved6;
  225         u_int16_t       in_reserved7;
  226         u_int16_t       in_oxid;
  227 } in_fcentry_24xx_t;
  228 
  229 #define IN24XX_FLAG_PUREX_IOCB          0x1
  230 #define IN24XX_FLAG_GLOBAL_LOGOUT       0x2
  231 
  232 #define IN24XX_LIP_RESET        0x0E
  233 #define IN24XX_LINK_RESET       0x0F
  234 #define IN24XX_PORT_LOGOUT      0x29
  235 #define IN24XX_PORT_CHANGED     0x2A
  236 #define IN24XX_LINK_FAILED      0x2E
  237 #define IN24XX_SRR_RCVD         0x45
  238 #define IN24XX_ELS_RCVD         0x46    /*
  239                                          * login-affectin ELS received- check
  240                                          * subcode for specific opcode
  241                                          */
  242 /*
  243  * Notify Acknowledge Entry structure
  244  */
  245 #define NA_RSVDLEN      22
  246 typedef struct {
  247         isphdr_t        na_header;
  248         u_int32_t       na_reserved;
  249         u_int8_t        na_lun;         /* lun */
  250         u_int8_t        na_iid;         /* initiator */
  251         u_int8_t        na_reserved2;
  252         u_int8_t        na_tgt;         /* target */
  253         u_int32_t       na_flags;
  254         u_int8_t        na_status;
  255         u_int8_t        na_event;
  256         u_int16_t       na_seqid;       /* sequence id */
  257         u_int16_t       na_reserved3[NA_RSVDLEN];
  258 } na_entry_t;
  259 
  260 /*
  261  * Value for the na_event field
  262  */
  263 #define NA_RST_CLRD     0x80    /* Clear an async event notification */
  264 #define NA_OK           0x01    /* Notify Acknowledge Succeeded */
  265 #define NA_INVALID      0x06    /* Invalid Notify Acknowledge */
  266 
  267 #define NA2_RSVDLEN     21
  268 typedef struct {
  269         isphdr_t        na_header;
  270         u_int32_t       na_reserved;
  271         u_int8_t        na_lun;         /* lun */
  272         u_int8_t        na_iid;         /* initiator */
  273         u_int16_t       na_scclun;
  274         u_int16_t       na_flags;
  275         u_int16_t       na_reserved2;
  276         u_int16_t       na_status;
  277         u_int16_t       na_task_flags;
  278         u_int16_t       na_seqid;       /* sequence id */
  279         u_int16_t       na_reserved3[NA2_RSVDLEN];
  280 } na_fcentry_t;
  281 
  282 typedef struct {
  283         isphdr_t        na_header;
  284         u_int32_t       na_reserved;
  285         u_int16_t       na_iid;         /* initiator loop id */
  286         u_int16_t       na_response;    /* response code */
  287         u_int16_t       na_flags;
  288         u_int16_t       na_reserved2;
  289         u_int16_t       na_status;
  290         u_int16_t       na_task_flags;
  291         u_int16_t       na_seqid;       /* sequence id */
  292         u_int16_t       na_reserved3[NA2_RSVDLEN];
  293 } na_fcentry_e_t;
  294 
  295 #define NAFC_RCOUNT     0x80    /* increment resource count */
  296 #define NAFC_RST_CLRD   0x20    /* Clear LIP Reset */
  297 #define NAFC_TVALID     0x10    /* task mangement response code is valid */
  298 
  299 /*
  300  * ISP24XX Notify Acknowledge
  301  */
  302 
  303 typedef struct {
  304         isphdr_t        na_header;
  305         u_int32_t       na_handle;
  306         u_int16_t       na_nphdl;
  307         u_int16_t       na_reserved1;
  308         u_int16_t       na_flags;
  309         u_int16_t       na_srr_rxid;
  310         u_int16_t       na_status;
  311         u_int8_t        na_status_subcode;
  312         u_int8_t        na_reserved2;
  313         u_int32_t       na_rxid;
  314         u_int16_t       na_srr_reloff_lo;
  315         u_int16_t       na_srr_reloff_hi;
  316         u_int16_t       na_srr_iu;
  317         u_int16_t       na_srr_flags;
  318         u_int8_t        na_reserved3[18];
  319         u_int8_t        na_reserved4;
  320         u_int8_t        na_vpindex;
  321         u_int8_t        na_srr_reject_vunique;
  322         u_int8_t        na_srr_reject_explanation;
  323         u_int8_t        na_srr_reject_code;
  324         u_int8_t        na_reserved5;
  325         u_int8_t        na_reserved6[6];
  326         u_int16_t       na_oxid;
  327 } na_fcentry_24xx_t;
  328 
  329 /*
  330  * Accept Target I/O Entry structure
  331  */
  332 #define ATIO_CDBLEN     26
  333 
  334 typedef struct {
  335         isphdr_t        at_header;
  336         u_int16_t       at_reserved;
  337         u_int16_t       at_handle;
  338         u_int8_t        at_lun;         /* lun */
  339         u_int8_t        at_iid;         /* initiator */
  340         u_int8_t        at_cdblen;      /* cdb length */
  341         u_int8_t        at_tgt;         /* target */
  342         u_int32_t       at_flags;
  343         u_int8_t        at_status;      /* firmware status */
  344         u_int8_t        at_scsi_status; /* scsi status */
  345         u_int8_t        at_tag_val;     /* tag value */
  346         u_int8_t        at_tag_type;    /* tag type */
  347         u_int8_t        at_cdb[ATIO_CDBLEN];    /* received CDB */
  348         u_int8_t        at_sense[QLTM_SENSELEN];/* suggested sense data */
  349 } at_entry_t;
  350 
  351 /*
  352  * at_flags values
  353  */
  354 #define AT_NODISC       0x00008000      /* disconnect disabled */
  355 #define AT_TQAE         0x00000002      /* Tagged Queue Action enabled */
  356 
  357 /*
  358  * at_status values
  359  */
  360 #define AT_PATH_INVALID 0x07    /* ATIO sent to firmware for disabled lun */
  361 #define AT_RESET        0x0E    /* SCSI Bus Reset Occurred */
  362 #define AT_PHASE_ERROR  0x14    /* Bus phase sequence error */
  363 #define AT_NOCAP        0x16    /* Requested capability not available */
  364 #define AT_BDR_MSG      0x17    /* Bus Device Reset msg received */
  365 #define AT_CDB          0x3D    /* CDB received */
  366 /*
  367  * Macros to create and fetch and test concatenated handle and tag value macros
  368  */
  369 
  370 #define AT_MAKE_TAGID(tid, aep)                                         \
  371         tid = ((aep)->at_handle << 16);                                 \
  372         if ((aep)->at_flags & AT_TQAE)                                  \
  373                 (tid) |= ((aep)->at_tag_val + 1)
  374 
  375 #define CT_MAKE_TAGID(tid, ct)                                          \
  376         tid = ((ct)->ct_fwhandle << 16);                                \
  377         if ((ct)->ct_flags & CT_TQAE)                                   \
  378                 (tid) |= ((ct)->ct_tag_val + 1)
  379 
  380 #define AT_HAS_TAG(val)         ((val) & 0xffff)
  381 #define AT_GET_TAG(val)         AT_HAS_TAG(val) - 1
  382 #define AT_GET_INST(val)        (((val) >> 26) & 0x3f)
  383 #define AT_GET_BUS(val)         (((val) >> 25) & 0x1)
  384 #define AT_GET_HANDLE(val)      ((val) >> 16)
  385 
  386 #define IN_MAKE_TAGID(tid, bus, inst, inp)                              \
  387         tid = inp->in_seqid;                                            \
  388         tid |= (inp->in_tag_val << 16);                                 \
  389         tid |= (1 << 24);                                               \
  390         tid |= (bus << 25);                                             \
  391         tid |= (inst << 26)
  392 
  393 #define TAG_INSERT_INST(tid, inst)                                      \
  394         tid &= ~(0x3ffffff);                                            \
  395         tid |= (inst << 26)
  396 
  397 #define TAG_INSERT_BUS(tid, bus)                                        \
  398         tid &= ~(1 << 25);                                              \
  399         tid |= (bus << 25)
  400 
  401 /*
  402  * Accept Target I/O Entry structure, Type 2
  403  */
  404 #define ATIO2_CDBLEN    16
  405 
  406 typedef struct {
  407         isphdr_t        at_header;
  408         u_int32_t       at_reserved;
  409         u_int8_t        at_lun;         /* lun or reserved */
  410         u_int8_t        at_iid;         /* initiator */
  411         u_int16_t       at_rxid;        /* response ID */
  412         u_int16_t       at_flags;
  413         u_int16_t       at_status;      /* firmware status */
  414         u_int8_t        at_reserved1;
  415         u_int8_t        at_taskcodes;
  416         u_int8_t        at_taskflags;
  417         u_int8_t        at_execodes;
  418         u_int8_t        at_cdb[ATIO2_CDBLEN];   /* received CDB */
  419         u_int32_t       at_datalen;             /* allocated data len */
  420         u_int16_t       at_scclun;              /* SCC Lun or reserved */
  421         u_int16_t       at_wwpn[4];             /* WWPN of initiator */
  422         u_int16_t       at_reserved2[6];
  423         u_int16_t       at_oxid;
  424 } at2_entry_t;
  425 
  426 typedef struct {
  427         isphdr_t        at_header;
  428         u_int32_t       at_reserved;
  429         u_int16_t       at_iid;         /* initiator */
  430         u_int16_t       at_rxid;        /* response ID */
  431         u_int16_t       at_flags;
  432         u_int16_t       at_status;      /* firmware status */
  433         u_int8_t        at_crn;         /* command reference number */
  434         u_int8_t        at_taskcodes;
  435         u_int8_t        at_taskflags;
  436         u_int8_t        at_execodes;
  437         u_int8_t        at_cdb[ATIO2_CDBLEN];   /* received CDB */
  438         u_int32_t       at_datalen;             /* allocated data len */
  439         u_int16_t       at_scclun;              /* SCC Lun or reserved */
  440         u_int16_t       at_wwpn[4];             /* WWPN of initiator */
  441         u_int16_t       at_reserved2[6];
  442         u_int16_t       at_oxid;
  443 } at2e_entry_t;
  444 
  445 #define ATIO2_WWPN_OFFSET       0x2A
  446 #define ATIO2_OXID_OFFSET       0x3E
  447 
  448 #define ATIO2_TC_ATTR_MASK      0x7
  449 #define ATIO2_TC_ATTR_SIMPLEQ   0
  450 #define ATIO2_TC_ATTR_HEADOFQ   1
  451 #define ATIO2_TC_ATTR_ORDERED   2
  452 #define ATIO2_TC_ATTR_ACAQ      4
  453 #define ATIO2_TC_ATTR_UNTAGGED  5
  454 
  455 #define ATIO2_EX_WRITE          0x1
  456 #define ATIO2_EX_READ           0x2
  457 /*
  458  * Macros to create and fetch and test concatenated handle and tag value macros
  459  */
  460 #define AT2_MAKE_TAGID(tid, bus, inst, aep)                             \
  461         tid = aep->at_rxid;                                             \
  462         tid |= (((u_int64_t)inst) << 32);                               \
  463         tid |= (((u_int64_t)bus) << 48)
  464 
  465 #define CT2_MAKE_TAGID(tid, bus, inst, ct)                              \
  466         tid = ct->ct_rxid;                                              \
  467         tid |= (((u_int64_t)inst) << 32);                               \
  468         tid |= (((u_int64_t)(bus & 0xff)) << 48)
  469 
  470 #define AT2_HAS_TAG(val)        1
  471 #define AT2_GET_TAG(val)        ((val) & 0xffffffff)
  472 #define AT2_GET_INST(val)       ((val) >> 32)
  473 #define AT2_GET_HANDLE          AT2_GET_TAG
  474 #define AT2_GET_BUS(val)        (((val) >> 48) & 0xff)
  475 
  476 #define FC_HAS_TAG      AT2_HAS_TAG
  477 #define FC_GET_TAG      AT2_GET_TAG
  478 #define FC_GET_INST     AT2_GET_INST
  479 #define FC_GET_HANDLE   AT2_GET_HANDLE
  480 
  481 #define IN_FC_MAKE_TAGID(tid, bus, inst, seqid)                         \
  482         tid = seqid;                                                    \
  483         tid |= (((u_int64_t)inst) << 32);                               \
  484         tid |= (((u_int64_t)(bus & 0xff)) << 48)
  485 
  486 #define FC_TAG_INSERT_INST(tid, inst)                                   \
  487         tid &= ~0xffff00000000ull;                                      \
  488         tid |= (((u_int64_t)inst) << 32)
  489 
  490 /*
  491  * 24XX ATIO Definition
  492  *
  493  * This is *quite* different from other entry types.
  494  * First of all, it has its own queue it comes in on.
  495  *
  496  * Secondly, it doesn't have a normal header.
  497  *
  498  * Thirdly, it's just a passthru of the FCP CMND IU
  499  * which is recorded in big endian mode.
  500  */
  501 typedef struct {
  502         u_int8_t        at_type;
  503         u_int8_t        at_count;
  504         /*
  505          * Task attribute in high four bits,
  506          * the rest is the FCP CMND IU Length.
  507          * NB: the command can extend past the
  508          * length for a single queue entry.
  509          */
  510         u_int16_t       at_ta_len;
  511         u_int32_t       at_rxid;
  512         fc_hdr_t        at_hdr;
  513         fcp_cmnd_iu_t   at_cmnd;
  514 } at7_entry_t;
  515 
  516 
  517 /*
  518  * Continue Target I/O Entry structure
  519  * Request from driver. The response from the
  520  * ISP firmware is the same except that the last 18
  521  * bytes are overwritten by suggested sense data if
  522  * the 'autosense valid' bit is set in the status byte.
  523  */
  524 typedef struct {
  525         isphdr_t        ct_header;
  526         u_int16_t       ct_reserved;
  527 #define ct_syshandle    ct_reserved     /* we use this */
  528         u_int16_t       ct_fwhandle;    /* required by f/w */
  529         u_int8_t        ct_lun; /* lun */
  530         u_int8_t        ct_iid; /* initiator id */
  531         u_int8_t        ct_reserved2;
  532         u_int8_t        ct_tgt; /* our target id */
  533         u_int32_t       ct_flags;
  534         u_int8_t        ct_status;      /* isp status */
  535         u_int8_t        ct_scsi_status; /* scsi status */
  536         u_int8_t        ct_tag_val;     /* tag value */
  537         u_int8_t        ct_tag_type;    /* tag type */
  538         u_int32_t       ct_xfrlen;      /* transfer length */
  539         u_int32_t       ct_resid;       /* residual length */
  540         u_int16_t       ct_timeout;
  541         u_int16_t       ct_seg_count;
  542         /*
  543          * This is so we can share tag name space with
  544          * CTIO{2,3,4} with the minimum of pain.
  545          */
  546         union {
  547                 ispds_t         ct_a[ISP_RQDSEG];
  548         } _u;
  549 #define ct_dataseg      _u.ct_a
  550 } ct_entry_t;
  551 
  552 /*
  553  * For some of the dual port SCSI adapters, port (bus #) is reported
  554  * in the MSbit of ct_iid. Bit fields are a bit too awkward here.
  555  *
  556  * Note that this does not apply to FC adapters at all which can and
  557  * do report IIDs between 0x81 && 0xfe (or 0x7ff) which represent devices
  558  * that have logged in across a SCSI fabric.
  559  */
  560 #define GET_IID_VAL(x)          (x & 0x3f)
  561 #define GET_BUS_VAL(x)          ((x >> 7) & 0x1)
  562 #define SET_IID_VAL(y, x)       y = ((y & ~0x3f) | (x & 0x3f))
  563 #define SET_BUS_VAL(y, x)       y = ((y & 0x3f) | ((x & 0x1) << 7))
  564 
  565 /*
  566  * ct_flags values
  567  */
  568 #define CT_TQAE         0x00000002      /* bit  1, Tagged Queue Action enable */
  569 #define CT_DATA_IN      0x00000040      /* bits 6&7, Data direction */
  570 #define CT_DATA_OUT     0x00000080      /* bits 6&7, Data direction */
  571 #define CT_NO_DATA      0x000000C0      /* bits 6&7, Data direction */
  572 #define CT_CCINCR       0x00000100      /* bit 8, autoincrement atio count */
  573 #define CT_DATAMASK     0x000000C0      /* bits 6&7, Data direction */
  574 #define CT_INISYNCWIDE  0x00004000      /* bit 14, Do Sync/Wide Negotiation */
  575 #define CT_NODISC       0x00008000      /* bit 15, Disconnects disabled */
  576 #define CT_DSDP         0x01000000      /* bit 24, Disable Save Data Pointers */
  577 #define CT_SENDRDP      0x04000000      /* bit 26, Send Restore Pointers msg */
  578 #define CT_SENDSTATUS   0x80000000      /* bit 31, Send SCSI status byte */
  579 
  580 /*
  581  * ct_status values
  582  * - set by the firmware when it returns the CTIO
  583  */
  584 #define CT_OK           0x01    /* completed without error */
  585 #define CT_ABORTED      0x02    /* aborted by host */
  586 #define CT_ERR          0x04    /* see sense data for error */
  587 #define CT_INVAL        0x06    /* request for disabled lun */
  588 #define CT_NOPATH       0x07    /* invalid ITL nexus */
  589 #define CT_INVRXID      0x08    /* (FC only) Invalid RX_ID */
  590 #define CT_DATA_OVER    0x09    /* (FC only) Data Overrun */
  591 #define CT_RSELTMO      0x0A    /* reselection timeout after 2 tries */
  592 #define CT_TIMEOUT      0x0B    /* timed out */
  593 #define CT_RESET        0x0E    /* SCSI Bus Reset occurred */
  594 #define CT_PARITY       0x0F    /* Uncorrectable Parity Error */
  595 #define CT_BUS_ERROR    0x10    /* (FC Only) DMA PCI Error */
  596 #define CT_PANIC        0x13    /* Unrecoverable Error */
  597 #define CT_PHASE_ERROR  0x14    /* Bus phase sequence error */
  598 #define CT_DATA_UNDER   0x15    /* (FC only) Data Underrun */
  599 #define CT_BDR_MSG      0x17    /* Bus Device Reset msg received */
  600 #define CT_TERMINATED   0x19    /* due to Terminate Transfer mbox cmd */
  601 #define CT_PORTNOTAVAIL 0x28    /* port not available */
  602 #define CT_LOGOUT       0x29    /* port logout */
  603 #define CT_PORTCHANGED  0x2A    /* port changed */
  604 #define CT_IDE          0x33    /* Initiator Detected Error */
  605 #define CT_NOACK        0x35    /* Outstanding Immed. Notify. entry */
  606 #define CT_SRR          0x45    /* SRR Received */
  607 #define CT_LUN_RESET    0x48    /* Lun Reset Received */
  608 
  609 /*
  610  * When the firmware returns a CTIO entry, it may overwrite the last
  611  * part of the structure with sense data. This starts at offset 0x2E
  612  * into the entry, which is in the middle of ct_dataseg[1]. Rather
  613  * than define a new struct for this, I'm just using the sense data
  614  * offset.
  615  */
  616 #define CTIO_SENSE_OFFSET       0x2E
  617 
  618 /*
  619  * Entry length in u_longs. All entries are the same size so
  620  * any one will do as the numerator.
  621  */
  622 #define UINT32_ENTRY_SIZE       (sizeof(at_entry_t)/sizeof(u_int32_t))
  623 
  624 /*
  625  * QLA2100 CTIO (type 2) entry
  626  */
  627 #define MAXRESPLEN      26
  628 typedef struct {
  629         isphdr_t        ct_header;
  630         u_int16_t       ct_reserved;
  631         u_int16_t       ct_fwhandle;    /* just to match CTIO */
  632         u_int8_t        ct_lun;         /* lun */
  633         u_int8_t        ct_iid;         /* initiator id */
  634         u_int16_t       ct_rxid;        /* response ID */
  635         u_int16_t       ct_flags;
  636         u_int16_t       ct_status;      /* isp status */
  637         u_int16_t       ct_timeout;
  638         u_int16_t       ct_seg_count;
  639         u_int32_t       ct_reloff;      /* relative offset */
  640         int32_t         ct_resid;       /* residual length */
  641         union {
  642                 /*
  643                  * The three different modes that the target driver
  644                  * can set the CTIO{2,3,4} up as.
  645                  *
  646                  * The first is for sending FCP_DATA_IUs as well as
  647                  * (optionally) sending a terminal SCSI status FCP_RSP_IU.
  648                  *
  649                  * The second is for sending SCSI sense data in an FCP_RSP_IU.
  650                  * Note that no FCP_DATA_IUs will be sent.
  651                  *
  652                  * The third is for sending FCP_RSP_IUs as built specifically
  653                  * in system memory as located by the isp_dataseg.
  654                  */
  655                 struct {
  656                         u_int32_t _reserved;
  657                         u_int16_t _reserved2;
  658                         u_int16_t ct_scsi_status;
  659                         u_int32_t ct_xfrlen;
  660                         union {
  661                                 ispds_t ct_a[ISP_RQDSEG_T2];    /* CTIO2 */
  662                                 ispds64_t ct_b[ISP_RQDSEG_T3];  /* CTIO3 */
  663                                 ispdslist_t ct_c;               /* CTIO4 */
  664                         } _u;
  665 #define ct_dataseg      _u.ct_a
  666 #define ct_dataseg64    _u.ct_b
  667 #define ct_dslist       _u.ct_c
  668                 } m0;
  669                 struct {
  670                         u_int16_t _reserved;
  671                         u_int16_t _reserved2;
  672                         u_int16_t ct_senselen;
  673                         u_int16_t ct_scsi_status;
  674                         u_int16_t ct_resplen;
  675                         u_int8_t  ct_resp[MAXRESPLEN];
  676                 } m1;
  677                 struct {
  678                         u_int32_t _reserved;
  679                         u_int16_t _reserved2;
  680                         u_int16_t _reserved3;
  681                         u_int32_t ct_datalen;
  682                         ispds_t ct_fcp_rsp_iudata;
  683                 } m2;
  684                 /*
  685                  * CTIO2 returned from F/W...
  686                  */
  687                 struct {
  688                         u_int32_t _reserved[4];
  689                         u_int16_t ct_scsi_status;
  690                         u_int8_t  ct_sense[QLTM_SENSELEN];
  691                 } fw;
  692         } rsp;
  693 } ct2_entry_t;
  694 
  695 typedef struct {
  696         isphdr_t        ct_header;
  697         u_int32_t       ct_syshandle;
  698         u_int16_t       ct_iid;         /* initiator id */
  699         u_int16_t       ct_rxid;        /* response ID */
  700         u_int16_t       ct_flags;
  701         u_int16_t       ct_status;      /* isp status */
  702         u_int16_t       ct_timeout;
  703         u_int16_t       ct_seg_count;
  704         u_int32_t       ct_reloff;      /* relative offset */
  705         int32_t         ct_resid;       /* residual length */
  706         union {
  707                 struct {
  708                         u_int32_t _reserved;
  709                         u_int16_t _reserved2;
  710                         u_int16_t ct_scsi_status;
  711                         u_int32_t ct_xfrlen;
  712                         union {
  713                                 ispds_t ct_dataseg[ISP_RQDSEG_T2];
  714                                 ispds64_t ct_dataseg64[ISP_RQDSEG_T3];
  715                                 ispdslist_t ct_dslist;
  716                         } u;
  717                 } m0;
  718                 struct {
  719                         u_int16_t _reserved;
  720                         u_int16_t _reserved2;
  721                         u_int16_t ct_senselen;
  722                         u_int16_t ct_scsi_status;
  723                         u_int16_t ct_resplen;
  724                         u_int8_t  ct_resp[MAXRESPLEN];
  725                 } m1;
  726                 struct {
  727                         u_int32_t _reserved;
  728                         u_int16_t _reserved2;
  729                         u_int16_t _reserved3;
  730                         u_int32_t ct_datalen;
  731                         ispds_t ct_fcp_rsp_iudata;
  732                 } m2;
  733         } rsp;
  734 } ct2e_entry_t;
  735 
  736 /*
  737  * ct_flags values for CTIO2
  738  */
  739 #define CT2_FLAG_MODE0  0x0000
  740 #define CT2_FLAG_MODE1  0x0001
  741 #define CT2_FLAG_MODE2  0x0002
  742 #define         CT2_FLAG_MMASK  0x0003
  743 #define CT2_DATA_IN     CT_DATA_IN
  744 #define CT2_DATA_OUT    CT_DATA_OUT
  745 #define CT2_NO_DATA     CT_NO_DATA
  746 #define CT2_DATAMASK    CT_DATAMASK
  747 #define CT2_CCINCR      0x0100
  748 #define CT2_FASTPOST    0x0200
  749 #define CT2_CONFIRM     0x2000
  750 #define CT2_TERMINATE   0x4000
  751 #define CT2_SENDSTATUS  0x8000
  752 
  753 /*
  754  * ct_status values are (mostly) the same as that for ct_entry.
  755  */
  756 
  757 /*
  758  * ct_scsi_status values- the low 8 bits are the normal SCSI status
  759  * we know and love. The upper 8 bits are validity markers for FCP_RSP_IU
  760  * fields.
  761  */
  762 #define CT2_RSPLEN_VALID        0x0100
  763 #define CT2_SNSLEN_VALID        0x0200
  764 #define CT2_DATA_OVER           0x0400
  765 #define CT2_DATA_UNDER          0x0800
  766 
  767 /*
  768  * ISP24XX CTIO
  769  */
  770 #define MAXRESPLEN_24XX 24
  771 typedef struct {
  772         isphdr_t        ct_header;
  773         u_int32_t       ct_syshandle;
  774         u_int16_t       ct_nphdl;       /* status on returned CTIOs */
  775         u_int16_t       ct_timeout;
  776         u_int16_t       ct_seg_count;
  777         u_int8_t        ct_vpindex;
  778         u_int8_t        ct_xflags;
  779         u_int16_t       ct_iid_lo;      /* low 16 bits of portid */
  780         u_int8_t        ct_iid_hi;      /* hi 8 bits of portid */
  781         u_int8_t        ct_reserved;
  782         u_int32_t       ct_rxid;
  783         u_int16_t       ct_senselen;    /* mode 0 only */
  784         u_int16_t       ct_flags;
  785         int32_t         ct_resid;       /* residual length */
  786         u_int16_t       ct_oxid;
  787         u_int16_t       ct_scsi_status; /* modes 0 && 1 only */
  788         union {
  789                 struct {
  790                         u_int32_t       reloff;
  791                         u_int32_t       reserved0;
  792                         u_int32_t       ct_xfrlen;
  793                         u_int32_t       reserved1;
  794                         ispds64_t       ds;
  795                 } m0;
  796                 struct {
  797                         u_int16_t ct_resplen;
  798                         u_int16_t reserved;
  799                         u_int8_t  ct_resp[MAXRESPLEN_24XX];
  800                 } m1;
  801                 struct {
  802                         u_int32_t reserved0;
  803                         u_int32_t ct_datalen;
  804                         u_int32_t reserved1;
  805                         ispds64_t ct_fcp_rsp_iudata;
  806                 } m2;
  807         } rsp;
  808 } ct7_entry_t;
  809 
  810 /*
  811  * ct_flags values for CTIO7
  812  */
  813 #define CT7_DATA_IN     0x0002
  814 #define CT7_DATA_OUT    0x0001
  815 #define CT7_NO_DATA     0x0000
  816 #define         CT7_DATAMASK    0x003
  817 #define CT7_DSD_ENABLE  0x0004
  818 #define CT7_CONF_STSFD  0x0010
  819 #define CT7_EXPLCT_CONF 0x0020
  820 #define CT7_FLAG_MODE0  0x0000
  821 #define CT7_FLAG_MODE1  0x0040
  822 #define CT7_FLAG_MODE7  0x0080
  823 #define         CT7_FLAG_MMASK  0x00C0
  824 #define CT7_FASTPOST    0x0100
  825 #define CT7_ATTR_MASK   0x1e00  /* task attributes from atio7 */
  826 #define CT7_CONFIRM     0x2000
  827 #define CT7_TERMINATE   0x4000
  828 #define CT7_SENDSTATUS  0x8000
  829 
  830 /*
  831  * Type 7 CTIO status codes
  832  */
  833 #define CT7_OK          0x01    /* completed without error */
  834 #define CT7_ABORTED     0x02    /* aborted by host */
  835 #define CT7_ERR         0x04    /* see sense data for error */
  836 #define CT7_INVAL       0x06    /* request for disabled lun */
  837 #define CT7_INVRXID     0x08    /* (FC only) Invalid RX_ID */
  838 #define CT7_DATA_OVER   0x09    /* (FC only) Data Overrun */
  839 #define CT7_TIMEOUT     0x0B    /* timed out */
  840 #define CT7_RESET       0x0E    /* LIP Rset Received */
  841 #define CT7_BUS_ERROR   0x10    /* DMA PCI Error */
  842 #define CT7_REASSY_ERR  0x11    /* DMA reassembly error */
  843 #define CT7_DATA_UNDER  0x15    /* (FC only) Data Underrun */
  844 #define CT7_PORTUNAVAIL 0x28    /* port not available */
  845 #define CT7_LOGOUT      0x29    /* port logout */
  846 #define CT7_PORTCHANGED 0x2A    /* port changed */
  847 #define CT7_SRR         0x45    /* SRR Received */
  848 
  849 /*
  850  * Other 24XX related target IOCBs
  851  */
  852 
  853 /*
  854  * ABTS Received
  855  */
  856 typedef struct {
  857         isphdr_t        abts_header;
  858         u_int8_t        abts_reserved0[6];
  859         u_int16_t       abts_nphdl;
  860         u_int16_t       abts_reserved1;
  861         u_int16_t       abts_sof;
  862         u_int32_t       abts_rxid_abts;
  863         u_int16_t       abts_did_lo;
  864         u_int8_t        abts_did_hi;
  865         u_int8_t        abts_r_ctl;
  866         u_int16_t       abts_sid_lo;
  867         u_int8_t        abts_sid_hi;
  868         u_int8_t        abts_cs_ctl;
  869         u_int16_t       abts_fs_ctl;
  870         u_int8_t        abts_f_ctl;
  871         u_int8_t        abts_type;
  872         u_int16_t       abts_seq_cnt;
  873         u_int8_t        abts_df_ctl;
  874         u_int8_t        abts_seq_id;
  875         u_int16_t       abts_rx_id;
  876         u_int16_t       abts_ox_id;
  877         u_int32_t       abts_param;
  878         u_int8_t        abts_reserved2[16];
  879         u_int32_t       abts_rxid_task;
  880 } abts_t;
  881 
  882 typedef struct {
  883         isphdr_t        abts_rsp_header;
  884         u_int32_t       abts_rsp_handle;
  885         u_int16_t       abts_rsp_status;
  886         u_int16_t       abts_rsp_nphdl;
  887         u_int16_t       abts_rsp_ctl_flags;
  888         u_int16_t       abts_rsp_sof;
  889         u_int32_t       abts_rsp_rxid_abts;
  890         u_int16_t       abts_rsp_did_lo;
  891         u_int8_t        abts_rsp_did_hi;
  892         u_int8_t        abts_rsp_r_ctl;
  893         u_int16_t       abts_rsp_sid_lo;
  894         u_int8_t        abts_rsp_sid_hi;
  895         u_int8_t        abts_rsp_cs_ctl;
  896         u_int16_t       abts_rsp_f_ctl_lo;
  897         u_int8_t        abts_rsp_f_ctl_hi;
  898         u_int8_t        abts_rsp_type;
  899         u_int16_t       abts_rsp_seq_cnt;
  900         u_int8_t        abts_rsp_df_ctl;
  901         u_int8_t        abts_rsp_seq_id;
  902         u_int16_t       abts_rsp_rx_id;
  903         u_int16_t       abts_rsp_ox_id;
  904         u_int32_t       abts_rsp_param;
  905         union {
  906                 struct {
  907                         u_int16_t reserved;
  908                         u_int8_t  last_seq_id;
  909                         u_int8_t  seq_id_valid;
  910                         u_int16_t aborted_rx_id;
  911                         u_int16_t aborted_ox_id;
  912                         u_int16_t high_seq_cnt;
  913                         u_int16_t low_seq_cnt;
  914                         u_int8_t  reserved2[4];
  915                 } ba_acc;
  916                 struct {
  917                         u_int8_t vendor_unique;
  918                         u_int8_t explanation;
  919                         u_int8_t reason;
  920                         u_int8_t reserved;
  921                         u_int8_t reserved2[12];
  922                 } ba_rjt;
  923                 struct {
  924                         u_int8_t  reserved[8];
  925                         u_int32_t subcode1;
  926                         u_int32_t subcode2;
  927                 } rsp;
  928                 u_int8_t reserved[16];
  929         } abts_rsp_payload;
  930         u_int32_t       abts_rsp_rxid_task;
  931 } abts_rsp_t;
  932 
  933 /* terminate this ABTS exchange */
  934 #define ISP24XX_ABTS_RSP_TERMINATE      0x01
  935 
  936 #define ISP24XX_ABTS_RSP_COMPLETE       0x00
  937 #define ISP24XX_ABTS_RSP_RESET          0x04
  938 #define ISP24XX_ABTS_RSP_ABORTED        0x05
  939 #define ISP24XX_ABTS_RSP_TIMEOUT        0x06
  940 #define ISP24XX_ABTS_RSP_INVXID         0x08
  941 #define ISP24XX_ABTS_RSP_LOGOUT         0x29
  942 #define ISP24XX_ABTS_RSP_SUBCODE        0x31
  943 
  944 /*
  945  * Debug macros
  946  */
  947 
  948 #define ISP_TDQE(isp, msg, idx, arg)    \
  949     if (isp->isp_dblev & ISP_LOGTDEBUG2) isp_print_qentry(isp, msg, idx, arg)
  950 
  951 #ifdef  ISP_TARGET_FUNCTIONS
  952 /*
  953  * The functions below are for the publicly available
  954  * target mode functions that are internal to the QLogic driver.
  955  */
  956 
  957 /*
  958  * This function handles new response queue entry appropriate for target mode.
  959  */
  960 int isp_target_notify(struct ispsoftc *, void *, u_int16_t *);
  961 
  962 /*
  963  * This function externalizes the ability to acknowledge an Immediate Notify
  964  * request.
  965  */
  966 void isp_notify_ack(ispsoftc_t *, void *);
  967 
  968 /*
  969  * Enable/Disable/Modify a logical unit.
  970  * (softc, cmd, bus, tgt, lun, cmd_cnt, inotify_cnt, opaque)
  971  */
  972 #define DFLT_CMND_CNT   0xfe    /* unmonitored */
  973 #define DFLT_INOT_CNT   16
  974 int isp_lun_cmd(struct ispsoftc *, int, int, int, int, int, int, u_int32_t);
  975 
  976 /*
  977  * General request queue 'put' routine for target mode entries.
  978  */
  979 int isp_target_put_entry(struct ispsoftc *isp, void *);
  980 
  981 /*
  982  * General routine to put back an ATIO entry-
  983  * used for replenishing f/w resource counts.
  984  * The argument is a pointer to a source ATIO
  985  * or ATIO2.
  986  */
  987 int isp_target_put_atio(struct ispsoftc *, void *);
  988 
  989 /*
  990  * General routine to send a final CTIO for a command- used mostly for
  991  * local responses.
  992  */
  993 int isp_endcmd(struct ispsoftc *, void *, u_int32_t, u_int16_t);
  994 #define ECMD_SVALID     0x100
  995 
  996 /*
  997  * Handle an asynchronous event
  998  *
  999  * Return nonzero if the interrupt that generated this event has been dismissed.
 1000  */
 1001 
 1002 int isp_target_async(struct ispsoftc *, int, int);
 1003 #endif
 1004 #endif  /* _ISP_TARGET_H */

Cache object: a36a18bac3f2f8ff1820b812fd2342f4


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.