From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964949AbWGFQ2I (ORCPT ); Thu, 6 Jul 2006 12:28:08 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S965109AbWGFQ2H (ORCPT ); Thu, 6 Jul 2006 12:28:07 -0400 Received: from mail6.sea5.speakeasy.net ([69.17.117.8]:47807 "EHLO mail6.sea5.speakeasy.net") by vger.kernel.org with ESMTP id S964949AbWGFQ2G (ORCPT ); Thu, 6 Jul 2006 12:28:06 -0400 Date: Thu, 6 Jul 2006 09:28:05 -0700 (PDT) From: Vadim Lobanov To: Ulrich Drepper cc: Andrew Morton , linux-kernel@vger.kernel.org Subject: Re: [PATCH] Fix poll() nfds check. In-Reply-To: Message-ID: References: <20060705203959.53e128ef.akpm@osdl.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 6 Jul 2006, Ulrich Drepper wrote: > On 7/5/06, Andrew Morton wrote: > > [EINVAL] > > The nfds argument is greater than {OPEN_MAX}, or ... > > This requirement must be treated the same way as the EMFILE error in > open(): ignore the OPEN_MAX limit if ulimit says so. The question is > what to do if the ulimit < OPEN_MAX. POSIX does not require OPEN_MAX > to be the exact limit. This interpretation makes more sense to me. No hardcoded magic number limits where the behavior of the syscall changes. > So, I think removing the OPEN_MAX comparison is the correct way to do > this here. If somebody wants strict POSIX compliance they have to set > ulimit -n to 256. Andrew, assuming that you're willing to make this change to the code, I can redo this patch against the latest rc and resend, if that'll make it easier to apply. -- Vadim Lobanov