diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2020-07-19 18:57:59 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2020-07-19 18:57:59 +0000 |
commit | d32d980880593ffd2ea498c8788daec161fed944 (patch) | |
tree | 9258e56adc4011b03c9f27b48cb72f6a9e3dfe2b /sys/dev/ic/ami.c | |
parent | 1f57964aae4a2bef3fc9b6048f221e513aff3870 (diff) |
Move the adapter related items (luns, adapter, adapter_target,
adapter_buswidth, adapter_softc) from struct scsi_link to struct
scsibus_attach_args.
Additional compile tests by jmatthew@ (sparc64) and aoyam@ (luna88k).
Diffstat (limited to 'sys/dev/ic/ami.c')
-rw-r--r-- | sys/dev/ic/ami.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/sys/dev/ic/ami.c b/sys/dev/ic/ami.c index 88dabf9bd0a..04dbbb10d0f 100644 --- a/sys/dev/ic/ami.c +++ b/sys/dev/ic/ami.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ami.c,v 1.251 2020/07/16 21:18:30 krw Exp $ */ +/* $OpenBSD: ami.c,v 1.252 2020/07/19 18:57:57 krw Exp $ */ /* * Copyright (c) 2001 Michael Shalayeff @@ -536,13 +536,14 @@ ami_attach(struct ami_softc *sc) rw_init(&sc->sc_lock, NULL); sc->sc_link.openings = sc->sc_maxcmds; - sc->sc_link.adapter_softc = sc; - sc->sc_link.adapter = &ami_switch; - sc->sc_link.adapter_target = SDEV_NO_ADAPTER_TARGET; - sc->sc_link.adapter_buswidth = sc->sc_maxunits; sc->sc_link.pool = &sc->sc_iopool; saa.saa_sc_link = &sc->sc_link; + saa.saa_adapter_softc = sc; + saa.saa_adapter = &ami_switch; + saa.saa_adapter_target = SDEV_NO_ADAPTER_TARGET; + saa.saa_adapter_buswidth = sc->sc_maxunits; + saa.saa_luns = 8; sc->sc_scsibus = (struct scsibus_softc *)config_found(&sc->sc_dev, &saa, scsiprint); @@ -584,13 +585,14 @@ ami_attach(struct ami_softc *sc) /* TODO fetch adapter_target from the controller */ rsc->sc_link.openings = sc->sc_maxcmds; - rsc->sc_link.adapter_softc = rsc; - rsc->sc_link.adapter = &ami_raw_switch; - rsc->sc_link.adapter_target = SDEV_NO_ADAPTER_TARGET; - rsc->sc_link.adapter_buswidth = 16; rsc->sc_link.pool = &sc->sc_iopool; saa.saa_sc_link = &rsc->sc_link; + saa.saa_adapter_softc = rsc; + saa.saa_adapter = &ami_raw_switch; + saa.saa_adapter_target = SDEV_NO_ADAPTER_TARGET; + saa.saa_adapter_buswidth = 16; + saa.saa_luns = 8; ptbus = (struct scsibus_softc *)config_found(&sc->sc_dev, &saa, scsiprint); |