From owner-freebsd-emulation@FreeBSD.ORG Sun Apr 28 15:24:53 2013 Return-Path: Delivered-To: emulation@freebsd.org Received: from mx1.freebsd.org (mx1.FreeBSD.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id 66BCA8AB for ; Sun, 28 Apr 2013 15:24:53 +0000 (UTC) (envelope-from chagin.dmitry@gmail.com) Received: from mail-lb0-f179.google.com (mail-lb0-f179.google.com [209.85.217.179]) by mx1.freebsd.org (Postfix) with ESMTP id DCD49191F for ; Sun, 28 Apr 2013 15:24:52 +0000 (UTC) Received: by mail-lb0-f179.google.com with SMTP id t1so5044821lbd.38 for ; Sun, 28 Apr 2013 08:24:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:sender:date:from:to:cc:subject:message-id:references :mime-version:content-type:content-disposition:in-reply-to :user-agent; bh=UK7T52EUynF521mny9geDHZTYZ9dJeAzBPKBDom+CSQ=; b=ES73PpTcXAxWVbrr0c/tguYM4ga4CzmXtpDbtArEa4ElXE8/vE5HPEDKjNBD037T+n rYV4tzBIqhBLomokfN6Pr/tXbfPLY4S208TBnF1ClKTikBwZofy86hggtetfzDcIRdUy 5XLAmfIHwb6ujYpCZAtqrmzdty2YBktD9wv3T7I8kJ4VssTTdxZHN0+Rpa6C2UqBK1jf tTz4oq8veBgRM4AWeZ0pRdEMf7/D0qO2v2wjsl2A+6uJyClNsdyFbTD/pW5BB7HGljLY jjecl/HtsK3BkJ2/cr/B8mLf9e9KDDGS1S6Na40cWrVct4/3Q/yiDyE94KINa9S0236Y UPIA== X-Received: by 10.112.74.233 with SMTP id x9mr1205977lbv.0.1367162686068; Sun, 28 Apr 2013 08:24:46 -0700 (PDT) Received: from dchagin.static.corbina.net (dchagin.static.corbina.ru. [78.107.232.239]) by mx.google.com with ESMTPSA id wc5sm7872644lbb.13.2013.04.28.08.24.44 for (version=TLSv1.2 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 28 Apr 2013 08:24:45 -0700 (PDT) Sender: Dmitry Chagin Received: from dchagin.static.corbina.net (localhost [127.0.0.1]) by dchagin.static.corbina.net (8.14.6/8.14.6) with ESMTP id r3SFOeEG044260; Sun, 28 Apr 2013 19:24:40 +0400 (MSK) (envelope-from dchagin@dchagin.static.corbina.net) Received: (from dchagin@localhost) by dchagin.static.corbina.net (8.14.6/8.14.6/Submit) id r3SFObei044259; Sun, 28 Apr 2013 19:24:37 +0400 (MSK) (envelope-from dchagin) Date: Sun, 28 Apr 2013 19:24:30 +0400 From: Chagin Dmitry To: Yuri Subject: Re: Linux linux_fcntl64 with F_GETLK is faulty? Message-ID: <20130428152430.GA44233@dchagin.static.corbina.net> References: <517CE41E.2020007@rawbw.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="k1lZvvs/B4yU6o8G" Content-Disposition: inline In-Reply-To: <517CE41E.2020007@rawbw.com> User-Agent: Mutt/1.5.21 (2010-09-15) Cc: emulation@freebsd.org X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Development of Emulators of other operating systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 28 Apr 2013 15:24:53 -0000 --k1lZvvs/B4yU6o8G Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sun, Apr 28, 2013 at 01:55:58AM -0700, Yuri wrote: > While running a linux 32-bit program on 9.1 amd64, I see these two lines= =20 > in truss log, and program also eventually fails: > linux_open("/some/file/name",0x40,0644) =3D 5 (0x5) > linux_fcntl64(0x5,0x7,0xffff8410,0xffff8410,0x2a988ff4,0x6) ERR#9 'Bad=20 > file descriptor' >=20 > cmd=3D0x7 is F_GETLK in linux. >=20 > Several questions with this: > 1. Why EBADF error is returned? fd=3D5 appears to be a valid descriptor= =20 > based on the presence of the previous open call. > 2. Is file locking not implemented in linux emulator? Is this related to= =20 > the issue when acrobat reader requires linux_adobe.ko kernel module and= =20 > also consumes 100% CPU all the time due to some workaround? >=20 > Theare are in make.conf of this system, if this matters: > OVERRIDE_LINUX_BASE_PORT=3Df10 > OVERRIDE_LINUX_NONBASE_PORTS=3Df10 >=20 Hi, Yuri. can u point me to the test program? --=20 Have fun! chd --k1lZvvs/B4yU6o8G Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.19 (FreeBSD) iEYEARECAAYFAlF9Py4ACgkQ0t2Tb3OO/O2ACwCgp5mPqIf8WJzxN8PODTdBt5Ub 8/UAmwQHDoIDCP/k56ujabIaUURZCQqX =djEU -----END PGP SIGNATURE----- --k1lZvvs/B4yU6o8G--