From owner-freebsd-hackers@FreeBSD.ORG Tue Aug 26 08:20:33 2014 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 855628E3 for ; Tue, 26 Aug 2014 08:20:33 +0000 (UTC) Received: from mail-we0-x22f.google.com (mail-we0-x22f.google.com [IPv6:2a00:1450:400c:c03::22f]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 1B1F337F5 for ; Tue, 26 Aug 2014 08:20:32 +0000 (UTC) Received: by mail-we0-f175.google.com with SMTP id t60so14330174wes.20 for ; Tue, 26 Aug 2014 01:20:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-type:content-disposition:in-reply-to :user-agent; bh=a8WYs7Z328Y35diBXtcvkiLcQAGQPIXyy8puiBOsF2E=; b=JapyFYVMrMqMlDxJbEcaOgj7B29POAa3ZweidoWlompqbPo71sLx13eXehfmnYP7C0 73Om11PPwW51RABPpu7Zw74bS4tFJ3SEhyrX/izILsOKdWB5yCmN91JoCgkCJyy1rwLQ IxgISVHFReqDQBCy1VfL4W4yxzgkAIfpZ7SXs93My6kPyhlqcQwdkneG5mMSt0mUK8wu sdjjwcWVZrGUCbuYwOtveFAtIXuch0484PfMWb21AgCypKuueIi6g6vQA7AXV3CtqhKo lnkb5w4pnQVoxVi1H6kCepR4TFXhN901m8crLjm0ERqJ+Du3d+ka9NvvJh0yBFgLvGsO BFYQ== X-Received: by 10.180.210.231 with SMTP id mx7mr20060311wic.42.1409041231351; Tue, 26 Aug 2014 01:20:31 -0700 (PDT) Received: from dft-labs.eu (n1x0n-1-pt.tunnel.tserv5.lon1.ipv6.he.net. [2001:470:1f08:1f7::2]) by mx.google.com with ESMTPSA id xt6sm6341450wjc.14.2014.08.26.01.20.29 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Tue, 26 Aug 2014 01:20:30 -0700 (PDT) Date: Tue, 26 Aug 2014 10:20:27 +0200 From: Mateusz Guzik To: Konstantin Belousov Subject: Re: atomic_load_acq_int in sequential_heuristic Message-ID: <20140826082026.GD23088@dft-labs.eu> Mail-Followup-To: Mateusz Guzik , Konstantin Belousov , freebsd-hackers@freebsd.org References: <20140825005659.GA14344@dft-labs.eu> <20140825073404.GZ2737@kib.kiev.ua> <20140825081526.GB14344@dft-labs.eu> <20140825083539.GB2737@kib.kiev.ua> <20140825091056.GC14344@dft-labs.eu> <20140825111000.GC2737@kib.kiev.ua> <20140825130433.GD14344@dft-labs.eu> <20140825172755.GD2737@kib.kiev.ua> <20140825180417.GB23088@dft-labs.eu> <20140825193531.GE2737@kib.kiev.ua> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20140825193531.GE2737@kib.kiev.ua> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: freebsd-hackers@freebsd.org X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 26 Aug 2014 08:20:33 -0000 On Mon, Aug 25, 2014 at 10:35:31PM +0300, Konstantin Belousov wrote: > On Mon, Aug 25, 2014 at 08:04:17PM +0200, Mateusz Guzik wrote: > > > I do think that there is bug in the "-1" stuff, but it is in compat32 > > > shims. The compat/freebsd32/syscalls.master does not provide the compat > > > for fcntl(2), which means that 32bit fcntl(2) does not work when either > > > signed extension is needed (the F_READAHEAD case), or on the big-endian > > > machines. On i386, it did not practically matter before F_READAHEAD, > > > since x86 is little-endian and flags passed as arg did not touch the > > > sign bit. > > > > > > Note that fcntl(2) man page is wrong, it claims that optional argument > > > arg is int. It cannot be true since pointer on LP64 platform cannot > > > fit into int. The SUSv4 is explicit in describing which command > > > takes which type; our man page must be fixed, but this is for later. > > > > > > See the patch at the end of the reply for the fix. It needs sysent > > > regen for actual build. > > > > > > > I tested the patch and it fixes the problem. > Which patch ? Your's or mine ? > Yours, apart from mine. I committed my patch as r270648. -- Mateusz Guzik