From owner-cvs-all Fri Mar 2 9:23:16 2001 Delivered-To: cvs-all@freebsd.org Received: from moby.geekhouse.net (moby.geekhouse.net [64.81.6.36]) by hub.freebsd.org (Postfix) with ESMTP id EDFF937B71B; Fri, 2 Mar 2001 09:23:11 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: from laptop.baldwin.cx (john@dhcp152.geekhouse.net [192.168.1.152]) by moby.geekhouse.net (8.11.0/8.9.3) with ESMTP id f22HNm157534; Fri, 2 Mar 2001 09:23:48 -0800 (PST) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: Date: Fri, 02 Mar 2001 09:22:52 -0800 (PST) From: John Baldwin To: Bruce Evans Subject: Re: cvs commit: src/sys/kern kern_intr.c Cc: cvs-all@FreeBSD.org, cvs-committers@FreeBSD.org Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 02-Mar-01 Bruce Evans wrote: > On Thu, 1 Mar 2001, John Baldwin wrote: > >> jhb 2001/03/01 22:07:39 PST >> >> Modified files: >> sys/kern kern_intr.c >> Log: >> Ok, the kernel will panic in kmem_malloc() if the kernel map is full, so >> malloc with M_WAITOK can't actually return NULL. I wish I could get two >> people to give me the same answer about this when I ask... > > Erm, this (non-returning of malloc with M_WAITOK) is clearly documented > in malloc.9. The panic is an implementation detail so it should not > be documented. Maybe we should have a Great Renaming for malloc() like > we did for mtx_enter() to get rid of the evil flags :-). Heh. So officially for the final and last time: malloc() can only return NULL if M_NOWAIT is specified. > Bruce -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.baldwin.cx/~john/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message