Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HJAhq-0000J8-IB for qemu-devel@nongnu.org; Mon, 19 Feb 2007 10:45:34 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HJAho-0000Ik-75 for qemu-devel@nongnu.org; Mon, 19 Feb 2007 10:45:33 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HJAho-0000Ih-1q for qemu-devel@nongnu.org; Mon, 19 Feb 2007 10:45:32 -0500 Received: from partizan.velesys.com ([213.184.230.195]) by monty-python.gnu.org with esmtp (Exim 4.52) id 1HJAhn-0004Xf-Gf for qemu-devel@nongnu.org; Mon, 19 Feb 2007 10:45:31 -0500 Received: from localhost (partizan [10.0.0.24]) by partizan.velesys.com (paritzan.velesys.com) with ESMTP id F38C1D63249 for ; Mon, 19 Feb 2007 17:47:34 +0200 (EET) Received: from partizan.velesys.com ([10.0.0.24]) by localhost (partizan.velesys.com [10.0.0.24]) (amavisd-new, port 10024) with ESMTP id Oz9UJpNq+RyE for ; Mon, 19 Feb 2007 17:47:31 +0200 (EET) Received: from localhost.localdomain (mm-110-150-57-86.adsl.mgts.by [86.57.150.110]) by partizan.velesys.com (paritzan.velesys.com) with ESMTP id B8F32D632D5 for ; Mon, 19 Feb 2007 17:47:30 +0200 (EET) Date: Mon, 19 Feb 2007 17:45:31 +0300 From: "Kirill A. Shutemov" Message-ID: <20070219144531.GJ25556@localhost.localdomain> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="PtLnLSExlPr13a2X" Content-Disposition: inline Subject: [Qemu-devel] [PATCH] syscall clock_gettime Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org --PtLnLSExlPr13a2X Content-Type: multipart/mixed; boundary="nb8zVy0QMK3AA1xu" Content-Disposition: inline --nb8zVy0QMK3AA1xu Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Patch from Debian patchset in the attachment. --nb8zVy0QMK3AA1xu Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=31_syscall_clock_gettime Content-Transfer-Encoding: quoted-printable --- linux-user/syscall.c.orig 2006-11-05 07:07:19.000000000 +0200 +++ linux-user/syscall.c 2006-11-05 07:07:25.000000000 +0200 @@ -3972,6 +3982,22 @@ long do_syscall(void *cpu_env, int num,=20 case TARGET_NR_getdomainname: goto unimplemented_nowarn; #endif +#ifdef TARGET_NR_clock_gettime + case TARGET_NR_clock_gettime: + { + struct target_timespec* ttp =3D (struct target_timespec*)arg2; + struct timespec htp; + if(ttp) { + htp.tv_sec =3D tswapl(ttp->tv_sec); + htp.tv_nsec =3D tswapl(ttp->tv_nsec); + ret =3D get_errno(clock_gettime((clockid_t)arg1, &htp)); + ttp->tv_sec =3D tswapl(htp.tv_sec); + ttp->tv_nsec =3D tswapl(htp.tv_nsec); + } else + ret =3D get_errno(clock_gettime((clockid_t)arg1, NULL)); + break; + } +#endif default: unimplemented: gemu_log("qemu: Unsupported syscall: %d\n", num); Index: Makefile.target =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- Makefile.target.orig 2006-11-05 07:06:52.000000000 +0200 +++ Makefile.target 2006-11-05 07:07:25.000000000 +0200 @@ -166,7 +166,7 @@ endif ######################################################### =20 CPPFLAGS+=3D-D_GNU_SOURCE -D_FILE_OFFSET_BITS=3D64 -D_LARGEFILE_SOURCE -LIBS+=3D-lm +LIBS+=3D-lm -lrt ifndef CONFIG_USER_ONLY LIBS+=3D-lz endif --nb8zVy0QMK3AA1xu-- --PtLnLSExlPr13a2X Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.6 (GNU/Linux) iD8DBQFF2bgLbWYnhzC5v6oRApVqAJ98+kkys4e/u6O2mVT6fRJI0DUGMgCgkgZX XaUDmPLco6lbBS6dFcDHCrQ= =SVnh -----END PGP SIGNATURE----- --PtLnLSExlPr13a2X--