From owner-freebsd-stable@FreeBSD.ORG Mon Sep 8 02:21:34 2003 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 2B4A016A4BF; Mon, 8 Sep 2003 02:21:34 -0700 (PDT) Received: from totem.fix.no (totem.fix.no [80.91.36.20]) by mx1.FreeBSD.org (Postfix) with ESMTP id C940243FFD; Mon, 8 Sep 2003 02:21:32 -0700 (PDT) (envelope-from anders@FreeBSD.org) Received: by totem.fix.no (Postfix, from userid 1000) id AF8A820247; Mon, 8 Sep 2003 11:21:55 +0200 (CEST) Date: Mon, 8 Sep 2003 11:21:55 +0200 From: Anders Nordby To: "Brandon S. Allbery KF8NH" Message-ID: <20030908092155.GC28554@totem.fix.no> References: <200308241114.h7OBETsI004360@pyanfar.ece.cmu.edu> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="AhhlLboLdkugWU4S" Content-Disposition: inline In-Reply-To: <200308241114.h7OBETsI004360@pyanfar.ece.cmu.edu> X-PGP-Key: http://anders.fix.no/pgp/ X-PGP-Key-FingerPrint: 1E0F C53C D8DF 6A8F EAAD 19C5 D12A BC9F 0083 5956 User-Agent: Mutt/1.5.1i cc: stable@FreeBSD.org cc: FreeBSD-gnats-submit@FreeBSD.org cc: jake@FreeBSD.org cc: luoqi@FreeBSD.org cc: vsilyaev@mindspring.com Subject: Re: ports/55928: vmware2 broken on -STABLE, presumably by PAE import X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 08 Sep 2003 09:21:34 -0000 --AhhlLboLdkugWU4S Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi, On Sun, Aug 24, 2003 at 07:14:29AM -0400, Brandon S. Allbery KF8NH wrote: > >Synopsis: vmware2 broken on -STABLE, presumably by PAE import >> (..) Your patch makes VmWare2 build, but it doesn't make it work: - VmWare fails to allocate memory (see http://anders.fix.no/test/vmware/1.png and http://anders.fix.no/test/vmware/2.png). - There seems to be something wrong with vmmon, some error messages are reported to my console log: Console log for noname.aftenposten.no /dev/vmmon: HostIF_LockPage vpn=0x048a65 mpn=000000 already tracked Sep 8 10:07:54 noname /kernel: /dev/vmmon: HostIF_LockPage vpn=0x048a65 mpn=000000 already tracked /dev/vmmon: HostIF_LockPage vpn=0x048a65 mpn=000000 already tracked /dev/vmmon: HostIF_LockPage vpn=0x048a65 mpn=000000 already tracked /dev/vmmon: HostIF_LockPage vpn=0x048a65 mpn=000000 already tracked /dev/vmmon: HostIF_LockPage vpn=0x048a65 mpn=000000 already tracked Sep 8 10:07:58 noname last message repeated 4 times Oh, and FreeBSD gets unstable with these patches of yours. I've seen several hard hangs. I cleaned up the patch to be relative to the current port (patch attached). I'm applying your patch (pmap.patch-stable) if OSVERSION is less than 500000, and higher or equal to 480101 (which was used at the time of the PAE MFC). For those on the Cc: list, I added you because you committed PAE/pmap things, are on the -stable list or maintain the vmware2 port. :) Any tips or improvements to the patch to make VmWare2 work in FreeBSD again is very welcome. If we want VmWare supported in -stable at all (4.9 being right around the corner and all), this must be dealt with ASAP. Feel free to use me for testing your suggestions. Cheers, -- Anders. --AhhlLboLdkugWU4S Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="vmware2.diff" diff -Nur vmware2.old/Makefile vmware2/Makefile --- vmware2.old/Makefile Sun Apr 13 11:55:43 2003 +++ vmware2/Makefile Mon Sep 8 09:22:11 2003 @@ -99,6 +99,8 @@ .endif .if ${OSVERSION} >= 500027 ${CAT} ${FILESDIR}/pmap.patch | (cd ${WRKSRC} && patch) > /dev/null 2>&1 +.elseif ${OSVERSION} < 500000 && ${OSVERSION} >= 480101 + ${CAT} ${FILESDIR}/pmap.patch-stable | (cd ${WRKSRC} && patch) > /dev/null 2>&1 .endif ${CP} ${FILESDIR}/Makefile ${WRKSRC} ${CP} ${FILESDIR}/Makefile.vmmon ${WRKSRC}/vmmon-only/Makefile diff -Nur vmware2.old/files/pmap.patch-stable vmware2/files/pmap.patch-stable --- vmware2.old/files/pmap.patch-stable Thu Jan 1 01:00:00 1970 +++ vmware2/files/pmap.patch-stable Mon Sep 8 09:17:55 2003 @@ -0,0 +1,16 @@ +--- vmmon-only/freebsd/hostif.c.orig Mon Sep 8 09:10:39 2003 ++++ vmmon-only/freebsd/hostif.c Mon Sep 8 09:11:28 2003 +@@ -181,11 +181,11 @@ + { + #define DEB(x) + caddr_t addr = (caddr_t)VPN_2_VA(ppn); +- pt_entry_t pteptr = (pt_entry_t)vtopte(addr); ++ pt_entry_t pteptr = (pt_entry_t)vtopte((unsigned long) addr); + PTE pte; + + DEB(printf("FindMPN: for page %d address %p(phys %p) pteptr %p", ppn, addr, (caddr_t)vtophys(addr), pteptr)); +- pte=*pteptr; ++ pte=*((caddr_t)pteptr); + DEB(printf("(0x%08x)\n", pte)); + if (pte & PTE_P) { + return PTE_2_PFN(pte); --AhhlLboLdkugWU4S--