* [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
@ 2005-05-02 1:45 Adrian Bunk
2005-05-02 16:09 ` Andi Kleen
2005-05-03 0:30 ` Andrew Morton
0 siblings, 2 replies; 9+ messages in thread
From: Adrian Bunk @ 2005-05-02 1:45 UTC (permalink / raw)
To: Andi Kleen, Christoph Hellwig, Andrew Morton; +Cc: linux-kernel
This removal should have happened last month.
Signed-off-by: Adrian Bunk <bunk@stusta.de>
---
Documentation/feature-removal-schedule.txt | 8 -
fs/compat.c | 90 ---------------------
include/linux/ioctl32.h | 22 -----
3 files changed, 120 deletions(-)
--- linux-2.6.12-rc3-mm2-full/Documentation/feature-removal-schedule.txt.old 2005-05-01 23:55:12.000000000 +0200
+++ linux-2.6.12-rc3-mm2-full/Documentation/feature-removal-schedule.txt 2005-05-01 23:55:23.000000000 +0200
@@ -43,14 +43,6 @@
---------------------------
-What: register_ioctl32_conversion() / unregister_ioctl32_conversion()
-When: April 2005
-Why: Replaced by ->compat_ioctl in file_operations and other method
- vecors.
-Who: Andi Kleen <ak@muc.de>, Christoph Hellwig <hch@lst.de>
-
----------------------------
-
What: RCU API moves to EXPORT_SYMBOL_GPL
When: April 2006
Files: include/linux/rcupdate.h, kernel/rcupdate.c
--- linux-2.6.12-rc3-mm2-full/include/linux/ioctl32.h.old 2005-05-01 23:55:43.000000000 +0200
+++ linux-2.6.12-rc3-mm2-full/include/linux/ioctl32.h 2005-05-01 23:56:08.000000000 +0200
@@ -14,26 +14,4 @@
struct ioctl_trans *next;
};
-/*
- * Register an 32bit ioctl translation handler for ioctl cmd.
- *
- * handler == NULL: use 64bit ioctl handler.
- * arguments to handler: fd: file descriptor
- * cmd: ioctl command.
- * arg: ioctl argument
- * struct file *file: file descriptor pointer.
- */
-
-#ifdef CONFIG_COMPAT
-extern int __deprecated register_ioctl32_conversion(unsigned int cmd,
- ioctl_trans_handler_t handler);
-extern int __deprecated unregister_ioctl32_conversion(unsigned int cmd);
-
-#else
-
-#define register_ioctl32_conversion(cmd, handler) ({ 0; })
-#define unregister_ioctl32_conversion(cmd) ({ 0; })
-
-#endif
-
#endif
--- linux-2.6.12-rc3-mm2-full/fs/compat.c.old 2005-05-01 23:56:17.000000000 +0200
+++ linux-2.6.12-rc3-mm2-full/fs/compat.c 2005-05-01 23:57:45.000000000 +0200
@@ -310,96 +310,6 @@
__initcall(init_sys32_ioctl);
-int register_ioctl32_conversion(unsigned int cmd,
- ioctl_trans_handler_t handler)
-{
- struct ioctl_trans *t;
- struct ioctl_trans *new_t;
- unsigned long hash = ioctl32_hash(cmd);
-
- new_t = kmalloc(sizeof(*new_t), GFP_KERNEL);
- if (!new_t)
- return -ENOMEM;
-
- down_write(&ioctl32_sem);
- for (t = ioctl32_hash_table[hash]; t; t = t->next) {
- if (t->cmd == cmd) {
- printk(KERN_ERR "Trying to register duplicated ioctl32 "
- "handler %x\n", cmd);
- up_write(&ioctl32_sem);
- kfree(new_t);
- return -EINVAL;
- }
- }
- new_t->next = NULL;
- new_t->cmd = cmd;
- new_t->handler = handler;
- ioctl32_insert_translation(new_t);
-
- up_write(&ioctl32_sem);
- return 0;
-}
-EXPORT_SYMBOL(register_ioctl32_conversion);
-
-static inline int builtin_ioctl(struct ioctl_trans *t)
-{
- return t >= ioctl_start && t < (ioctl_start + ioctl_table_size);
-}
-
-/* Problem:
- This function cannot unregister duplicate ioctls, because they are not
- unique.
- When they happen we need to extend the prototype to pass the handler too. */
-
-int unregister_ioctl32_conversion(unsigned int cmd)
-{
- unsigned long hash = ioctl32_hash(cmd);
- struct ioctl_trans *t, *t1;
-
- down_write(&ioctl32_sem);
-
- t = ioctl32_hash_table[hash];
- if (!t) {
- up_write(&ioctl32_sem);
- return -EINVAL;
- }
-
- if (t->cmd == cmd) {
- if (builtin_ioctl(t)) {
- printk("%p tried to unregister builtin ioctl %x\n",
- __builtin_return_address(0), cmd);
- } else {
- ioctl32_hash_table[hash] = t->next;
- up_write(&ioctl32_sem);
- kfree(t);
- return 0;
- }
- }
- while (t->next) {
- t1 = t->next;
- if (t1->cmd == cmd) {
- if (builtin_ioctl(t1)) {
- printk("%p tried to unregister builtin "
- "ioctl %x\n",
- __builtin_return_address(0), cmd);
- goto out;
- } else {
- t->next = t1->next;
- up_write(&ioctl32_sem);
- kfree(t1);
- return 0;
- }
- }
- t = t1;
- }
- printk(KERN_ERR "Trying to free unknown 32bit ioctl handler %x\n",
- cmd);
-out:
- up_write(&ioctl32_sem);
- return -EINVAL;
-}
-EXPORT_SYMBOL(unregister_ioctl32_conversion);
-
static void compat_ioctl_error(struct file *filp, unsigned int fd,
unsigned int cmd, unsigned long arg)
{
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-02 1:45 [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month Adrian Bunk
@ 2005-05-02 16:09 ` Andi Kleen
2005-05-02 16:20 ` Christoph Hellwig
2005-05-02 16:34 ` Adrian Bunk
2005-05-03 0:30 ` Andrew Morton
1 sibling, 2 replies; 9+ messages in thread
From: Andi Kleen @ 2005-05-02 16:09 UTC (permalink / raw)
To: Adrian Bunk; +Cc: Christoph Hellwig, Andrew Morton, linux-kernel
On Mon, May 02, 2005 at 03:45:51AM +0200, Adrian Bunk wrote:
> This removal should have happened last month.
Thanks. I believe I2O and s390 are still using it though. The I2O patch
is pending somewhere and s390 will hopefully catch up.
-Andi
>
> Signed-off-by: Adrian Bunk <bunk@stusta.de>
>
> ---
>
> Documentation/feature-removal-schedule.txt | 8 -
> fs/compat.c | 90 ---------------------
> include/linux/ioctl32.h | 22 -----
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-02 16:09 ` Andi Kleen
@ 2005-05-02 16:20 ` Christoph Hellwig
2005-05-02 16:34 ` Adrian Bunk
1 sibling, 0 replies; 9+ messages in thread
From: Christoph Hellwig @ 2005-05-02 16:20 UTC (permalink / raw)
To: Andi Kleen; +Cc: Adrian Bunk, Christoph Hellwig, Andrew Morton, linux-kernel
On Mon, May 02, 2005 at 06:09:16PM +0200, Andi Kleen wrote:
> On Mon, May 02, 2005 at 03:45:51AM +0200, Adrian Bunk wrote:
> > This removal should have happened last month.
>
> Thanks. I believe I2O and s390 are still using it though. The I2O patch
> is pending somewhere and s390 will hopefully catch up.
both i2o and s390 have been converted away from it in mainline.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-02 16:09 ` Andi Kleen
2005-05-02 16:20 ` Christoph Hellwig
@ 2005-05-02 16:34 ` Adrian Bunk
2005-05-02 17:16 ` Andi Kleen
1 sibling, 1 reply; 9+ messages in thread
From: Adrian Bunk @ 2005-05-02 16:34 UTC (permalink / raw)
To: Andi Kleen; +Cc: Christoph Hellwig, Andrew Morton, linux-kernel
On Mon, May 02, 2005 at 06:09:16PM +0200, Andi Kleen wrote:
> On Mon, May 02, 2005 at 03:45:51AM +0200, Adrian Bunk wrote:
> > This removal should have happened last month.
>
> Thanks. I believe I2O and s390 are still using it though. The I2O patch
> is pending somewhere and s390 will hopefully catch up.
There are no users in 2.6.12-rc3-mm2.
> -Andi
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-02 16:34 ` Adrian Bunk
@ 2005-05-02 17:16 ` Andi Kleen
0 siblings, 0 replies; 9+ messages in thread
From: Andi Kleen @ 2005-05-02 17:16 UTC (permalink / raw)
To: Adrian Bunk; +Cc: Christoph Hellwig, Andrew Morton, linux-kernel
On Mon, May 02, 2005 at 06:34:29PM +0200, Adrian Bunk wrote:
> On Mon, May 02, 2005 at 06:09:16PM +0200, Andi Kleen wrote:
> > On Mon, May 02, 2005 at 03:45:51AM +0200, Adrian Bunk wrote:
> > > This removal should have happened last month.
> >
> > Thanks. I believe I2O and s390 are still using it though. The I2O patch
> > is pending somewhere and s390 will hopefully catch up.
>
> There are no users in 2.6.12-rc3-mm2.
Great. It can go then.
BTW with that the BKL in compat_ioctl can be removed too - it is useless
now.
-Andi
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-02 1:45 [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month Adrian Bunk
2005-05-02 16:09 ` Andi Kleen
@ 2005-05-03 0:30 ` Andrew Morton
2005-05-03 0:39 ` Adrian Bunk
2005-05-03 14:46 ` Andi Kleen
1 sibling, 2 replies; 9+ messages in thread
From: Andrew Morton @ 2005-05-03 0:30 UTC (permalink / raw)
To: Adrian Bunk; +Cc: ak, hch, linux-kernel, linux-usb-devel
Adrian Bunk <bunk@stusta.de> wrote:
>
> This removal should have happened last month.
drivers/usb/misc/sisusbvga/sisusb.c will use these functions if someone
defines SISUSB_OLD_CONFIG_COMPAT, so we need to agree to zap that code
before I can merge this upstream.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-03 0:30 ` Andrew Morton
@ 2005-05-03 0:39 ` Adrian Bunk
2005-05-03 7:30 ` Thomas Winischhofer
2005-05-03 14:46 ` Andi Kleen
1 sibling, 1 reply; 9+ messages in thread
From: Adrian Bunk @ 2005-05-03 0:39 UTC (permalink / raw)
To: Andrew Morton; +Cc: ak, hch, linux-kernel, linux-usb-devel, Thomas Winischhofer
On Mon, May 02, 2005 at 05:30:52PM -0700, Andrew Morton wrote:
> Adrian Bunk <bunk@stusta.de> wrote:
> >
> > This removal should have happened last month.
>
> drivers/usb/misc/sisusbvga/sisusb.c will use these functions if someone
> defines SISUSB_OLD_CONFIG_COMPAT, so we need to agree to zap that code
> before I can merge this upstream.
That's not a problem.
Quoting drivers/usb/misc/sisusbvga/sisusb.h:
#ifdef CONFIG_COMPAT
#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,10)
#include <linux/ioctl32.h>
#define SISUSB_OLD_CONFIG_COMPAT
#else
#define SISUSB_NEW_CONFIG_COMPAT
#endif
#endif
I decided not to drop the SISUSB_OLD_CONFIG_COMPAT code in my patch
because it seems Thomas is sharing this code between different kernel
versions, and a removal might make his life harder for no big win.
cu
Adrian
--
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-03 0:39 ` Adrian Bunk
@ 2005-05-03 7:30 ` Thomas Winischhofer
0 siblings, 0 replies; 9+ messages in thread
From: Thomas Winischhofer @ 2005-05-03 7:30 UTC (permalink / raw)
To: Adrian Bunk; +Cc: Andrew Morton, ak, hch, linux-kernel, linux-usb-devel
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Adrian Bunk wrote:
> On Mon, May 02, 2005 at 05:30:52PM -0700, Andrew Morton wrote:
>
>>Adrian Bunk <bunk@stusta.de> wrote:
>>
>>>This removal should have happened last month.
>>
>>drivers/usb/misc/sisusbvga/sisusb.c will use these functions if someone
>>defines SISUSB_OLD_CONFIG_COMPAT, so we need to agree to zap that code
>>before I can merge this upstream.
Why on earth should anyone #define something with "SISUSB" in the
beginning, on a level that might be available in a usb driver?
>
> That's not a problem.
>
>
> Quoting drivers/usb/misc/sisusbvga/sisusb.h:
>
> #ifdef CONFIG_COMPAT
> #if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,10)
> #include <linux/ioctl32.h>
> #define SISUSB_OLD_CONFIG_COMPAT
> #else
> #define SISUSB_NEW_CONFIG_COMPAT
> #endif
> #endif
>
>
> I decided not to drop the SISUSB_OLD_CONFIG_COMPAT code in my patch
> because it seems Thomas is sharing this code between different kernel
> versions, and a removal might make his life harder for no big win.
Exactly. Thanks, Adrian.
Thomas
- --
Thomas Winischhofer
Vienna/Austria
thomas AT winischhofer DOT net *** http://www.winischhofer.net
twini AT xfree86 DOT org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFCdyh+zydIRAktyUcRAgTLAKDJ7woebRDkqRS70aImI5c0y+fiyQCgyNqE
8haWeqvcbbbCjYn607Xh51E=
=ZaoZ
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month
2005-05-03 0:30 ` Andrew Morton
2005-05-03 0:39 ` Adrian Bunk
@ 2005-05-03 14:46 ` Andi Kleen
1 sibling, 0 replies; 9+ messages in thread
From: Andi Kleen @ 2005-05-03 14:46 UTC (permalink / raw)
To: Andrew Morton; +Cc: Adrian Bunk, hch, linux-kernel, linux-usb-devel
On Mon, May 02, 2005 at 05:30:52PM -0700, Andrew Morton wrote:
> Adrian Bunk <bunk@stusta.de> wrote:
> >
> > This removal should have happened last month.
>
> drivers/usb/misc/sisusbvga/sisusb.c will use these functions if someone
> defines SISUSB_OLD_CONFIG_COMPAT, so we need to agree to zap that code
> before I can merge this upstream.
I had a patch to fix that one. I think I sent it to the maintainer,
perhaps he ignored it. I will dig it up again.
-Andi
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2005-05-03 14:48 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-05-02 1:45 [2.6 patch] {,un}register_ioctl32_conversion should have been removed last month Adrian Bunk
2005-05-02 16:09 ` Andi Kleen
2005-05-02 16:20 ` Christoph Hellwig
2005-05-02 16:34 ` Adrian Bunk
2005-05-02 17:16 ` Andi Kleen
2005-05-03 0:30 ` Andrew Morton
2005-05-03 0:39 ` Adrian Bunk
2005-05-03 7:30 ` Thomas Winischhofer
2005-05-03 14:46 ` Andi Kleen
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox