Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/ic Clean up license && copyright a tad. ct_reserved ...



details:   https://anonhg.NetBSD.org/src/rev/d13704db5a1d
branches:  trunk
changeset: 507123:d13704db5a1d
user:      mjacob <mjacob%NetBSD.org@localhost>
date:      Wed Mar 14 05:01:54 2001 +0000

description:
Clean up license && copyright a tad. ct_reserved should now be more
properly called ct_syshandle.

diffstat:

 sys/dev/ic/isp_target.c |  40 +++++++++++++++++++---------------------
 1 files changed, 19 insertions(+), 21 deletions(-)

diffs (154 lines):

diff -r 3e671e8e3996 -r d13704db5a1d sys/dev/ic/isp_target.c
--- a/sys/dev/ic/isp_target.c   Wed Mar 14 04:55:21 2001 +0000
+++ b/sys/dev/ic/isp_target.c   Wed Mar 14 05:01:54 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: isp_target.c,v 1.10 2000/12/23 01:38:00 wiz Exp $ */
+/* $NetBSD: isp_target.c,v 1.11 2001/03/14 05:01:54 mjacob Exp $ */
 /*
  * This driver, which is contained in NetBSD in the files:
  *
@@ -30,7 +30,7 @@
 /*
  * Machine and OS Independent Target Mode Code for the Qlogic SCSI/FC adapters.
  *
- * Copyright (c) 1999 by Matthew Jacob
+ * Copyright (c) 1999, 2000, 2001 by Matthew Jacob
  * All rights reserved.
  * mjacob%feral.com@localhost
  *
@@ -40,10 +40,7 @@
  * 1. Redistributions of source code must retain the above copyright
  *    notice immediately at the beginning of the file, without modification,
  *    this list of conditions, and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
+ * 2. The name of the author may not be used to endorse or promote products
  *    derived from this software without specific prior written permission.
  *
  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
@@ -118,7 +115,7 @@
  * The third group that can show up in the response queue are Immediate
  * Notification events. These include things like notifications of SCSI bus
  * resets, or Bus Device Reset messages or other messages received. This
- * a classic oddbins area. It can get  a little wierd because you then turn
+ * a classic oddbins area. It can get  a little weird because you then turn
  * around and acknowledge the Immediate Notify by writing an entry onto the
  * request queue and then the f/w turns around and gives you an acknowledgement
  * to *your* acknowledgement on the response queue (the idea being to let
@@ -451,7 +448,7 @@
  */
 
 int
-isp_endcmd(struct ispsoftc *isp, void *arg, u_int32_t code, u_int32_t hdl)
+isp_endcmd(struct ispsoftc *isp, void *arg, u_int32_t code, u_int16_t hdl)
 {
        int sts;
        union {
@@ -491,13 +488,14 @@
                        cto->rsp.m1.ct_senselen = 16;
                        cto->ct_flags |= CT2_SNSLEN_VALID;
                }
-               cto->ct_reserved = hdl;
+               cto->ct_syshandle = hdl;
        } else {
                at_entry_t *aep = arg;
                ct_entry_t *cto = &un._ctio;
 
                cto->ct_header.rqs_entry_type = RQSTYPE_CTIO;
                cto->ct_header.rqs_entry_count = 1;
+               cto->ct_fwhandle = aep->at_handle;
                cto->ct_iid = aep->at_iid;
                cto->ct_tgt = aep->at_tgt;
                cto->ct_lun = aep->at_lun;
@@ -508,7 +506,7 @@
                        cto->ct_flags |= CT_CCINCR;
                }
                cto->ct_scsi_status = sts;
-               cto->ct_reserved = hdl;
+               cto->ct_syshandle = hdl;
        }
        return (isp_target_put_entry(isp, &un));
 }
@@ -902,12 +900,12 @@
        struct ispsoftc *isp;
        ct_entry_t *ct;
 {
-       XS_T *xs;
+       void *xs;
        int pl = ISP_LOGTDEBUG2;
        char *fmsg = NULL;
 
-       if (ct->ct_reserved) {
-               xs = isp_find_xs(isp, ct->ct_reserved);
+       if (ct->ct_syshandle) {
+               xs = isp_find_xs(isp, ct->ct_syshandle);
                if (xs == NULL)
                        pl = ISP_LOGALL;
        } else {
@@ -1035,7 +1033,7 @@
                 * The assumption is that they'll all be returned in the
                 * order we got them.
                 */
-               if (ct->ct_reserved == 0) {
+               if (ct->ct_syshandle == 0) {
                        if ((ct->ct_flags & CT_SENDSTATUS) == 0) {
                                isp_prt(isp, pl,
                                    "intermediate CTIO completed ok");
@@ -1046,7 +1044,7 @@
                } else {
                        isp_prt(isp, pl,
                            "NO xs for CTIO (handle 0x%x) status 0x%x",
-                           ct->ct_reserved, ct->ct_status & ~QLTM_SVALID);
+                           ct->ct_syshandle, ct->ct_status & ~QLTM_SVALID);
                }
        } else {
                if (ct->ct_flags & CT_SENDSTATUS) {
@@ -1065,7 +1063,7 @@
                         * notify platform dependent layers.
                         */
                        isp_prt(isp, pl, "data CTIO complete");
-                       ISP_DMAFREE(isp, xs, ct->ct_reserved);
+                       ISP_DMAFREE(isp, xs, ct->ct_syshandle);
                }
                (void) isp_async(isp, ISPASYNC_TARGET_ACTION, ct);
                /*
@@ -1083,8 +1081,8 @@
        int pl = ISP_LOGTDEBUG2;
        char *fmsg = NULL;
 
-       if (ct->ct_reserved) {
-               xs = isp_find_xs(isp, ct->ct_reserved);
+       if (ct->ct_syshandle) {
+               xs = isp_find_xs(isp, ct->ct_syshandle);
                if (xs == NULL)
                        pl = ISP_LOGALL;
        } else {
@@ -1215,7 +1213,7 @@
                 * The assumption is that they'll all be returned in the
                 * order we got them.
                 */
-               if (ct->ct_reserved == 0) {
+               if (ct->ct_syshandle == 0) {
                        if ((ct->ct_flags & CT_SENDSTATUS) == 0) {
                                isp_prt(isp, pl,
                                    "intermediate CTIO completed ok");
@@ -1226,7 +1224,7 @@
                } else {
                        isp_prt(isp, pl,
                            "NO xs for CTIO (handle 0x%x) status 0x%x",
-                           ct->ct_reserved, ct->ct_status & ~QLTM_SVALID);
+                           ct->ct_syshandle, ct->ct_status & ~QLTM_SVALID);
                }
        } else {
                if (ct->ct_flags & CT_SENDSTATUS) {
@@ -1245,7 +1243,7 @@
                         * notify platform dependent layers.
                         */
                        isp_prt(isp, pl, "data CTIO complete");
-                       ISP_DMAFREE(isp, xs, ct->ct_reserved);
+                       ISP_DMAFREE(isp, xs, ct->ct_syshandle);
                }
                (void) isp_async(isp, ISPASYNC_TARGET_ACTION, ct);
                /*



Home | Main Index | Thread Index | Old Index