From owner-freebsd-emulation@FreeBSD.ORG Tue May 5 14:08:41 2009 Return-Path: Delivered-To: freebsd-emulation@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 131F31065674 for ; Tue, 5 May 2009 14:08:41 +0000 (UTC) (envelope-from alexander@leidinger.net) Received: from redbull.bpaserver.net (redbullneu.bpaserver.net [213.198.78.217]) by mx1.freebsd.org (Postfix) with ESMTP id B4A6A8FC18 for ; Tue, 5 May 2009 14:08:40 +0000 (UTC) (envelope-from alexander@leidinger.net) Received: from outgoing.leidinger.net (pD9E2E3AD.dip.t-dialin.net [217.226.227.173]) by redbull.bpaserver.net (Postfix) with ESMTP id C33DD2E0DC; Tue, 5 May 2009 16:08:33 +0200 (CEST) Received: from webmail.leidinger.net (webmail.leidinger.net [192.168.1.102]) by outgoing.leidinger.net (Postfix) with ESMTP id 8B3299E04D; Tue, 5 May 2009 16:08:28 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=Leidinger.net; s=outgoing-alex; t=1241532508; bh=Z7xslIyKQjTwC5x2PlCm4pqez+A86QZjuTlE+op/f7Q=; h=Message-ID:Date:From:To:Cc:Subject:References:In-Reply-To: MIME-Version:Content-Type:Content-Transfer-Encoding; b=ubaVytj4bIucMmxxr7jQP6K4yDM/aW158IwEO19mvP6S435RHBPLk/kvlXfVgNEbs 4eporhRchLtho2uIY3FvGp0+P4y3xMmjHeFwY/TdHGCmxYmUggWVSXUgJiCdkVjCX1 cQ/WMY0ExWVvEFo8Y8LchG99Zt5xTMBrvGilKsGsEyG64yjljAJzRzHKkxIsIbnT38 MmWP14ZSHHSpD1bSVwPhy2r4nFZINrhCpx0Oi7VOISG8zBqIZeDcuiZLJ1bmqcCZBF hWyU2ST+Fs0OScy05Ik3LZ3rxYiGwfShqWwdC+eXriuChwRiW+p+dcFkTqAp5NQQB6 UkToVGyOv6Dbw== Received: (from www@localhost) by webmail.leidinger.net (8.14.3/8.13.8/Submit) id n45E8SDG081350; Tue, 5 May 2009 16:08:28 +0200 (CEST) (envelope-from Alexander@Leidinger.net) Received: from pslux.cec.eu.int (pslux.cec.eu.int [158.169.9.14]) by webmail.leidinger.net (Horde Framework) with HTTP; Tue, 05 May 2009 16:08:27 +0200 Message-ID: <20090505160827.1359651x47bqmxc8@webmail.leidinger.net> X-Priority: 3 (Normal) Date: Tue, 05 May 2009 16:08:27 +0200 From: Alexander Leidinger To: Boris Samorodov References: <81924694@bb.ipt.ru> <20090505144955.16373k1b32dpaxo0@webmail.leidinger.net> <47993241@bb.ipt.ru> In-Reply-To: <47993241@bb.ipt.ru> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; DelSp="Yes"; format="flowed" Content-Disposition: inline Content-Transfer-Encoding: 7bit User-Agent: Internet Messaging Program (IMP) 4.3.3 / FreeBSD-8.0 X-BPAnet-MailScanner-Information: Please contact the ISP for more information X-MailScanner-ID: C33DD2E0DC.6200C X-BPAnet-MailScanner: Found to be clean X-BPAnet-MailScanner-SpamCheck: not spam, ORDB-RBL, SpamAssassin (not cached, score=-14.9, required 6, BAYES_00 -15.00, DKIM_SIGNED 0.00, DKIM_VERIFIED -0.00, RDNS_DYNAMIC 0.10) X-BPAnet-MailScanner-From: alexander@leidinger.net X-Spam-Status: No Cc: freebsd-emulation@FreeBSD.org Subject: Re: [linux-f10] linux_socketcall... ERR#43 'Protocol not supported' 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: Tue, 05 May 2009 14:08:41 -0000 Quoting Boris Samorodov (from Tue, 05 May 2009 17:44:54 +0400): > On Tue, 05 May 2009 14:49:55 +0200 Alexander Leidinger wrote: >> Quoting Boris Samorodov (from Tue, 05 May 2009 >> 09:51:21 +0400): > >> > I'm working on Fedora 10 ports and almost all is fine (even >> > google-earth seems to work)... But there is no resolving. >> > I managed to find the culprit. Here it is: > >> > Ktrace/linux_kdump gives this: >> > ----- >> > 48833 ping CALL linux_socketcall(0x1,0xbfbfd218) >> > 48833 ping RET linux_socketcall -1 errno 93 Unknown error: 93 >> > 48833 ping CALL gettimeofday(0xbfbfd2e0,0) >> > 48833 ping RET gettimeofday 0 >> > 48833 ping CALL linux_socketcall(0x1,0xbfbfd218) >> > 48833 ping RET linux_socketcall -1 errno 93 Unknown error: 93 >> > 48833 ping CALL write(0x2,0xbfbfbf48,0x1a) >> > 48833 ping GIO fd 2 wrote 26 bytes >> > "ping: unknown host www.ru >> > " >> > 48833 ping RET write 26/0x1a >> > 48833 ping CALL linux_exit_group(0x2) >> > ---- > >> There was a commit after April 30 about linux socket stuff. I don't >> know if it is related or not. You can either update and test, or > > Thanks for the info, I'm updating now. > >> instrument the current code to print out the parameters to >> linux_socketcall in a human readable way. > > Can you give a tiny example? orig: ---snip--- switch (args->what) { case LINUX_SOCKET: return (linux_socket(td, arg)); case LINUX_BIND: return (linux_bind(td, arg)); ---snip--- modified (ugly): ---snip--- switch (args->what) { case LINUX_SOCKET: int ret = linux_socket(td, arg); printf("LINUX_SOCKET: %d\n", ret); return (ret); case LINUX_BIND: return (linux_bind(td, arg)); ---snip--- After this you should see in ktrace which one it tries to call. Revert to the orig one and instrument the corresponding function, for linux_socket thish would be: ---snip--- linux_socket(struct thread *td, struct linux_socket_args *args) { #ifdef INET6 INIT_VNET_INET6(curvnet); #endif struct socket_args /* { int domain; int type; int protocol; } */ bsd_args; int retval_socket; /* debug for bsam */ printf("linux_socket (LINUX): domain: %d, type: %d, protocol: %d\n", args->domain, args->type, args->protocol); bsd_args.protocol = args->protocol; bsd_args.type = args->type; bsd_args.domain = linux_to_bsd_domain(args->domain); /* debug for bsam */ printf("linux_socket (FreeBSD): domain: %d\n", bsd_args.domain); if (bsd_args.domain == -1) return (EINVAL); ---snip--- Bye, Alexander. -- The six great gifts of an Irish girl are beauty, soft voice, sweet speech, wisdom, needlework, and chastity. -- Theodore Roosevelt, 1907 http://www.Leidinger.net Alexander @ Leidinger.net: PGP ID = B0063FE7 http://www.FreeBSD.org netchild @ FreeBSD.org : PGP ID = 72077137