Source-Changes-HG archive

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

[src/trunk]: src/sys Pull up the thorpej_scsipi branch to main branch.



details:   https://anonhg.NetBSD.org/src/rev/f07f7c43c77d
branches:  trunk
changeset: 509060:f07f7c43c77d
user:      bouyer <bouyer%NetBSD.org@localhost>
date:      Wed Apr 25 17:53:04 2001 +0000

description:
Pull up the thorpej_scsipi branch to main branch.
This is a completely rewritten scsipi_xfer execution engine, and the
associated changes to HBA drivers. Overview of changes & features:
- All xfers are queued in the mid-layer, rather than doing so in an
  ad-hoc fashion in individual adapter drivers.
- Adapter/channel resource management in the mid-layer, avoids even trying
  to start running an xfer if the adapter/channel doesn't have the resources.
- Better communication between the mid-layer and the adapters.
- Asynchronous event notification mechanism from adapter to mid-layer and
  peripherals.
- Better peripheral queue management: freeze/thaw, sorted requeueing during
  recovery, etc.
- Clean separation of peripherals, adapters, and adapter channels (no more
  scsipi_link).
- Kernel thread for each scsipi_channel makes error recovery much easier
  (no more dealing with interrupt context when recovering from an error).
- Mid-layer support for tagged queueing: commands can have the tag type
  set explicitly, tag IDs are allocated in the mid-layer (thus eliminating
  the need to use buggy tag ID allocation schemes in many adapter drivers).
- support for QUEUE FULL and CHECK CONDITION status in mid-layer; the command
  will be requeued, or a REQUEST SENSE will be sent as appropriate.

Just before the merge syssrc has been tagged with thorpej_scsipi_beforemerge

