RE: 2.4.25-rc1: Inconsistent ioctl symbol usage in drivers/message/fusion/mptctl.c

From: Mikael Pettersson
Date: Tue Feb 10 2004 - 04:50:02 EST


Moore, Eric Dean writes:
> On Monday, February 09, 2004 5:27 AM, Marcelo Tosatti wrote
> > Hi Eric,
> >
> > Can you please fix this up?
> >
> > On Mon, 9 Feb 2004, Keith Owens wrote:
> >
> > > 2.4.25-rc1 drivers/message/fusion/mptctl.c expects sys_ioctl,
> > > register_ioctl32_conversion and unregister_ioctl32_conversion to be
> > > exported symbols when MPT_CONFIG_COMPAT is defined. That symbol is
> > > defined for __sparc_v9__, __x86_64__ and __ia64__.
> > >
> > > The symbols are not exported in ia64, mptctl.o gets
> > unresolved symbols
> > > when it is a module on ia64.
> > >
> > > x64_64 exports register_ioctl32_conversion and
> > unregister_ioctl32_conversion,
> > > but not sys_ioctl.
> >
>
>
> Marcelo - Here is a fix for the x86_64 issue.
> In Redhat/Suse kernels this "sys_ioctl" symbol is exported, but
> not in generic kernel. The ia64 problem is going to require
> a fix in the mptctl driver.
>
>
> --- linux-2.4.25-pre8-ref/arch/x86_64/ia32/ia32_ioctl.c 2004-02-09
> 12:49:05.000000000 -0700
> +++ linux-2.4.25-pre8/arch/x86_64/ia32/ia32_ioctl.c 2004-02-09
> 12:00:52.000000000 -0700
> @@ -129,6 +129,8 @@
> #define EXT2_IOC32_GETVERSION _IOR('v', 1, int)
> #define EXT2_IOC32_SETVERSION _IOW('v', 2, int)
>
> +EXPORT_SYMBOL(sys_ioctl);
> +

Can't you just use register_ioctl32_conversion()'s convention that
a NULL handler defaults to sys_ioctl? Alternatively you could just
write the one-liner

filp->f_op->ioctl(filp->f_dentry->d_inode, filp, cmd, arg)

in your handler.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/