| Summary: | brctl with linux 2.4 | ||
|---|---|---|---|
| Product: | Busybox | Reporter: | emmeciu |
| Component: | Networking | Assignee: | unassigned |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | busybox-cvs |
| Priority: | P5 | ||
| Version: | 1.17.x | ||
| Target Milestone: | --- | ||
| Hardware: | Other | ||
| OS: | Linux | ||
| Host: | Target: | ||
| Build: | |||
|
Description
emmeciu
2010-09-06 15:22:37 UTC
I confirm that brctl is not working with linux 2.4
The linux 2.4 uses IOCTL in a different way when creating bridge or adding interfacs.
The IOCTL defines at the beginning of brctl.c file need to be removed and the following code must be updated:
-------
#ifdef SIOCBRADDBR || SIOCBRDELBR
ioctl_or_perror_and_die(fd,
key == ARG_addbr ? SIOCBRADDBR : SIOCBRDELBR,
br, "bridge %s", br);
#else
arm_ioctl(args,
key == ARG_addbr ? BRCTL_ADD_BRIDGE : BRCTL_DEL_BRIDGE,
(unsigned long) br,
0);
ioctl_or_perror_and_die(fd, SIOCGIFBR, &args, "bridge %s", br);
#endif
-------
-------
#ifdef SIOCBRADDIF || SIOCBRDELIF
ioctl_or_perror_and_die(fd,
key == ARG_addif ? SIOCBRADDIF : SIOCBRDELIF,
&ifr,
"bridge %s", br);
#else
arm_ioctl(args,
key == ARG_addif ? BRCTL_ADD_IF : BRCTL_DEL_IF,
ifr.ifr_ifindex, 0);
ifr.ifr_data = (char *)args;
xioctl(fd, SIOCDEVPRIVATE, &ifr);
#endif
-------
Please feel free to contact me if you need more info.
Regs,
Thierry
|