summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sys/sparc64/sbus/sbus.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/sparc64/sbus/sbus.c b/sys/sparc64/sbus/sbus.c
index 5cf7ad2..dbe3859 100644
--- a/sys/sparc64/sbus/sbus.c
+++ b/sys/sparc64/sbus/sbus.c
@@ -303,8 +303,8 @@ sbus_attach(device_t dev)
sizeof(*range), (void **)&range)) == -1) {
panic("%s: error getting ranges property", __func__);
}
- sc->sc_rd = (struct sbus_rd *)malloc(sizeof(*sc->sc_rd) * sc->sc_nrange,
- M_DEVBUF, M_NOWAIT);
+ sc->sc_rd = malloc(sizeof(*sc->sc_rd) * sc->sc_nrange, M_DEVBUF,
+ M_NOWAIT | M_ZERO);
if (sc->sc_rd == NULL)
panic("%s: cannot allocate rmans", __func__);
/*
OpenPOWER on IntegriCloud