ieee80211_ioctl.c (117040) | ieee80211_ioctl.c (117811) |
---|---|
1/*- 2 * Copyright (c) 2001 Atsushi Onoe 3 * Copyright (c) 2002, 2003 Sam Leffler, Errno Consulting 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 17 unchanged lines hidden (view full) --- 26 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 27 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 28 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 29 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 30 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 */ 32 33#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2001 Atsushi Onoe 3 * Copyright (c) 2002, 2003 Sam Leffler, Errno Consulting 4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: --- 17 unchanged lines hidden (view full) --- 26 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 27 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 28 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 29 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 30 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 31 */ 32 33#include <sys/cdefs.h> |
34__FBSDID("$FreeBSD: head/sys/net80211/ieee80211_ioctl.c 117040 2003-06-29 20:12:17Z sam $"); | 34__FBSDID("$FreeBSD: head/sys/net80211/ieee80211_ioctl.c 117811 2003-07-20 21:36:08Z sam $"); |
35 36/* 37 * IEEE 802.11 ioctl support (FreeBSD-specific) 38 */ 39 40#include <sys/endian.h> 41#include <sys/param.h> 42#include <sys/kernel.h> --- 611 unchanged lines hidden (view full) --- 654 break; 655 case WI_RID_IFACE_STATS: 656 error = EPERM; 657 break; 658 case WI_RID_SCAN_REQ: /* XXX wicontrol */ 659 if (ic->ic_opmode == IEEE80211_M_HOSTAP) 660 break; 661 /* NB: ignore channel list and tx rate parameters */ | 35 36/* 37 * IEEE 802.11 ioctl support (FreeBSD-specific) 38 */ 39 40#include <sys/endian.h> 41#include <sys/param.h> 42#include <sys/kernel.h> --- 611 unchanged lines hidden (view full) --- 654 break; 655 case WI_RID_IFACE_STATS: 656 error = EPERM; 657 break; 658 case WI_RID_SCAN_REQ: /* XXX wicontrol */ 659 if (ic->ic_opmode == IEEE80211_M_HOSTAP) 660 break; 661 /* NB: ignore channel list and tx rate parameters */ |
662 error = ieee80211_new_state(ifp, IEEE80211_S_SCAN, -1); | 662 error = ieee80211_new_state(ic, IEEE80211_S_SCAN, -1); |
663 break; 664 case WI_RID_SCAN_APS: 665 if (ic->ic_opmode == IEEE80211_M_HOSTAP) 666 break; 667 len--; /* XXX: tx rate? */ 668 /* FALLTHRU */ 669 case WI_RID_CHANNEL_LIST: 670 memset(chanlist, 0, sizeof(chanlist)); --- 27 unchanged lines hidden (view full) --- 698 break; 699 } 700 } 701 if (isclr(chanlist, ieee80211_chan2ieee(ic, ic->ic_bss->ni_chan))) 702 ic->ic_bss->ni_chan = ic->ic_ibss_chan; 703 if (wreq.wi_type == WI_RID_CHANNEL_LIST) 704 error = ENETRESET; 705 else | 663 break; 664 case WI_RID_SCAN_APS: 665 if (ic->ic_opmode == IEEE80211_M_HOSTAP) 666 break; 667 len--; /* XXX: tx rate? */ 668 /* FALLTHRU */ 669 case WI_RID_CHANNEL_LIST: 670 memset(chanlist, 0, sizeof(chanlist)); --- 27 unchanged lines hidden (view full) --- 698 break; 699 } 700 } 701 if (isclr(chanlist, ieee80211_chan2ieee(ic, ic->ic_bss->ni_chan))) 702 ic->ic_bss->ni_chan = ic->ic_ibss_chan; 703 if (wreq.wi_type == WI_RID_CHANNEL_LIST) 704 error = ENETRESET; 705 else |
706 error = ieee80211_new_state(ifp, IEEE80211_S_SCAN, -1); | 706 error = ieee80211_new_state(ic, IEEE80211_S_SCAN, -1); |
707 break; 708 default: 709 error = EINVAL; 710 break; 711 } 712 return error; 713} 714 --- 274 unchanged lines hidden --- | 707 break; 708 default: 709 error = EINVAL; 710 break; 711 } 712 return error; 713} 714 --- 274 unchanged lines hidden --- |