From owner-freebsd-emulation@FreeBSD.ORG Thu Mar 20 20:29:10 2008 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 AC259106564A for ; Thu, 20 Mar 2008 20:29:10 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from anti-4.kiev.sovam.com (anti-4.kiev.sovam.com [62.64.120.202]) by mx1.freebsd.org (Postfix) with ESMTP id 376518FC14 for ; Thu, 20 Mar 2008 20:29:10 +0000 (UTC) (envelope-from kostikbel@gmail.com) Received: from [212.82.216.226] (helo=skuns.kiev.zoral.com.ua) by anti-4.kiev.sovam.com with esmtps (TLSv1:AES256-SHA:256) (Exim 4.67) (envelope-from ) id 1JcRNr-0007bn-4G for freebsd-emulation@freebsd.org; Thu, 20 Mar 2008 22:29:08 +0200 Received: from deviant.kiev.zoral.com.ua (root@deviant.kiev.zoral.com.ua [10.1.1.148]) by skuns.kiev.zoral.com.ua (8.14.2/8.14.2) with ESMTP id m2KKT6kK000123 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 20 Mar 2008 22:29:06 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: from deviant.kiev.zoral.com.ua (kostik@localhost [127.0.0.1]) by deviant.kiev.zoral.com.ua (8.14.2/8.14.2) with ESMTP id m2KKSrMS057885; Thu, 20 Mar 2008 22:28:53 +0200 (EET) (envelope-from kostikbel@gmail.com) Received: (from kostik@localhost) by deviant.kiev.zoral.com.ua (8.14.2/8.14.2/Submit) id m2KKSqeO057884; Thu, 20 Mar 2008 22:28:52 +0200 (EET) (envelope-from kostikbel@gmail.com) X-Authentication-Warning: deviant.kiev.zoral.com.ua: kostik set sender to kostikbel@gmail.com using -f Date: Thu, 20 Mar 2008 22:28:52 +0200 From: Kostik Belousov To: Juergen Lock Message-ID: <20080320202852.GR10374@deviant.kiev.zoral.com.ua> References: <200803202015.m2KKFTBX080186@saturn.kn-bremen.de> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="F3mDA9xuPwJBqvPm" Content-Disposition: inline In-Reply-To: <200803202015.m2KKFTBX080186@saturn.kn-bremen.de> User-Agent: Mutt/1.4.2.3i X-Virus-Scanned: ClamAV version 0.91.2, clamav-milter version 0.91.2 on skuns.kiev.zoral.com.ua X-Virus-Status: Clean X-Spam-Status: No, score=-4.4 required=5.0 tests=ALL_TRUSTED,AWL,BAYES_00 autolearn=ham version=3.2.4 X-Spam-Checker-Version: SpamAssassin 3.2.4 (2008-01-01) on skuns.kiev.zoral.com.ua X-Scanner-Signature: 44556c58cf61beb49de4494ee559d59c X-DrWeb-checked: yes X-SpamTest-Envelope-From: kostikbel@gmail.com X-SpamTest-Group-ID: 00000000 X-SpamTest-Info: Profiles 2450 [Mar 20 2008] X-SpamTest-Info: helo_type=3 X-SpamTest-Info: {received from trusted relay: not dialup} X-SpamTest-Method: none X-SpamTest-Method: Local Lists X-SpamTest-Rate: 0 X-SpamTest-Status: Not detected X-SpamTest-Status-Extended: not_detected X-SpamTest-Version: SMTP-Filter Version 3.0.0 [0255], KAS30/Release Cc: freebsd-emulation@freebsd.org, olli@lurza.secnetix.de Subject: Re: qemu coredumps on RELENG_7 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: Thu, 20 Mar 2008 20:29:10 -0000 --F3mDA9xuPwJBqvPm Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Thu, Mar 20, 2008 at 09:15:29PM +0100, Juergen Lock wrote: > In article <200803181152.m2IBq0Ih012824@lurza.secnetix.de> you write: > >D Hill wrote: > > > Rick C. Petty wrote: > > > > Oliver Fromme wrote: > > > > > Kostik Belousov wrote: > > > > > >=20 > > > > > > Definitely, > > > > > > kldload aio > > > > > > before running qemu. > > > > >=20 > > > > > Thank you, that seems to solve the problem indeed. > > > > > Is that documented somewhere? It's not in the manpage. > > > > > I think it should be in the manpage ... would have > > > > > saved me quite some time. > > > >=20 > Actually it is also documented in the pkg-message of the port(s), but > apparently nobody reads that... (OK I could patch a pointer to that > into the manpage, do other ports do that?) >=20 > > > > Nope. It should be, or at least qemu should fail to start or at le= ast > > > > print a message instead of just randomly failing. > > > >Definitely. > > > > > > I ran into the same problem and only after spending hours trying to= get it > > > > to work did I remember to kldload aio. > > >=20 > > > I don't know if this applies. However, I found this in=20 > > > /usr/ports/UPDATING: > > >=20 > > > 20070206: > > > >It applies, but I think someone who installs qemu now > >isn't supposed to read UPDATING all the way back to > >February 2007. In fact, for fresh installs you should > >not have to read UPDATING _at_ _all_. > > > >Important information like this should be in the manual > >page, and -- as Rick pointed out -- the failure mode is > >pathetic. It should print a useful error message right > >at the start instead of randomly failing later. >=20 > Anyway, this was easier than I thought: (it didn't occur to me that > modfind(2) also finds modules that are statically linked into the kernel.= ..) >=20 > Index: qemu/vl.c > @@ -8423,6 +8423,12 @@ > nb_nics =3D 0; > /* default mac address of the first network interface */ > =20 > +#ifdef __FreeBSD__ > + loadmodules(0, "aio", NULL); > + if (modfind("aio") =3D=3D -1) > + fprintf(stderr, "warning: aio not (kld)loaded, may cause `Invali= d system call' traps on disk IO\n"); > +#endif > + > optind =3D 1; > for(;;) { > if (optind >=3D argc) >=20 > Would everybody be satisfied with this now? :) > Juergen Me not :). Better print the message without the module load attempt. --F3mDA9xuPwJBqvPm Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.8 (FreeBSD) iEYEARECAAYFAkfiyQMACgkQC3+MBN1Mb4iGoQCgzCXhS/MMAJoK/A/iG0zddXyf y3cAoJbnV7oPpvphuA9wCQqD5i7ujmOe =nY6Z -----END PGP SIGNATURE----- --F3mDA9xuPwJBqvPm--