From owner-freebsd-hackers@FreeBSD.ORG Tue Sep 22 07:28:50 2009 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A72501065670 for ; Tue, 22 Sep 2009 07:28:50 +0000 (UTC) (envelope-from is@rambler-co.ru) Received: from mailrelay1.rambler.ru (mailrelay1.rambler.ru [81.19.66.239]) by mx1.freebsd.org (Postfix) with ESMTP id 58ABF8FC14 for ; Tue, 22 Sep 2009 07:28:50 +0000 (UTC) Received: from kas30pipe.localhost (localhost [127.0.0.1]) by mailrelay1.rambler.ru (Postfix) with ESMTP id 3D0D1130CBA; Tue, 22 Sep 2009 11:28:49 +0400 (MSD) Received: from localhost (www290.rambler.ru [10.9.0.148]) by mailrelay1.rambler.ru (Postfix) with ESMTP id D236F130CB8; Tue, 22 Sep 2009 11:28:48 +0400 (MSD) Date: Tue, 22 Sep 2009 11:28:48 +0400 From: Igor Sysoev To: Kostik Belousov Message-ID: <20090922072848.GA727@rambler-co.ru> References: <20090917101526.GF57619@rambler-co.ru> <4AB2B7A1.5000601@delphij.net> <20090918074027.GI47688@deviant.kiev.zoral.com.ua> <20090921111245.GB23958@rambler-co.ru> <20090921112909.GQ47688@deviant.kiev.zoral.com.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Disposition: inline In-Reply-To: <20090921112909.GQ47688@deviant.kiev.zoral.com.ua> User-Agent: Mutt/1.5.20 (2009-06-14) X-Anti-Virus: Kaspersky Anti-Virus for MailServers 5.5.33/RELEASE, bases: 02092009 #2738642, status: clean X-SpamTest-Envelope-From: is@rambler-co.ru X-SpamTest-Group-ID: 00000000 X-SpamTest-Info: Profiles 9536 [Sen 02 2009] X-SpamTest-Info: {received from trusted relay: common white list} X-SpamTest-Method: white ip list X-SpamTest-Rate: 0 X-SpamTest-Status: Trusted X-SpamTest-Status-Extended: trusted X-SpamTest-Version: SMTP-Filter Version 3.0.0 [0284], KAS30/Release Cc: freebsd-hackers@freebsd.org, d@delphij.net Subject: Re: fcntl(F_RDAHEAD) X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Sep 2009 07:28:50 -0000 On Mon, Sep 21, 2009 at 02:29:09PM +0300, Kostik Belousov wrote: > On Mon, Sep 21, 2009 at 03:12:45PM +0400, Igor Sysoev wrote: > > > What I dislike about the patch is the new kernel-private flag that is > > > eaten from the open(2) flags namespace. We do already have FHASLOCK, > > > so far the only such flag. > > > > We can change > > int f_seqcount; > > to > > u_int f_seqcount; > > > > and can use highest bit instead of O_READAHEAD: anyway f_seqcount is shifted > > to 16 bits left. > > Or do the same trick as was done for FHASLOCK and override some flag that > is not saved after open, see FMASK. > > Or split f_seqcount into two u_short fields, one for f_seqcount, second for > f_kflag, and use the later for FHASLOCK and FREADAHEAD. [We are trying to > not grow struct file unless absolutely neccessary]. I agree that struct file should not grow (at least in this case). However, I believe splitting f_seqcount into two fields will break kernel ABI. Or not ? I think f_seqcount should be splitted in 9-CURRENT and probably, in 8-STABLE, but in 7-STABLE we may use the open(2) flags namespace. -- Igor Sysoev http://sysoev.ru/en/