From owner-cvs-src@FreeBSD.ORG Wed Jun 21 17:58:29 2006 Return-Path: X-Original-To: cvs-src@FreeBSD.org Delivered-To: cvs-src@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C961616A474; Wed, 21 Jun 2006 17:58:29 +0000 (UTC) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (gate.funkthat.com [69.17.45.168]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4D24043D5A; Wed, 21 Jun 2006 17:58:29 +0000 (GMT) (envelope-from jmg@hydrogen.funkthat.com) Received: from hydrogen.funkthat.com (pg20kx6wjdjyn8wm@localhost.funkthat.com [127.0.0.1]) by hydrogen.funkthat.com (8.13.6/8.13.3) with ESMTP id k5LHwNsm084618; Wed, 21 Jun 2006 10:58:23 -0700 (PDT) (envelope-from jmg@hydrogen.funkthat.com) Received: (from jmg@localhost) by hydrogen.funkthat.com (8.13.6/8.13.3/Submit) id k5LHwLMJ084617; Wed, 21 Jun 2006 10:58:21 -0700 (PDT) (envelope-from jmg) Date: Wed, 21 Jun 2006 10:58:21 -0700 From: John-Mark Gurney To: Alan Cox Message-ID: <20060621175821.GB82074@funkthat.com> References: <200606211259.k5LCx5as082227@repoman.freebsd.org> <20060621172849.GA82074@funkthat.com> <44998562.6080705@cs.rice.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <44998562.6080705@cs.rice.edu> User-Agent: Mutt/1.4.2.1i X-Operating-System: FreeBSD 5.4-RELEASE-p6 i386 X-PGP-Fingerprint: B7 EC EF F8 AE ED A7 31 96 7A 22 B3 D8 56 36 F4 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html Cc: cvs-src@FreeBSD.org, src-committers@FreeBSD.org, Konstantin Belousov , cvs-all@FreeBSD.org Subject: Re: cvs commit: src/lib/libc/sys mincore.2 src/sys/vm vm_mmap.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: John-Mark Gurney List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Jun 2006 17:58:29 -0000 Alan Cox wrote this message on Wed, Jun 21, 2006 at 12:44 -0500: > John-Mark Gurney wrote: > > >Konstantin Belousov wrote this message on Wed, Jun 21, 2006 at 12:59 +0000: > > > >> Modified files: > >> lib/libc/sys mincore.2 > >> sys/vm vm_mmap.c > >> Log: > >> Make the mincore(2) return ENOMEM when requested range is not fully > >> mapped. > > > >Is this change to be posix compliant or something? ENOMEM seems like > >the wrong error, or are we allocating memory? > >#define ENOMEM 12 /* Cannot allocate memory */ > > > >the original EINVAL seems to me the correct one, as is commonly used > >when the data passed in is incorrect... > > I looked at this when the patch was proposed. ENOMEM is the de facto > standard error for this case. To the best of my knowledge, there is no > officially-sanctioned specification for mincore(2). Could you please provide a reference to this de facto standard error as in other places where ENOMEM is used for such an error? -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not."