[...]

So add "case TUNSETIFF" to the switch statement above. You discovered the fix for your own bug, so why not implement it and submit the resulting patch here? :-)
It might have been intentionally left out - but here we go:


--- linux-2.6.10/fs/compat_ioctl.c 2005-02-15 00:09:53.969591354 +0100 +++ linux-2.6.10.patched/fs/compat_ioctl.c 2005-02-15 00:08:26.078059666 +0100 @@ -696,6 +696,7 @@ case SIOCGIFDSTADDR: case SIOCGIFNETMASK: case SIOCGIFTXQLEN: + case TUNSETIFF: if (copy_to_user(uifr32, &ifr, sizeof(*uifr32))) return -EFAULT; break;

:-))

Actually, it did the trick - l2tpns works fine now.

[...]


include/linux/if_tun.h defines TUNSETIFF using the _IOW() macro. Which indicates that data only comes in from userspace. This definition is incorrect, it should use _IORW() as Eric stated, but it can't be changed because this ioctl value is hardcoded into many existing applications which would break if we "fixed" this.


So the preferred behaviour would be: Add an interface-specification to l2tpns' config - or will the above "patch" ever be included in the official kernel?


Thanks for your help,
Michael
-
To unsubscribe from this list: send the line "unsubscribe sparclinux" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to