summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkrw <krw@openbsd.org>2018-02-07 06:19:54 +0000
committerkrw <krw@openbsd.org>2018-02-07 06:19:54 +0000
commitc6a0181911ffae8f85557b87f77c12375ce30e68 (patch)
tree309b0b41002e5ad35952c24730e7e7e5cf357766
parentUse duid_format() instead of rolling one locally. (diff)
downloadwireguard-openbsd-c6a0181911ffae8f85557b87f77c12375ce30e68.tar.xz
wireguard-openbsd-c6a0181911ffae8f85557b87f77c12375ce30e68.zip
Use M_WAITOK to show we don't need to check for NULL.
ok deraadt@
-rw-r--r--sys/arch/amd64/amd64/mpbios.c6
-rw-r--r--sys/arch/i386/i386/mpbios.c6
2 files changed, 6 insertions, 6 deletions
diff --git a/sys/arch/amd64/amd64/mpbios.c b/sys/arch/amd64/amd64/mpbios.c
index 29fc18cfa2a..abbe1f3939b 100644
--- a/sys/arch/amd64/amd64/mpbios.c
+++ b/sys/arch/amd64/amd64/mpbios.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpbios.c,v 1.28 2017/10/14 04:44:43 jsg Exp $ */
+/* $OpenBSD: mpbios.c,v 1.29 2018/02/07 06:19:54 krw Exp $ */
/* $NetBSD: mpbios.c,v 1.7 2003/05/15 16:32:50 fvdl Exp $ */
/*-
@@ -556,9 +556,9 @@ mpbios_scan(struct device *self)
}
mp_busses = mallocarray(mp_nbusses, sizeof(struct mp_bus),
- M_DEVBUF, M_NOWAIT|M_ZERO);
+ M_DEVBUF, M_WAITOK|M_ZERO);
mp_intrs = mallocarray(intr_cnt, sizeof(struct mp_intr_map),
- M_DEVBUF, M_NOWAIT);
+ M_DEVBUF, M_WAITOK);
/* re-walk the table, recording info of interest */
position = (const u_int8_t *)mp_cth + sizeof(*mp_cth);
diff --git a/sys/arch/i386/i386/mpbios.c b/sys/arch/i386/i386/mpbios.c
index 75019e2c31d..4dfd3bd9bf2 100644
--- a/sys/arch/i386/i386/mpbios.c
+++ b/sys/arch/i386/i386/mpbios.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mpbios.c,v 1.40 2016/07/28 21:57:56 kettenis Exp $ */
+/* $OpenBSD: mpbios.c,v 1.41 2018/02/07 06:19:54 krw Exp $ */
/* $NetBSD: mpbios.c,v 1.2 2002/10/01 12:56:57 fvdl Exp $ */
/*-
@@ -597,9 +597,9 @@ mpbios_scan(struct device *self)
}
mp_busses = mallocarray(mp_nbusses, sizeof(struct mp_bus),
- M_DEVBUF, M_NOWAIT|M_ZERO);
+ M_DEVBUF, M_WAITOK|M_ZERO);
mp_intrs = mallocarray(intr_cnt, sizeof(struct mp_intr_map),
- M_DEVBUF, M_NOWAIT);
+ M_DEVBUF, M_WAITOK);
/* re-walk the table, recording info of interest */
position = (const u_int8_t *)mp_cth + sizeof(*mp_cth);