From mboxrd@z Thu Jan 1 00:00:00 1970 From: Hollis Blanchard Subject: Re: [XenPPC] Re: [PATCH 6 of 6] [XEN][LINUX] Add 32-bit privcmd ioctlconversion for 64-bit kernels Date: Fri, 06 Jul 2007 10:44:19 -0500 Message-ID: <1183736659.3008.8.camel@basalt> References: <3833674b6d561e690b49.1183674475@localhost> <468E14E8.76E4.0078.0@novell.com> Reply-To: Hollis Blanchard Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <468E14E8.76E4.0078.0@novell.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Jan Beulich Cc: xen-devel@lists.xensource.com, Keir Fraser , xen-ppc-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On Fri, 2007-07-06 at 09:09 +0100, Jan Beulich wrote: > >--- a/fs/compat_ioctl.c Thu Jul 05 17:25:47 2007 -0500 > >+++ b/fs/compat_ioctl.c Thu Jul 05 17:26:48 2007 -0500 > >@@ -2948,6 +2953,18 @@ COMPATIBLE_IOCTL(LPRESET) > > /*LPGETSTATS not implemented, but no kernels seem to compile it in > anyways*/ > > COMPATIBLE_IOCTL(LPGETFLAGS) > > HANDLE_IOCTL(LPSETTIMEOUT, lp_timeout_trans) > >+ > >+#ifdef CONFIG_XEN > >+HANDLE_IOCTL(IOCTL_PRIVCMD_MMAP_32, privcmd_ioctl_32) > >+HANDLE_IOCTL(IOCTL_PRIVCMD_MMAPBATCH_32, privcmd_ioctl_32) > >+COMPATIBLE_IOCTL(IOCTL_PRIVCMD_HYPERCALL) > > Where does the hypercall argument translation happen? It happens inside privcmd_hypercall(). See http://xenbits.xensource.com/ext/linux-ppc-2.6.hg?file/04f6ad5d9232/arch/powerpc/platforms/xen/hcall.c (In that tree, the function is named "arch_privcmd_hypercall".) IA64 and PPC both implement this function now; only x86 is left with #ifdefs in drivers/xen/privcmd/privcmd.c . COMPATIBLE_IOCTL is just about the ioctl itself, not the sub-structures. -- Hollis Blanchard IBM Linux Technology Center