diffstat:

 sys/arch/alpha/alpha/api_up1000.c     |    14 +-
 sys/arch/alpha/alpha/avalon_a12.c     |     6 +-
 sys/arch/alpha/alpha/dec_1000a.c      |     6 +-
 sys/arch/alpha/alpha/dec_2000_300.c   |     6 +-
 sys/arch/alpha/alpha/dec_2100_a50.c   |     6 +-
 sys/arch/alpha/alpha/dec_2100_a500.c  |     6 +-
 sys/arch/alpha/alpha/dec_3000_300.c   |     6 +-
 sys/arch/alpha/alpha/dec_3000_500.c   |     6 +-
 sys/arch/alpha/alpha/dec_550.c        |    14 +-
 sys/arch/alpha/alpha/dec_6600.c       |    14 +-
 sys/arch/alpha/alpha/dec_alphabook1.c |     6 +-
 sys/arch/alpha/alpha/dec_axppci_33.c  |     6 +-
 sys/arch/alpha/alpha/dec_eb164.c      |    14 +-
 sys/arch/alpha/alpha/dec_eb64plus.c   |     6 +-
 sys/arch/alpha/alpha/dec_eb66.c       |     6 +-
 sys/arch/alpha/alpha/dec_kn20aa.c     |     6 +-
 sys/arch/alpha/alpha/dec_kn300.c      |     6 +-
 sys/arch/alpha/alpha/dec_kn8ae.c      |     6 +-
 sys/arch/amiga/dev/afsc.c             |    47 +-
 sys/arch/amiga/dev/ahsc.c             |    50 +-
 sys/arch/amiga/dev/atzsc.c            |    50 +-
 sys/arch/amiga/dev/bzivsc.c           |     6 +-
 sys/arch/amiga/dev/bzsc.c             |     6 +-
 sys/arch/amiga/dev/bztzsc.c           |     6 +-
 sys/arch/amiga/dev/cbiiisc.c          |    61 +-
 sys/arch/amiga/dev/cbiisc.c           |     6 +-
 sys/arch/amiga/dev/cbsc.c             |     6 +-
 sys/arch/amiga/dev/drsc.c             |    48 +-
 sys/arch/amiga/dev/empsc.c            |    48 +-
 sys/arch/amiga/dev/flsc.c             |    12 +-
 sys/arch/amiga/dev/gtsc.c             |    47 +-
 sys/arch/amiga/dev/idesc.c            |   185 +-
 sys/arch/amiga/dev/ivsc.c             |    48 +-
 sys/arch/amiga/dev/mgnsc.c            |    47 +-
 sys/arch/amiga/dev/mlhsc.c            |    47 +-
 sys/arch/amiga/dev/otgsc.c            |    47 +-
 sys/arch/amiga/dev/sbic.c             |   319 +--
 sys/arch/amiga/dev/sbicvar.h          |     9 +-
 sys/arch/amiga/dev/sci.c              |   146 +-
 sys/arch/amiga/dev/scivar.h           |    13 +-
 sys/arch/amiga/dev/siop.c             |   223 +-
 sys/arch/amiga/dev/siop2.c            |   234 +-
 sys/arch/amiga/dev/siopvar.h          |    12 +-
 sys/arch/amiga/dev/wesc.c             |    48 +-
 sys/arch/amiga/dev/wstsc.c            |    48 +-
 sys/arch/amiga/dev/zssc.c             |    39 +-
 sys/arch/arc/jazz/asc.c               |   223 +-
 sys/arch/arm32/podulebus/asc.c        |    73 +-
 sys/arch/arm32/podulebus/cosc.c       |    68 +-
 sys/arch/arm32/podulebus/csa.c        |    10 +-
 sys/arch/arm32/podulebus/csc.c        |    63 +-
 sys/arch/arm32/podulebus/esc.c        |   177 +-
 sys/arch/arm32/podulebus/escvar.h     |    15 +-
 sys/arch/arm32/podulebus/oak.c        |    10 +-
 sys/arch/arm32/podulebus/ptsc.c       |    65 +-
 sys/arch/arm32/podulebus/sbic.c       |   387 +---
 sys/arch/arm32/podulebus/sbicvar.h    |     9 +-
 sys/arch/arm32/podulebus/sfas.c       |   176 +-
 sys/arch/arm32/podulebus/sfasvar.h    |    13 +-
 sys/arch/arm32/shark/shark_machdep.c  |     8 +-
 sys/arch/atari/dev/ncr5380.c          |   282 +-
 sys/arch/atari/dev/ncr5380reg.h       |     4 +-
 sys/arch/mac68k/dev/ncr5380.c         |   161 +-
 sys/arch/mac68k/dev/ncr5380reg.h      |     4 +-
 sys/arch/mac68k/mac68k/autoconf.c     |    16 +-
 sys/arch/mac68k/obio/esp.c            |     6 +-
 sys/arch/mac68k/obio/sbc_obio.c       |     7 +-
 sys/arch/macppc/dev/esp.c             |     6 +-
 sys/arch/macppc/dev/mesh.c            |   220 +-
 sys/arch/macppc/macppc/autoconf.c     |    12 +-
 sys/arch/mipsco/obio/asc.c            |     6 +-
 sys/arch/mvme68k/dev/ncrsc_pcctwo.c   |    36 +-
 sys/arch/mvme68k/dev/sbic.c           |   309 +--
 sys/arch/mvme68k/dev/sbicvar.h        |     9 +-
 sys/arch/mvme68k/dev/siop.c           |   217 +-
 sys/arch/mvme68k/dev/siopvar.h        |     9 +-
 sys/arch/mvme68k/dev/wdsc.c           |    39 +-
 sys/arch/mvme68k/mvme68k/autoconf.c   |     4 +-
 sys/arch/news68k/dev/si.c             |     6 +-
 sys/arch/news68k/news68k/autoconf.c   |     6 +-
 sys/arch/newsmips/apbus/spifi.c       |   153 +-
 sys/arch/newsmips/dev/sc_wrap.c       |   153 +-
 sys/arch/newsmips/dev/scsireg.h       |     4 +-
 sys/arch/newsmips/newsmips/autoconf.c |     6 +-
 sys/arch/pc532/dev/ncr.c              |     6 +-
 sys/arch/pc532/pc532/disksubr.c       |     7 +-
 sys/arch/pmax/dev/rz.c                |     8 +-
 sys/arch/pmax/dev/sii.c               |   129 +-
 sys/arch/pmax/dev/sii_ds.c            |    16 +-
 sys/arch/pmax/dev/siivar.h            |    11 +-
 sys/arch/pmax/pmax/autoconf.c         |     6 +-
 sys/arch/pmax/tc/asc_ioasic.c         |     8 +-
 sys/arch/pmax/tc/asc_pmaz.c           |    10 +-
 sys/arch/sparc/dev/esp_obio.c         |     8 +-
 sys/arch/sparc/dev/sw.c               |    12 +-
 sys/arch/sparc/sparc/autoconf.c       |    15 +-
 sys/arch/sparc64/sparc64/autoconf.c   |    12 +-
 sys/arch/sun2/sun2/autoconf.c         |    10 +-
 sys/arch/sun3/dev/esp.c               |     6 +-
 sys/arch/sun3/dev/si.c                |    13 +-
 sys/arch/sun3/dev/si_sebuf.c          |    16 +-
 sys/arch/sun3/sun3/autoconf.c         |    10 +-
 sys/arch/vax/vax/autoconf.c           |     7 +-
 sys/arch/vax/vsa/asc_vsbus.c          |     8 +-
 sys/arch/vax/vsa/ncr.c                |     6 +-
 sys/arch/x68k/dev/mha.c               |   320 +--
 sys/arch/x68k/dev/mhavar.h            |     4 +-
 sys/arch/x68k/x68k/autoconf.c         |     8 +-
 sys/dev/ata/atavar.h                  |     4 +-
 sys/dev/eisa/ahb.c                    |   455 ++---
 sys/dev/eisa/bha_eisa.c               |     3 +-
 sys/dev/eisa/dpt_eisa.c               |    45 +-
 sys/dev/i2o/iopsp.c                   |   270 +-
 sys/dev/i2o/iopspvar.h                |    13 +-
 sys/dev/ic/adv.c                      |   598 +++----
 sys/dev/ic/advlib.c                   |     3 +-
 sys/dev/ic/advlib.h                   |     7 +-
 sys/dev/ic/adw.c                      |   373 +---
 sys/dev/ic/adwlib.h                   |     8 +-
 sys/dev/ic/aha.c                      |   444 ++---
 sys/dev/ic/ahavar.h                   |     7 +-
 sys/dev/ic/aic6360.c                  |   386 ++--
 sys/dev/ic/aic6360var.h               |     4 +-
 sys/dev/ic/aic7xxx.c                  |   670 +++-----
 sys/dev/ic/aic7xxxvar.h               |    11 +-
 sys/dev/ic/bha.c                      |  2528 +++++++++++++++++++-------------
 sys/dev/ic/bhareg.h                   |   150 +-
 sys/dev/ic/bhavar.h                   |   141 +-
 sys/dev/ic/dpt.c                      |  1217 +++++++--------
 sys/dev/ic/dptreg.h                   |    46 +-
 sys/dev/ic/dptvar.h                   |    45 +-
 sys/dev/ic/isp_netbsd.c               |   448 +---
 sys/dev/ic/isp_netbsd.h               |    20 +-
 sys/dev/ic/mb89352.c                  |   321 +--
 sys/dev/ic/mb89352var.h               |     4 +-
 sys/dev/ic/ncr5380sbc.c               |   333 +--
 sys/dev/ic/ncr5380var.h               |     7 +-
 sys/dev/ic/ncr53c9x.c                 |   510 +++---
 sys/dev/ic/ncr53c9xvar.h              |    19 +-
 sys/dev/ic/siop.c                     |   922 +++++------
 sys/dev/ic/siop_common.c              |   124 +-
 sys/dev/ic/siopvar.h                  |     9 +-
 sys/dev/ic/siopvar_common.h           |    17 +-
 sys/dev/ic/sunscpal.c                 |   296 +--
 sys/dev/ic/sunscpalvar.h              |    12 +-
 sys/dev/ic/uha.c                      |   422 ++---
 sys/dev/ic/uhavar.h                   |     7 +-
 sys/dev/ic/wdc.c                      |    24 +-
 sys/dev/ic/wdcvar.h                   |     6 +-
 sys/dev/isa/bha_isa.c                 |     5 +-
 sys/dev/isa/dpt_isa.c                 |   128 +-
 sys/dev/isa/esp_isa.c                 |     8 +-
 sys/dev/isa/nca_isa.c                 |    15 +-
 sys/dev/isa/seagate.c                 |   280 ++-
 sys/dev/isa/wds.c                     |   727 +++-----
 sys/dev/pci/bha_pci.c                 |     3 +-
 sys/dev/pci/dpt_pci.c                 |    38 +-
 sys/dev/pci/ncr.c                     |    32 +-
 sys/dev/pci/pcscp.c                   |     9 +-
 sys/dev/pcmcia/aic_pcmcia.c           |    12 +-
 sys/dev/pcmcia/esp_pcmcia.c           |    15 +-
 sys/dev/pcmcia/wdc_pcmcia.c           |    14 +-
 sys/dev/sbus/esp_sbus.c               |     7 +-
 sys/dev/scsipi/atapi_base.c           |    87 +-
 sys/dev/scsipi/atapi_wdc.c            |   407 ++--
 sys/dev/scsipi/atapiconf.c            |   244 +-
 sys/dev/scsipi/atapiconf.h            |    37 +-
 sys/dev/scsipi/cd.c                   |   275 +-
 sys/dev/scsipi/cd_atapi.c             |    24 +-
 sys/dev/scsipi/cd_scsi.c              |    17 +-
 sys/dev/scsipi/cdvar.h                |     9 +-
 sys/dev/scsipi/ch.c                   |   119 +-
 sys/dev/scsipi/files.scsipi           |    15 +-
 sys/dev/scsipi/if_se.c                |    93 +-
 sys/dev/scsipi/scsi_base.c            |    88 +-
 sys/dev/scsipi/scsi_message.h         |     9 +-
 sys/dev/scsipi/scsi_tape.h            |     4 +-
 sys/dev/scsipi/scsiconf.c             |   738 ++++-----
 sys/dev/scsipi/scsiconf.h             |    42 +-
 sys/dev/scsipi/scsipi_all.h           |    89 +-
 sys/dev/scsipi/scsipi_base.c          |  2141 +++++++++++++++++++++++----
 sys/dev/scsipi/scsipi_base.h          |    20 +-
 sys/dev/scsipi/scsipi_debug.h         |   107 +-
 sys/dev/scsipi/scsipi_ioctl.c         |   133 +-
 sys/dev/scsipi/scsipi_verbose.c       |     4 +-
 sys/dev/scsipi/scsipiconf.c           |    54 +-
 sys/dev/scsipi/scsipiconf.h           |   620 +++++--
 sys/dev/scsipi/sd.c                   |   316 ++-
 sys/dev/scsipi/sd_atapi.c             |    24 +-
 sys/dev/scsipi/sd_scsi.c              |    55 +-
 sys/dev/scsipi/sdvar.h                |    10 +-
 sys/dev/scsipi/ses.c                  |    32 +-
 sys/dev/scsipi/ss.c                   |    84 +-
 sys/dev/scsipi/ss_mustek.c            |    65 +-
 sys/dev/scsipi/ss_scanjet.c           |    25 +-
 sys/dev/scsipi/ssvar.h                |     4 +-
 sys/dev/scsipi/st.c                   |   283 +-
 sys/dev/scsipi/uk.c                   |    70 +-
 sys/dev/tc/asc.c                      |    34 +-
 sys/dev/tc/asc_tcds.c                 |     9 +-
 sys/dev/usb/umassbus.c                |   352 ++--
 sys/dev/usb/umassbus.h                |    14 +-
 sys/dev/usb/usscanner.c               |   171 +-
 sys/dev/vme/si.c                      |    10 +-
 204 files changed, 12628 insertions(+), 12154 deletions(-)

