From owner-freebsd-bugs Wed Jan 15 11:11:51 1997 Return-Path: Received: (from root@localhost) by freefall.freebsd.org (8.8.4/8.8.4) id LAA17747 for bugs-outgoing; Wed, 15 Jan 1997 11:11:51 -0800 (PST) Received: from tfs.com (tfs.com [140.145.250.1]) by freefall.freebsd.org (8.8.4/8.8.4) with SMTP id LAA17726; Wed, 15 Jan 1997 11:11:02 -0800 (PST) Received: from schizo.dk.tfs.com by tfs.com (smail3.1.28.1) with SMTP id m0vkajG-0003yEC; Wed, 15 Jan 97 11:10 PST Received: from critter.dk.tfs.com (critter-home [193.162.32.19]) by schizo.dk.tfs.com (8.8.2/8.7.3) with ESMTP id UAA00674; Wed, 15 Jan 1997 20:09:49 +0100 (MET) Received: from critter.dk.tfs.com (localhost [127.0.0.1]) by critter.dk.tfs.com (8.8.2/8.8.2) with ESMTP id UAA28147; Wed, 15 Jan 1997 20:10:47 +0100 (MET) To: Bruce Evans cc: dg@root.com, bugs@freebsd.org, dyson@freebsd.org, wollman@freebsd.org Subject: Re: malloc(..., M_WAITOK) found harmful In-reply-to: Your message of "Thu, 16 Jan 1997 04:54:18 +1100." <199701151754.EAA31434@godzilla.zeta.org.au> Date: Wed, 15 Jan 1997 20:10:47 +0100 Message-ID: <28145.853355447@critter.dk.tfs.com> From: Poul-Henning Kamp Sender: owner-bugs@freebsd.org X-Loop: FreeBSD.org Precedence: bulk In message <199701151754.EAA31434@godzilla.zeta.org.au>, Bruce Evans writes: >> Arrg!!!! I didn't even know about "mcl_map". Okay, this is easy to fix - >>mcl_map simply needs to be added to the list of maps in vm_map_entry_create. > >The maps are special-cased in too many other places. I added a check for >mcl_map after all the relevant checks for mb_map in vm_map.c. It is also >missing in vm_object.c. I think it is already handled right in vm_kern.c. Isn't it time to associate an attribute with the map, where we can see this special casing, rather than have these if() statements get longer and longer... ? >*** vm_map.c~ Wed Jan 15 04:50:05 1997 >--- vm_map.c Thu Jan 16 04:03:39 1997 >*************** >*** 333,338 **** > int s; > >! if (map == kernel_map || map == kmem_map || >! map == mb_map || map == pager_map) { > s = splvm(); > entry->next = kentry_free; >--- 331,336 ---- > int s; > >! if (map == kernel_map || map == kmem_map || map == mb_map || >! map == mcl_map || map == pager_map) { > s = splvm(); > entry->next = kentry_free; -- Poul-Henning Kamp | phk@FreeBSD.ORG FreeBSD Core-team. http://www.freebsd.org/~phk | phk@login.dknet.dk Private mailbox. whois: [PHK] | phk@tfs.com TRW Financial Systems, Inc. Power and ignorance is a disgusting cocktail.