From owner-freebsd-emulation@FreeBSD.ORG Fri Nov 18 13:41:10 2005 Return-Path: X-Original-To: freebsd-emulation@freebsd.org Delivered-To: freebsd-emulation@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 761A416A41F for ; Fri, 18 Nov 2005 13:41:10 +0000 (GMT) (envelope-from gwk@rahn-koltermann.de) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.190]) by mx1.FreeBSD.org (Postfix) with ESMTP id D4D0843D5D for ; Fri, 18 Nov 2005 13:41:03 +0000 (GMT) (envelope-from gwk@rahn-koltermann.de) Received: from [212.227.126.202] (helo=mrvnet.kundenserver.de) by moutng.kundenserver.de with esmtp (Exim 3.35 #1) id 1Ed6UA-0005vu-00 for freebsd-emulation@freebsd.org; Fri, 18 Nov 2005 14:41:02 +0100 Received: from [172.23.4.155] (helo=pustefix155.kundenserver.de) by mrvnet.kundenserver.de with esmtp (Exim 3.35 #1) id 1Ed6UA-0000iG-00 for freebsd-emulation@freebsd.org; Fri, 18 Nov 2005 14:41:02 +0100 Message-Id: <15222648.443191132321262768.JavaMail.servlet@kundenserver> From: gwk@rahn-koltermann.de To: MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_6417_428147.1132321262767" X-Priority: 3 X-Binford: 6100 (more power) X-Mailer: Webmail X-Originating-From: 27942123 X-Routing: DE X-Message-Id: <27942123$1132321262767172.23.4.15527331543@pustefix155.kundenserver.de-1957880801> X-Received: from pustefix155.kundenserver.de by 212.94.231.151 with HTTP id 27942123 for [freebsd-emulation@freebsd.org]; Fri, 18 Nov 2005 14:41:02 CET Date: Fri, 18 Nov 2005 14:41:02 +0100 X-Provags-ID: kundenserver.de abuse@kundenserver.de ident:@172.23.4.155 Subject: how to get VMWare2 to work on 6.0-R (Unable to fix standard file descriptors) X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.5 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: Fri, 18 Nov 2005 13:41:10 -0000 ------=_Part_6417_428147.1132321262767 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Hi, after upgrading to 6.0-R recently I am having trouble with VMWare2. First problem: it doesn't compile. Well, after some research on the web and borrowing from VMWare3 patches fbsd6-1.patch and fbsd6-2.patch I came up with the attached diffs that made it compile. Second problem: it won't run. The error message is "Unable to fix standard file descriptors." Period. Any ideas? Is it working for anyone else out there? -- Regards, Georg. ------=_Part_6417_428147.1132321262767 Content-Type: application/octet-stream; name=gwk.patch Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=gwk.patch diff -ur work/vmware-distrib/vmmon-only/freebsd/driver.c work.gwk/vmware-distrib/vmmon-only/freebsd/driver.c --- work/vmware-distrib/vmmon-only/freebsd/driver.c Fri Nov 18 14:34:08 2005 +++ work.gwk/vmware-distrib/vmmon-only/freebsd/driver.c Thu Nov 17 16:35:54 2005 @@ -164,8 +164,7 @@ .d_close = FreeBSD_Driver_Close, .d_ioctl = FreeBSD_Driver_Ioctl, .d_poll = FreeBSD_Driver_Poll, - .d_name = DEVICE_NAME, - .d_maj = CDEV_MAJOR + .d_name = DEVICE_NAME #else /* open */ FreeBSD_Driver_Open, /* close */ FreeBSD_Driver_Close, @@ -285,7 +284,6 @@ static int cleanup_module(void) { - int retval=0; destroy_dev(vmmon_dev); #if __FreeBSD_version < 500104 diff -ur work/vmware-distrib/vmmon-only/freebsd/hostif.c work.gwk/vmware-distrib/vmmon-only/freebsd/hostif.c --- work/vmware-distrib/vmmon-only/freebsd/hostif.c Fri Nov 18 14:34:08 2005 +++ work.gwk/vmware-distrib/vmmon-only/freebsd/hostif.c Thu Nov 17 16:36:13 2005 @@ -337,7 +337,7 @@ if (!(val & mask)) { val = val | mask; - outb(val,0xA1); + outbv(val,0xA1); } } @@ -1105,12 +1105,12 @@ rc = vm_fault_quick(addr, VM_PROT_READ|VM_PROT_WRITE); if (rc<0) { /* page don't present in map */ Warning("KernelAddr_Get!!! Addr %p not present\n", addr); - return NULL; + return 0; } paddr = vtophys(addr); #if __FreeBSD_version >= 500038 GIANT_REQUIRED; - ka->kaddr = kmem_alloc_pageable(kernel_map, PAGE_SIZE); + ka->kaddr = kmem_alloc_nofault(kernel_map, PAGE_SIZE); ka->map = PHYS_TO_VM_PAGE(paddr); vm_page_lock_queues(); vm_page_wire(ka->map); ------=_Part_6417_428147.1132321262767--