diff options
author | 2020-06-27 14:29:44 +0000 | |
---|---|---|
committer | 2020-06-27 14:29:44 +0000 | |
commit | a7997e14b2c5583c85c5c712c73af0f27d80f68b (patch) | |
tree | ed05f355cdd5a7f707ed31d2f1bc6178cdca08bc /sys/dev/pci | |
parent | Add missing label. (diff) | |
download | wireguard-openbsd-a7997e14b2c5583c85c5c712c73af0f27d80f68b.tar.xz wireguard-openbsd-a7997e14b2c5583c85c5c712c73af0f27d80f68b.zip |
No need to bzero()/memset() 'struct scsibus_attach_args' variables
immediately before initializing the only field in the struct.
Diffstat (limited to 'sys/dev/pci')
-rw-r--r-- | sys/dev/pci/arc.c | 3 | ||||
-rw-r--r-- | sys/dev/pci/iha_pci.c | 3 | ||||
-rw-r--r-- | sys/dev/pci/ips.c | 4 | ||||
-rw-r--r-- | sys/dev/pci/mfii.c | 4 | ||||
-rw-r--r-- | sys/dev/pci/mpii.c | 3 | ||||
-rw-r--r-- | sys/dev/pci/qle.c | 3 | ||||
-rw-r--r-- | sys/dev/pci/trm_pci.c | 3 | ||||
-rw-r--r-- | sys/dev/pci/vmwpvs.c | 3 |
8 files changed, 8 insertions, 18 deletions
diff --git a/sys/dev/pci/arc.c b/sys/dev/pci/arc.c index 6f8ec1bf70e..d4ee993e41d 100644 --- a/sys/dev/pci/arc.c +++ b/sys/dev/pci/arc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: arc.c,v 1.111 2020/06/24 18:59:30 krw Exp $ */ +/* $OpenBSD: arc.c,v 1.112 2020/06/27 14:29:45 krw Exp $ */ /* * Copyright (c) 2006 David Gwynne <dlg@openbsd.org> @@ -809,7 +809,6 @@ arc_attach(struct device *parent, struct device *self, void *aux) sc->sc_link.openings = sc->sc_req_count; sc->sc_link.pool = &sc->sc_iopool; - bzero(&saa, sizeof(saa)); saa.saa_sc_link = &sc->sc_link; child = config_found(self, &saa, scsiprint); diff --git a/sys/dev/pci/iha_pci.c b/sys/dev/pci/iha_pci.c index 63c66cd7a37..420662d035b 100644 --- a/sys/dev/pci/iha_pci.c +++ b/sys/dev/pci/iha_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: iha_pci.c,v 1.12 2007/10/18 21:10:58 otto Exp $ */ +/* $OpenBSD: iha_pci.c,v 1.13 2020/06/27 14:29:45 krw Exp $ */ /*------------------------------------------------------------------------- * * Device driver for the INI-9XXXU/UW or INIC-940/950 PCI SCSI Controller. @@ -126,7 +126,6 @@ iha_pci_attach(parent, self, aux) printf(": %s\n", intrstr); if (iha_init_tulip(sc) == 0) { - bzero(&saa, sizeof(saa)); saa.saa_sc_link = &sc->sc_link; config_found(&sc->sc_dev, &saa, scsiprint); } diff --git a/sys/dev/pci/ips.c b/sys/dev/pci/ips.c index cbcb06c8213..dd89d121f97 100644 --- a/sys/dev/pci/ips.c +++ b/sys/dev/pci/ips.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ips.c,v 1.119 2020/06/24 18:59:30 krw Exp $ */ +/* $OpenBSD: ips.c,v 1.120 2020/06/27 14:29:45 krw Exp $ */ /* * Copyright (c) 2006, 2007, 2009 Alexander Yurchenko <grange@openbsd.org> @@ -727,13 +727,11 @@ ips_attach(struct device *parent, struct device *self, void *aux) sc->sc_scsi_link.adapter_softc = sc; sc->sc_scsi_link.pool = &sc->sc_iopool; - bzero(&saa, sizeof(saa)); saa.saa_sc_link = &sc->sc_scsi_link; sc->sc_scsibus = (struct scsibus_softc *)config_found(self, &saa, scsiprint); /* For each channel attach SCSI pass-through bus */ - bzero(&saa, sizeof(saa)); for (i = 0; i < IPS_MAXCHANS; i++) { struct ips_pt *pt; struct scsi_link *link; diff --git a/sys/dev/pci/mfii.c b/sys/dev/pci/mfii.c index 3eadcdf81db..a6a70841da9 100644 --- a/sys/dev/pci/mfii.c +++ b/sys/dev/pci/mfii.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mfii.c,v 1.71 2020/06/24 22:03:41 cheloha Exp $ */ +/* $OpenBSD: mfii.c,v 1.72 2020/06/27 14:29:45 krw Exp $ */ /* * Copyright (c) 2012 David Gwynne <dlg@openbsd.org> @@ -788,7 +788,6 @@ mfii_attach(struct device *parent, struct device *self, void *aux) sc->sc_link.adapter_buswidth = sc->sc_info.mci_max_lds; sc->sc_link.pool = &sc->sc_iopool; - memset(&saa, 0, sizeof(saa)); saa.saa_sc_link = &sc->sc_link; sc->sc_scsibus = (struct scsibus_softc *) @@ -925,7 +924,6 @@ mfii_syspd(struct mfii_softc *sc) link->openings = sc->sc_max_cmds - 1; link->pool = &sc->sc_iopool; - memset(&saa, 0, sizeof(saa)); saa.saa_sc_link = link; sc->sc_pd->pd_scsibus = (struct scsibus_softc *) diff --git a/sys/dev/pci/mpii.c b/sys/dev/pci/mpii.c index 1041143abe5..165ba274712 100644 --- a/sys/dev/pci/mpii.c +++ b/sys/dev/pci/mpii.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mpii.c,v 1.129 2020/06/24 18:33:50 krw Exp $ */ +/* $OpenBSD: mpii.c,v 1.130 2020/06/27 14:29:45 krw Exp $ */ /* * Copyright (c) 2010, 2012 Mike Belopuhov * Copyright (c) 2009 James Giannoules @@ -590,7 +590,6 @@ mpii_attach(struct device *parent, struct device *self, void *aux) sc->sc_link.openings = sc->sc_max_cmds - 1; sc->sc_link.pool = &sc->sc_iopool; - memset(&saa, 0, sizeof(saa)); saa.saa_sc_link = &sc->sc_link; sc->sc_ih = pci_intr_establish(sc->sc_pc, ih, IPL_BIO, diff --git a/sys/dev/pci/qle.c b/sys/dev/pci/qle.c index 884131d5113..68e5f107024 100644 --- a/sys/dev/pci/qle.c +++ b/sys/dev/pci/qle.c @@ -1,4 +1,4 @@ -/* $OpenBSD: qle.c,v 1.54 2020/06/27 13:37:51 bket Exp $ */ +/* $OpenBSD: qle.c,v 1.55 2020/06/27 14:29:45 krw Exp $ */ /* * Copyright (c) 2013, 2014 Jonathan Matthew <jmatthew@openbsd.org> @@ -677,7 +677,6 @@ qle_attach(struct device *parent, struct device *self, void *aux) sc->sc_link.node_wwn &= ~(0xfULL << 56); } - memset(&saa, 0, sizeof(saa)); saa.saa_sc_link = &sc->sc_link; /* config_found() returns the scsibus attached to us */ diff --git a/sys/dev/pci/trm_pci.c b/sys/dev/pci/trm_pci.c index 584410e0637..e5b234bbdff 100644 --- a/sys/dev/pci/trm_pci.c +++ b/sys/dev/pci/trm_pci.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trm_pci.c,v 1.4 2006/11/28 23:59:45 dlg Exp $ +/* $OpenBSD: trm_pci.c,v 1.5 2020/06/27 14:29:45 krw Exp $ * ------------------------------------------------------------ * O.S : OpenBSD * FILE NAME : trm_pci.c @@ -153,7 +153,6 @@ trm_pci_attach(struct device *parent, struct device *self, void *aux) if (intrstr != NULL) printf(": %s\n", intrstr); - bzero(&saa, sizeof(saa)); saa.saa_sc_link = &sc->sc_link; /* Tell SCSI layer about our SCSI bus */ diff --git a/sys/dev/pci/vmwpvs.c b/sys/dev/pci/vmwpvs.c index b6179c12434..27e0ff6f306 100644 --- a/sys/dev/pci/vmwpvs.c +++ b/sys/dev/pci/vmwpvs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vmwpvs.c,v 1.17 2020/06/24 18:33:50 krw Exp $ */ +/* $OpenBSD: vmwpvs.c,v 1.18 2020/06/27 14:29:45 krw Exp $ */ /* * Copyright (c) 2013 David Gwynne <dlg@openbsd.org> @@ -567,7 +567,6 @@ vmwpvs_attach(struct device *parent, struct device *self, void *aux) sc->sc_link.openings = VMWPVS_OPENINGS; sc->sc_link.pool = &sc->sc_iopool; - bzero(&saa, sizeof(saa)); saa.saa_sc_link = &sc->sc_link; sc->sc_scsibus = (struct scsibus_softc *)config_found(&sc->sc_dev, |