summaryrefslogtreecommitdiff
path: root/sys/dev/lmc
diff options
context:
space:
mode:
authorDavid Malone <dwmalone@FreeBSD.org>2000-12-08 21:51:06 +0000
committerDavid Malone <dwmalone@FreeBSD.org>2000-12-08 21:51:06 +0000
commit7cc0979fd64b721c92c3dd4a8688b56e15c9a5f9 (patch)
treec383ffd6da8fbab2789828310191f8717f675124 /sys/dev/lmc
parentb1f3daafde37fa36b819c0649c121d98175a6a2d (diff)
Notes
Diffstat (limited to 'sys/dev/lmc')
-rw-r--r--sys/dev/lmc/if_lmc.c3
-rw-r--r--sys/dev/lmc/if_lmc_fbsd3.c3
2 files changed, 2 insertions, 4 deletions
diff --git a/sys/dev/lmc/if_lmc.c b/sys/dev/lmc/if_lmc.c
index a6c91a9bf3ce..cf220f7b5615 100644
--- a/sys/dev/lmc/if_lmc.c
+++ b/sys/dev/lmc/if_lmc.c
@@ -1342,12 +1342,11 @@ ng_lmc_rcvmsg(node_p node, struct ng_mesg *msg,
int pos = 0;
int resplen = sizeof(struct ng_mesg) + 512;
MALLOC(resp, struct ng_mesg *, resplen, M_NETGRAPH,
- M_NOWAIT);
+ M_NOWAIT | M_ZERO);
if (resp == NULL) {
error = ENOMEM;
break;
}
- bzero(resp, resplen);
arg = (resp)->data;
/*
diff --git a/sys/dev/lmc/if_lmc_fbsd3.c b/sys/dev/lmc/if_lmc_fbsd3.c
index ce7c9473f58c..f6f9bf9a9d11 100644
--- a/sys/dev/lmc/if_lmc_fbsd3.c
+++ b/sys/dev/lmc/if_lmc_fbsd3.c
@@ -137,10 +137,9 @@ lmc_pci_attach(pcici_t config_id, int unit)
/*
* allocate memory for the softc
*/
- sc = (lmc_softc_t *) malloc(sizeof(*sc), M_DEVBUF, M_NOWAIT);
+ sc = (lmc_softc_t *) malloc(sizeof(*sc), M_DEVBUF, M_NOWAIT | M_ZERO);
if (sc == NULL)
return;
- bzero(sc, sizeof(*sc)); /* Zero out the softc*/
revinfo = PCI_CONF_READ(PCI_CFRV) & 0xFF;
id = PCI_CONF_READ(PCI_CFID);