From owner-freebsd-emulation@FreeBSD.ORG Wed Mar 5 19:33:51 2008 Return-Path: Delivered-To: emulation@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C19F0106567F; Wed, 5 Mar 2008 19:33:51 +0000 (UTC) (envelope-from rdivacky@vlk.vlakno.cz) Received: from vlakno.cz (vlk.vlakno.cz [62.168.28.247]) by mx1.freebsd.org (Postfix) with ESMTP id 73D638FC2B; Wed, 5 Mar 2008 19:33:51 +0000 (UTC) (envelope-from rdivacky@vlk.vlakno.cz) Received: from localhost (localhost [127.0.0.1]) by vlakno.cz (Postfix) with ESMTP id 411AD676132; Wed, 5 Mar 2008 20:33:50 +0100 (CET) X-Virus-Scanned: amavisd-new at vlakno.cz Received: from vlakno.cz ([127.0.0.1]) by localhost (vlk.vlakno.cz [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id EVWNUO7eaAd3; Wed, 5 Mar 2008 20:33:31 +0100 (CET) Received: from vlk.vlakno.cz (localhost [127.0.0.1]) by vlakno.cz (Postfix) with ESMTP id 7F86E676102; Wed, 5 Mar 2008 20:33:31 +0100 (CET) Received: (from rdivacky@localhost) by vlk.vlakno.cz (8.13.8/8.13.8/Submit) id m25JXU58021152; Wed, 5 Mar 2008 20:33:30 +0100 (CET) (envelope-from rdivacky) Date: Wed, 5 Mar 2008 20:33:30 +0100 From: Roman Divacky To: Jeff Roberson Message-ID: <20080305193330.GA18756@freebsd.org> References: <20080302110130.GA30563@freebsd.org> <20080303022202.S920@desktop> <20080303144152.GA47887@freebsd.org> <20080303121025.K920@desktop> <20080304155205.X920@desktop> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="SUOF0GtieIMvvwua" Content-Disposition: inline In-Reply-To: <20080304155205.X920@desktop> User-Agent: Mutt/1.4.2.3i Cc: emulation@freebsd.org, jeff@freebsd.org Subject: Re: [PATCH] linux get affinity syscall 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: Wed, 05 Mar 2008 19:33:51 -0000 --SUOF0GtieIMvvwua Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable > >>>> if (args->len < sizeof(cpumask_t)) > >>>> return (EINVAL); >=20 > This should not be necessary anymore. >=20 > >>> > >>>Len here is in number of bits I believe as it is for our cpusetsize. > >> > >>no.. its specified in bytes > > > >You are right. So it is with fdsets. Please hold on and I'll change=20 > >cpuset to be bytes as well. > > > >> > >>>> > >>>> cga.level =3D CPU_LEVEL_WHICH; > >>>> cga.which =3D CPU_WHICH_PID; > >>>> cga.id =3D args->pid; > >>>> cga.cpusetsize =3D sizeof(cpumask_t) * NBBY; > >>>> cga.mask =3D (long *) args->user_mask_ptr; > >>> >=20 > I checked in a change to make our cpusetsize compatible. You should only= =20 > have to supply CPU_LEVEL_WHICH and CPU_WHICH_PID now. The rest of the=20 > arguments are compatible. is it possible to make cpuset_setproc non-static? if so could you please review the following patch: www.vlakno.cz/~rdivacky/linux_affinity.patch and tell me if its ok? (it lacks #include of something that should contain the prototype for cpuset_setproc()) thnx, roman --SUOF0GtieIMvvwua Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.8 (FreeBSD) iEYEARECAAYFAkfO9YoACgkQLVEj6D3CBEw1QwCfRyMTnaslDncJpTG8ppSZX/5U N2oAoILXqNN2kadGrAaON8GY+gWq8nxJ =9Uz2 -----END PGP SIGNATURE----- --SUOF0GtieIMvvwua--