diffs (truncated from 40618 to 300 lines):

diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/api_up1000.c
--- a/sys/arch/alpha/alpha/api_up1000.c Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/api_up1000.c Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: api_up1000.c,v 1.5 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: api_up1000.c,v 1.6 2001/04/25 17:53:04 bouyer Exp $ */
 
 /*
  * Copyright (c) 1995, 1996, 1997 Carnegie-Mellon University.
@@ -32,7 +32,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: api_up1000.c,v 1.5 2001/04/19 18:25:26 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: api_up1000.c,v 1.6 2001/04/25 17:53:04 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -237,11 +237,11 @@
                if (parent->dv_parent != scsipidev)
                        return;
 
-               if (sa->sa_sc_link->type == BUS_SCSI
-                   && b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
-                       return;
-               if (sa->sa_sc_link->type == BUS_ATAPI
-                   && b->unit / 100 != sa->sa_sc_link->scsipi_atapi.drive) 
+               if ((sa->sa_periph->periph_channel->chan_bustype->bustype_type
+                    == SCSIPI_BUSTYPE_SCSI ||
+                    sa->sa_periph->periph_channel->chan_bustype->bustype_type
+                    == SCSIPI_BUSTYPE_ATAPI)
+                   && b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/avalon_a12.c
--- a/sys/arch/alpha/alpha/avalon_a12.c Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/avalon_a12.c Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: avalon_a12.c,v 1.5 2000/05/22 20:13:32 thorpej Exp $ */
+/* $NetBSD: avalon_a12.c,v 1.6 2001/04/25 17:53:04 bouyer Exp $ */
 
 /* [Notice revision 2.2]
  * Copyright (c) 1997, 1998 Avalon Computer Systems, Inc.
@@ -64,7 +64,7 @@
 #include "opt_avalon_a12.h"            /* Config options headers */
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: avalon_a12.c,v 1.5 2000/05/22 20:13:32 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: avalon_a12.c,v 1.6 2001/04/25 17:53:04 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -214,7 +214,7 @@
                if (parent->dv_parent != scsidev)
                        return;
 
