On Sun, Jul 05, 2009 at 01:30:43PM +0200, Denys Vlasenko wrote: >On Sunday 05 July 2009 12:58, Bernhard Reutner-Fischer wrote: >> On Sun, Jul 05, 2009 at 04:02:48AM +0200, Denys Vlasenko wrote: >> >> >brctl needs to be rewritten to use newer kernel API... >> >it uses deprecated ioctl now. >> >> So.. did Stephen fix this by now, i.e. can you operate a bridge >> via sysfs *only* nowadays¹) ? >> >> cheers, >> >> PS: >> We are concerned about the size of the brctl(8) ²) >> >> ¹) >> http://lists.busybox.net/pipermail/busybox/2008-April/065314.html >> and >> https://lists.linux-foundation.org/pipermail/bridge/2008-May/005839.html >> https://lists.linux-foundation.org/pipermail/bridge/2008-May/005838.html >> ²) ioctl-only impl >> http://git.busybox.net/busybox/tree/networking/brctl.c >> needs less than 2400 bytes, including any fancy stuff and show* support. >> If we can switch to sysfs-only then we can probably keep that size or >> even reduce it, but if we have to use 2 separate operation-modi (ioctl for >> adding/deleting a bridge and interfaces *and* sysfs for the param-setting), >> then this would add undue size. > >Well. 32/64-bit setup on the x86-64 arch _must_ use sysfs: > >On kernel side, bridge ioctls lack compat translation, >and IIUC it is missing because ioctl are declared deprecated, >and thus it is considered waste of time to fix that.
yes. The patch quoted in ¹) above would: - add about 500 byte to the bridge.ko - would allow for a pure sysfs operation of bridges - thus the ioctl interface could (finally!) be dropped from the kernel (potentially saving several hundred bytes in turn) - which itself could be considered a(n optional, backward-compat config-knob for the kernel for !EMBEDDED ?) cleanup > >Considering that 32/64-bit setup on the x86-64 is used by millions >of users, this is a very serious reason to use sysfs. Yes. The only problem i had was that it adds bloat to userspace if only parts of bridge operation can be done via sysfs. Keep in mind that ioctl is deprecated anyway, but that crucial parts were missing from the sysfs interface to bridge. It would be benefical to both users and embedded setups if we could turn off the ioctl interface and use a purely sysfs interface instead, at least in my POV. Comments? _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
