summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>1999-02-26 04:49:08 +0000
committerArtur Grabowski <art@cvs.openbsd.org>1999-02-26 04:49:08 +0000
commitbc8986d97d2f8474b598194a210a6aa5338280b4 (patch)
treef0567237fda4f9a25a08eac36a78af74aef89c9f
parent548a1931905604077210d8a8c72f502eccc42246 (diff)
kmem allocation changes for uvm
-rw-r--r--sys/kern/uipc_mbuf.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/sys/kern/uipc_mbuf.c b/sys/kern/uipc_mbuf.c
index e70679bb0c8..dcfd71964de 100644
--- a/sys/kern/uipc_mbuf.c
+++ b/sys/kern/uipc_mbuf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: uipc_mbuf.c,v 1.8 1999/01/07 22:28:01 deraadt Exp $ */
+/* $OpenBSD: uipc_mbuf.c,v 1.9 1999/02/26 04:49:07 art Exp $ */
/* $NetBSD: uipc_mbuf.c,v 1.15.4.1 1996/06/13 17:11:44 cgd Exp $ */
/*
@@ -64,6 +64,10 @@ didn't get a copy, you may request one from <license@ipv6.nrl.navy.mil>.
#include <vm/vm.h>
+#if defined(UVM)
+#include <uvm/uvm_extern.h>
+#endif
+
extern vm_map_t mb_map;
struct mbuf *mbutl;
char *mclrefcnt;
@@ -101,7 +105,12 @@ m_clalloc(ncl, nowait)
int npg, s;
npg = ncl * CLSIZE;
+#if defined(UVM)
+ p = (caddr_t)uvm_km_kmemalloc(mb_map, uvmexp.mb_object, ctob(npg),
+ nowait ? 0 : UVM_KMF_NOWAIT);
+#else
p = (caddr_t)kmem_malloc(mb_map, ctob(npg), !nowait);
+#endif
if (p == NULL) {
s = splclock();
curtime = time;