mirror of
https://github.com/openwrt/openwrt.git
synced 2025-01-13 08:20:07 +00:00
modify SIOCSIWAP call to associate with a specific bssid when in managed mode
SVN-Revision: 1051
This commit is contained in:
parent
e9a0d8517b
commit
0d7667d477
@ -314,10 +314,15 @@ static int wlcompat_ioctl(struct net_device *dev,
|
|||||||
}
|
}
|
||||||
case SIOCSIWAP:
|
case SIOCSIWAP:
|
||||||
{
|
{
|
||||||
|
int ap = 0;
|
||||||
|
|
||||||
if (wrqu->ap_addr.sa_family != ARPHRD_ETHER)
|
if (wrqu->ap_addr.sa_family != ARPHRD_ETHER)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
if (wl_ioctl(dev,WLC_SET_BSSID,wrqu->ap_addr.sa_data,6) < 0)
|
if (wl_ioctl(dev, WLC_GET_AP, &ap, sizeof(ap)) < 0)
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
|
if (wl_ioctl(dev, (ap ? WLC_SET_BSSID : WLC_REASSOC), wrqu->ap_addr.sa_data, 6) < 0)
|
||||||
return -EINVAL;
|
return -EINVAL;
|
||||||
|
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user