-               if (b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
+               if (b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_1000a.c
--- a/sys/arch/alpha/alpha/dec_1000a.c  Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_1000a.c  Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_1000a.c,v 1.11 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: dec_1000a.c,v 1.12 2001/04/25 17:53:04 bouyer Exp $ */
 
 /*
  * Copyright (c) 1998 The NetBSD Foundation, Inc.
@@ -70,7 +70,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_1000a.c,v 1.11 2001/04/19 18:25:26 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_1000a.c,v 1.12 2001/04/25 17:53:04 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -317,7 +317,7 @@
                if (parent->dv_parent != scsidev)
                        return;
 
-               if (b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
+               if (b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_2000_300.c
--- a/sys/arch/alpha/alpha/dec_2000_300.c       Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_2000_300.c       Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_2000_300.c,v 1.2 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: dec_2000_300.c,v 1.3 2001/04/25 17:53:04 bouyer Exp $ */
 
 /*-
  * Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -65,7 +65,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_2000_300.c,v 1.2 2001/04/19 18:25:26 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_2000_300.c,v 1.3 2001/04/25 17:53:04 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -253,7 +253,7 @@
                if (parent->dv_parent != scsidev)
                        return;
 
-               if (b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
+               if (b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_2100_a50.c
--- a/sys/arch/alpha/alpha/dec_2100_a50.c       Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_2100_a50.c       Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_2100_a50.c,v 1.46 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: dec_2100_a50.c,v 1.47 2001/04/25 17:53:04 bouyer Exp $ */
 
 /*
  * Copyright (c) 1995, 1996, 1997 Carnegie-Mellon University.
@@ -31,7 +31,7 @@
  */
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_2100_a50.c,v 1.46 2001/04/19 18:25:26 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_2100_a50.c,v 1.47 2001/04/25 17:53:04 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -259,7 +259,7 @@
                if (parent->dv_parent != scsidev)
                        return;
 
-               if (b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
+               if (b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_2100_a500.c
--- a/sys/arch/alpha/alpha/dec_2100_a500.c      Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_2100_a500.c      Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_2100_a500.c,v 1.2 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: dec_2100_a500.c,v 1.3 2001/04/25 17:53:04 bouyer Exp $ */
 
 /*-
  * Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -65,7 +65,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_2100_a500.c,v 1.2 2001/04/19 18:25:26 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_2100_a500.c,v 1.3 2001/04/25 17:53:04 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -302,7 +302,7 @@
                if (parent->dv_parent != scsidev)
                        return;
 
-               if (b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
+               if (b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_3000_300.c
--- a/sys/arch/alpha/alpha/dec_3000_300.c       Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_3000_300.c       Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_3000_300.c,v 1.33 2000/10/17 08:55:43 nisimura Exp $ */
+/* $NetBSD: dec_3000_300.c,v 1.34 2001/04/25 17:53:04 bouyer Exp $ */
 
 /*
  * Copyright (c) 1995, 1996 Carnegie-Mellon University.
@@ -33,7 +33,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_3000_300.c,v 1.33 2000/10/17 08:55:43 nisimura Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_3000_300.c,v 1.34 2001/04/25 17:53:04 bouyer Exp $");
 
 #include "opt_new_scc_driver.h"
 
@@ -229,7 +229,7 @@
                if (parent->dv_parent != scsidev)
                        return;
 
-               if (b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
+               if (b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_3000_500.c
--- a/sys/arch/alpha/alpha/dec_3000_500.c       Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_3000_500.c       Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_3000_500.c,v 1.32 2000/10/17 08:55:43 nisimura Exp $ */
+/* $NetBSD: dec_3000_500.c,v 1.33 2001/04/25 17:53:04 bouyer Exp $ */
 
 /*
  * Copyright (c) 1994, 1995, 1996 Carnegie-Mellon University.
@@ -32,7 +32,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_3000_500.c,v 1.32 2000/10/17 08:55:43 nisimura Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_3000_500.c,v 1.33 2001/04/25 17:53:04 bouyer Exp $");
 
 #include "opt_new_scc_driver.h"
 
@@ -250,7 +250,7 @@
                if (parent->dv_parent != scsidev)
                        return;
 
-               if (b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
+               if (b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_550.c
--- a/sys/arch/alpha/alpha/dec_550.c    Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_550.c    Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_550.c,v 1.11 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: dec_550.c,v 1.12 2001/04/25 17:53:05 bouyer Exp $ */
 
 /*
  * Copyright (c) 1995, 1996, 1997 Carnegie-Mellon University.
@@ -32,7 +32,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_550.c,v 1.11 2001/04/19 18:25:26 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_550.c,v 1.12 2001/04/25 17:53:05 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -243,11 +243,11 @@
                if (parent->dv_parent != scsipidev)
                        return;
 
-               if (sa->sa_sc_link->type == BUS_SCSI
-                   && b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
-                       return;
-               if (sa->sa_sc_link->type == BUS_ATAPI
-                   && b->unit / 100 != sa->sa_sc_link->scsipi_atapi.drive) 
+               if ((sa->sa_periph->periph_channel->chan_bustype->bustype_type
+                    == SCSIPI_BUSTYPE_SCSI ||
+                    sa->sa_periph->periph_channel->chan_bustype->bustype_type
+                    == SCSIPI_BUSTYPE_ATAPI)
+                   && b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_6600.c
--- a/sys/arch/alpha/alpha/dec_6600.c   Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_6600.c   Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_6600.c,v 1.9 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: dec_6600.c,v 1.10 2001/04/25 17:53:05 bouyer Exp $ */
 
 /*
  * Copyright (c) 1995, 1996, 1997 Carnegie-Mellon University.
@@ -29,7 +29,7 @@
 
 #include <sys/cdefs.h>                 /* RCS ID & Copyright macro defns */
 
-__KERNEL_RCSID(0, "$NetBSD: dec_6600.c,v 1.9 2001/04/19 18:25:26 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: dec_6600.c,v 1.10 2001/04/25 17:53:05 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -260,11 +260,11 @@
                if (parent->dv_parent != scsipidev)
                        return;
 
-               if (sa->sa_sc_link->type == BUS_SCSI
-                   && b->unit / 100 != sa->sa_sc_link->scsipi_scsi.target)
-                       return;
-               if (sa->sa_sc_link->type == BUS_ATAPI
-                   && b->unit / 100 != sa->sa_sc_link->scsipi_atapi.drive)
+               if ((sa->sa_periph->periph_channel->chan_bustype->bustype_type
+                    == SCSIPI_BUSTYPE_SCSI ||
+                    sa->sa_periph->periph_channel->chan_bustype->bustype_type
+                    == SCSIPI_BUSTYPE_ATAPI)
+                   && b->unit / 100 != sa->sa_periph->periph_target)
                        return;
 
                /* XXX LUN! */
diff -r 0dba8c382b3a -r f07f7c43c77d sys/arch/alpha/alpha/dec_alphabook1.c
--- a/sys/arch/alpha/alpha/dec_alphabook1.c     Wed Apr 25 17:35:00 2001 +0000
+++ b/sys/arch/alpha/alpha/dec_alphabook1.c     Wed Apr 25 17:53:04 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: dec_alphabook1.c,v 1.7 2001/04/19 18:25:26 thorpej Exp $ */
+/* $NetBSD: dec_alphabook1.c,v 1.8 2001/04/25 17:53:05 bouyer Exp $ */



Home | Main Index | Thread Index | Old Index