From nobody@FreeBSD.org  Mon Mar 13 17:20:25 2006
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id A81C716A4A6
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 13 Mar 2006 17:20:24 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 5A8A943D55
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 13 Mar 2006 17:20:24 +0000 (GMT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.13.1/8.13.1) with ESMTP id k2DHKOUD076649
	for <freebsd-gnats-submit@FreeBSD.org>; Mon, 13 Mar 2006 17:20:24 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.13.1/8.13.1/Submit) id k2DHKOVm076648;
	Mon, 13 Mar 2006 17:20:24 GMT
	(envelope-from nobody)
Message-Id: <200603131720.k2DHKOVm076648@www.freebsd.org>
Date: Mon, 13 Mar 2006 17:20:24 GMT
From: Xavier <xotazu@users.sourceforge.net>
To: freebsd-gnats-submit@FreeBSD.org
Subject: kern.maxdsiz and (failed) section relocation
X-Send-Pr-Version: www-2.3

>Number:         94413
>Category:       kern
>Synopsis:       [kernel] wine fails when increasing kern.maxdsiz
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Mar 13 17:21:00 GMT 2006
>Closed-Date:    Tue Feb 05 15:49:12 UTC 2008
>Last-Modified:  Tue Feb 05 15:49:12 UTC 2008
>Originator:     Xavier
>Release:        6.0
>Organization:
CVC
>Environment:
FreeBSD cvc131.uab.es 6.0-RELEASE FreeBSD 6.0-RELEASE #0: Thu Nov  3 09:36:13 UTC 2005     root@x64.samsco.home:/usr/obj/usr/src/sys/GENERIC  i386
>Description:
When changing the kern.maxdsiz ont the /boot/loader.conf file, wine crashes.

My actual value is kern.maxdsiz="1024M". Higher memory values for this parameter also crashes wine.

When not changing this value in the loader.conf file (datasize is the default 512 Mb) wine runs fine.

Wine 0.9.7
>How-To-Repeat:
Defining kern.maxdsiz="1024M" in the /boot/loader.conf
>Fix:

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->gerald 
Responsible-Changed-By: edwin 
Responsible-Changed-When: Mon Mar 13 20:12:48 UTC 2006 
Responsible-Changed-Why:  
Over to maintainer 

http://www.freebsd.org/cgi/query-pr.cgi?pr=94413 

From: "Li-Lun Wang (Leland Wang)" <llwang@infor.org>
To: bug-followup@FreeBSD.org, xotazu@users.sourceforge.net
Cc:  
Subject: Re: ports/94413: wine fails when increasing kern.maxdsiz
Date: Fri, 24 Mar 2006 05:00:41 +0800

 -----BEGIN PGP SIGNED MESSAGE-----
 Hash: SHA1
 
 Hi,
 
 I think this is not really a wine-specific bug.
 This is due to (failed) section relocation.
 To produce the very same effect, I used a dummy test.c:
 
 int main(void)
 {   
     return 0;
 }
 
 and compiled with
 
 	cc -Wl,--section-start,.interp=0x7bf00400 test.c
 
 If it is run when I enlarge kern.maxdsiz in loader.conf,
 it always produces
 
 	ELF interpreter /libexec/ld-elf.so.1 not found
 
 I don't know why kern.maxdsiz should affects this, though.
 
 - -- Li-Lun Wang
 -----BEGIN PGP SIGNATURE-----
 Version: GnuPG v1.4.2.1 (FreeBSD)
 
 iD8DBQFEIwx4CQM7t5B2mhARAr2NAJ9Su5VXM/2rYqjc/o5BREDfFZS3iQCePuzJ
 XuONLlg/d1kJBh2vqhGBGz8=
 =gnLa
 -----END PGP SIGNATURE-----
Responsible-Changed-From-To: gerald->freebsd-bugs 
Responsible-Changed-By: gerald 
Responsible-Changed-When: Fri Mar 24 06:10:55 UTC 2006 
Responsible-Changed-Why:  


http://www.freebsd.org/cgi/query-pr.cgi?pr=94413 

From: Gerald Pfeifer <gerald@pfeifer.com>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: ports/94413: wine fails when increasing kern.maxdsiz
Date: Sun, 2 Apr 2006 09:11:01 +0200 (CEST)

 Note: the reason I moved this from emulators/wine to a general
 bug is the previous comment which indicates the issue is not really
 specific to Wine, but to the basesystem.
 
 Gerald

From: Tijl Coosemans <tijl@ulyssis.org>
To: bug-followup@freebsd.org
Cc: gerald@pfeifer.com
Subject: Re: kern/94413: [kernel] wine fails when increasing kern.maxdsiz
Date: Thu, 3 Aug 2006 14:46:14 +0200

 The problem is that mmap(2), when called with NULL for the addr 
 argument, only looks for free pages after the maximum data segment. 
 Given that Wine is located at the end of the first 2Gb of address space 
 (to leave room for the Windows executable), plus a maximum data segment 
 size of 1Gb, you're simply running out of user address space.
 
 There's a comment in the mmap code hinting at how this can be improved, 
 but really I don't think mmap should change (i.e. become more 
 complicated just for Wine). I'm not 100% sure, but I believe the 
 problem can be fixed by porting the Wine preloader and have it lower 
 the maximum RLIMIT_DATA.

From: Tijl Coosemans <tijl@ulyssis.org>
To: bug-followup@freebsd.org, xotazu@users.sourceforge.net
Cc:  
Subject: Re: kern/94413: [kernel] wine fails when increasing kern.maxdsiz
Date: Sat, 15 Sep 2007 18:17:42 +0200

 This should be fixed with Wine 0.9.45 in ports now. Can somebody
 confirm this, so the PR can be closed?

From: Daniel Rucci <dan@rucci.org>
To: bug-followup@FreeBSD.org, xotazu@users.sourceforge.net
Cc:  
Subject: Re: kern/94413: [kernel] wine fails when increasing kern.maxdsiz
Date: Sun, 13 Jan 2008 05:00:30 -0500

 7.0-PRERELEASE i386 #13: Sun Jan 13 02:15:23 EST 2008
 
 rucci@smurfbsd$ wine --version
 wine-0.9.52
 
 rucci@smurfbsd$ tail -1 /boot/loader.conf
 kern.maxdsiz="1024M"
 
 *reboot*
 
 winemine runs (I just got a high score)
 wine Ventrillo.exe runs
 wine notepad.exe runs
 
 not seeing a crash
 
 This PR seems similar to kern/86207 so i'll run the commands he 
 mentioned as well:
 
 rucci@smurfbsd$ ldd `which wine`
 /usr/local/bin/wine:
 	libwine.so.1 => /usr/local/lib/libwine.so.1 (0x4807d000)
 	libthr.so.3 => /lib/libthr.so.3 (0x48191000)
 	libc.so.7 => /lib/libc.so.7 (0x481a4000)
 but note that he was complaining about values > 1GB and I am right at that.
 
 Dan
 

From: Tijl Coosemans <tijl@ulyssis.org>
To: bug-followup@freebsd.org
Cc: gerald@pfeifer.com
Subject: Re: kern/94413: [kernel] wine fails when increasing kern.maxdsiz
Date: Tue, 5 Feb 2008 14:35:35 +0100

 Thanks Daniel. That means this PR and kern/86207 (duplicate) can be
 closed.
State-Changed-From-To: open->closed 
State-Changed-By: linimon 
State-Changed-When: Tue Feb 5 15:46:14 UTC 2008 
State-Changed-Why:  
This is believed to be fixed in the current version of Wine. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=94413 
>Unformatted:
