From owner-freebsd-hackers@FreeBSD.ORG Wed Jan 3 12:48:50 2007 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E654716A403 for ; Wed, 3 Jan 2007 12:48:50 +0000 (UTC) (envelope-from xdivac02@stud.fit.vutbr.cz) Received: from eva.fit.vutbr.cz (eva.fit.vutbr.cz [147.229.176.14]) by mx1.freebsd.org (Postfix) with ESMTP id 7D68713C469 for ; Wed, 3 Jan 2007 12:48:50 +0000 (UTC) (envelope-from xdivac02@stud.fit.vutbr.cz) Received: from eva.fit.vutbr.cz (localhost [127.0.0.1]) by eva.fit.vutbr.cz (envelope-from xdivac02@eva.fit.vutbr.cz) (8.13.8/8.13.7) with ESMTP id l03CLcLW076289 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 3 Jan 2007 13:21:38 +0100 (CET) Received: (from xdivac02@localhost) by eva.fit.vutbr.cz (8.13.8/8.13.3/Submit) id l03CLYZD076280; Wed, 3 Jan 2007 13:21:34 +0100 (CET) Date: Wed, 3 Jan 2007 13:21:34 +0100 From: Divacky Roman To: Intron is my alias on the Internet Message-ID: <20070103122134.GA74544@stud.fit.vutbr.cz> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.2i X-Scanned-By: MIMEDefang 2.57 on 147.229.176.14 Cc: freebsd-hackers@freebsd.org Subject: Re: Partially Unbreak Adobe Reader 7.0.8 for the New Linux Emulator 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: Wed, 03 Jan 2007 12:48:51 -0000 On Wed, Jan 03, 2007 at 07:47:28AM +0800, Intron is my alias on the Internet wrote: > My patch for /sys/compat/linux/linux_file.c (7.0-CURRENT) can > partially unbreak Adobe Reader 7.0.8 for Linux when the sysctl > compat.linux.osrelease is set to "2.6.16". You may download the patch > at: > > http://ftp.intron.ac/tmp/linux_file.c.diff this looks good. can you explain why this patch is not needed in 2.4 emulation? I cannot imagine why this differs in 2.6 and 2.4... does this cause the different read output I told you about? > But probably to your disappointment, the problem hasn't been > completely solved yet. Even after you have applied my patch (Don't > forget to set compat.linux.osrelease to "2.6.16"), you must remove > the directory ~/.adobe before you start Adobe Reader 7.0.8 every time, > otherwise the PDF file cannot be properly browsed. > > I have noticed that the calling behavior against the Linux > system call mmap2(2) is strange: > > 1658: linux_mmap2(0x0,0x8974,0x1,0x1,0x0,0x6) = 790032384 (0x2f16f000) > 1658: linux_mmap2(0x0,0x8fd8,0x1,0x1,0x0,0x6) = 790032384 (0x2f16f000) > 1658: linux_mmap2(0x0,0x8974,0x1,0x1,0x0,0x6) = 790032384 (0x2f16f000) > 1658: linux_mmap2(0x0,0x1000,0x3,0x22,0xffffffff,0x6) = 790069248 > (0x2f178000) > 1658: linux_mmap2(0x0,0x1000,0x3,0x22,0xffffffff,0x6) = 790069248 > (0x2f178000) > 1658: linux_mmap2(0x0,0x8fd8,0x1,0x1,0x0,0x6) = 790032384 (0x2f16f000) > 1658: linux_mmap2(0x0,0x8974,0x1,0x1,0x0,0x6) = 790032384 (0x2f16f000) > 1658: linux_mmap2(0x0,0x8a78,0x1,0x1,0x0,0x6) = 790032384 (0x2f16f000) > 1658: linux_mmap2(0x0,0x8974,0x1,0x1,0x0,0x6) = 790032384 (0x2f16f000) > > The last calling argument is always stupid 6, which doesn't agree with > the calling behavior against mmap(2) when compat.linux.osrelease is set > to 2.4.2. This probably means that all files mapped by mmap2(2) cannot be > properly read from memory space. well.. the last argument is pgoff which sets an offset. I dont see anything particularly wrong with this. why do you think its bad? anyway.. thnx for the patch! roman