Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 15 Dec 2004 10:59:26 -0800
From:      Sean McNeil <sean@mcneil.com>
To:        Ruslan Ermilov <ru@FreeBSD.org>
Cc:        "Tim J. Robbins" <tjr@FreeBSD.org>
Subject:   Re: ports/emulators/linux_base on amd64
Message-ID:  <1103137166.76745.9.camel@server.mcneil.com>
In-Reply-To: <20041215102625.GM25967@ip.net.ua>
References:  <20041214182153.GA80721@ip.net.ua> <1103049246.21655.3.camel@server.mcneil.com> <20041214215415.GB29362@ip.net.ua> <1103062382.46568.1.camel@server.mcneil.com> <1103066141.2041.4.camel@server.mcneil.com> <20041215102625.GM25967@ip.net.ua>

next in thread | previous in thread | raw e-mail | index | archive | help

--=-7Y4KkmDKwfHHQI+9rsqV
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable

On Wed, 2004-12-15 at 12:26 +0200, Ruslan Ermilov wrote:
> The reason for this is as follows:
>=20
> hammer# grep -C3 TJR /sys/compat/linux/linux_socket.c=20
>         struct iovec *iov;
>         int error;
>=20
>         /* XXXTJR sendmsg is broken on amd64 */
>=20
>         error =3D copyin(args, &linux_args, sizeof(linux_args));
>         if (error)
> --
>         struct cmsghdr *cmsg;
>         int error;
>=20
>         /* XXXTJR recvmsg is broken on amd64 */
>=20
>         if ((error =3D copyin(args, &linux_args, sizeof(linux_args))))
>                 return (error);

Is there any additional work being done with linux emulation on amd64?
There is something odd here that puzzles me.  There are changes to
convert 32-bit pointers over to 64-bit as it does the copyin.  For
sendmsg/recvmsg, these have a msghdr structure that can get a little
complicated (especially mgs_control which is protocol dependent).  But
I'm not sure why this is done at all.  Why convert the 32-bit pointers
in the linux emulation?  Why not have the linux emulation as it should
be - independent of architecture sizes - and have it build on top of
64-bit or compat_ia32 for 32-bit?  This would go a very long way in
getting linux64 working under FreeBSD, wouldn't it?

Cheers,
Sean


--=-7Y4KkmDKwfHHQI+9rsqV
Content-Type: application/pgp-signature; name=signature.asc
Content-Description: This is a digitally signed message part

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (FreeBSD)

iD8DBQBBwImOyQsGN30uGE4RAmSYAJ9PhpNyXus+bst0ltnKu7s2vtZKywCeOrNh
uxfKSvemfLK+22gGcVw+dJ8=
=QdJ9
-----END PGP SIGNATURE-----

--=-7Y4KkmDKwfHHQI+9rsqV--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1103137166.76745.9.camel>