summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/arch/hp300/hp300/autoconf.c5
-rw-r--r--sys/arch/hp300/hp300/mem.c6
2 files changed, 5 insertions, 6 deletions
diff --git a/sys/arch/hp300/hp300/autoconf.c b/sys/arch/hp300/hp300/autoconf.c
index 58d58bfd7ef..6efcee9abcf 100644
--- a/sys/arch/hp300/hp300/autoconf.c
+++ b/sys/arch/hp300/hp300/autoconf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: autoconf.c,v 1.43 2007/06/01 19:25:09 deraadt Exp $ */
+/* $OpenBSD: autoconf.c,v 1.44 2007/09/08 09:28:49 martin Exp $ */
/* $NetBSD: autoconf.c,v 1.45 1999/04/10 17:31:02 kleink Exp $ */
/*
@@ -334,10 +334,9 @@ device_register(dev, aux)
* we can mount as root.
*/
dd = (struct dev_data *)malloc(sizeof(struct dev_data),
- M_DEVBUF, M_NOWAIT);
+ M_DEVBUF, M_NOWAIT | M_ZERO);
if (dd == NULL)
panic("device_register: can't allocate dev_data");
- bzero(dd, sizeof(struct dev_data));
dd->dd_dev = dev;
diff --git a/sys/arch/hp300/hp300/mem.c b/sys/arch/hp300/hp300/mem.c
index 6d9f0006bd3..2b0751deae8 100644
--- a/sys/arch/hp300/hp300/mem.c
+++ b/sys/arch/hp300/hp300/mem.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mem.c,v 1.23 2005/10/28 09:07:48 martin Exp $ */
+/* $OpenBSD: mem.c,v 1.24 2007/09/08 09:28:49 martin Exp $ */
/* $NetBSD: mem.c,v 1.25 1999/03/27 00:30:06 mycroft Exp $ */
/*
@@ -192,8 +192,8 @@ mmrw(dev, uio, flags)
*/
if (devzeropage == NULL) {
devzeropage = (caddr_t)
- malloc(PAGE_SIZE, M_TEMP, M_WAITOK);
- bzero(devzeropage, PAGE_SIZE);
+ malloc(PAGE_SIZE, M_TEMP,
+ M_WAITOK | M_ZERO);
}
c = min(iov->iov_len, PAGE_SIZE);
error = uiomove(devzeropage, c, uio);