Deleted Added
full compact
if_bwn.c (204385) if_bwn.c (204436)
1/*-
2 * Copyright (c) 2009-2010 Weongyo Jeong <weongyo@freebsd.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 14 unchanged lines hidden (view full) ---

23 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
24 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
25 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
26 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
27 * THE POSSIBILITY OF SUCH DAMAGES.
28 */
29
30#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 2009-2010 Weongyo Jeong <weongyo@freebsd.org>
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 14 unchanged lines hidden (view full) ---

23 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
24 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
25 * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
26 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
27 * THE POSSIBILITY OF SUCH DAMAGES.
28 */
29
30#include <sys/cdefs.h>
31__FBSDID("$FreeBSD: head/sys/dev/bwn/if_bwn.c 204385 2010-02-27 02:20:38Z weongyo $");
31__FBSDID("$FreeBSD: head/sys/dev/bwn/if_bwn.c 204436 2010-02-27 23:04:29Z weongyo $");
32
33/*
34 * The Broadcom Wireless LAN controller driver.
35 */
36
37#include <sys/param.h>
38#include <sys/systm.h>
39#include <sys/module.h>

--- 1031 unchanged lines hidden (view full) ---

1071 ic = ifp->if_l2com;
1072 ic->ic_ifp = ifp;
1073 /* XXX not right but it's not used anywhere important */
1074 ic->ic_phytype = IEEE80211_T_OFDM;
1075 ic->ic_opmode = IEEE80211_M_STA;
1076 ic->ic_caps =
1077 IEEE80211_C_STA /* station mode supported */
1078 | IEEE80211_C_MONITOR /* monitor mode */
32
33/*
34 * The Broadcom Wireless LAN controller driver.
35 */
36
37#include <sys/param.h>
38#include <sys/systm.h>
39#include <sys/module.h>

--- 1031 unchanged lines hidden (view full) ---

1071 ic = ifp->if_l2com;
1072 ic->ic_ifp = ifp;
1073 /* XXX not right but it's not used anywhere important */
1074 ic->ic_phytype = IEEE80211_T_OFDM;
1075 ic->ic_opmode = IEEE80211_M_STA;
1076 ic->ic_caps =
1077 IEEE80211_C_STA /* station mode supported */
1078 | IEEE80211_C_MONITOR /* monitor mode */
1079 | IEEE80211_C_AHDEMO /* adhoc demo mode */
1079 | IEEE80211_C_SHPREAMBLE /* short preamble supported */
1080 | IEEE80211_C_SHSLOT /* short slot time supported */
1081 | IEEE80211_C_WME /* WME/WMM supported */
1082 | IEEE80211_C_WPA /* capable of WPA1+WPA2 */
1083 | IEEE80211_C_BGSCAN /* capable of bg scanning */
1084 | IEEE80211_C_TXPMGT /* capable of txpow mgt */
1085 ;
1086

--- 7355 unchanged lines hidden (view full) ---

8442 if (ic->ic_opmode == IEEE80211_M_STA &&
8443 (sc->sc_flags & BWN_FLAG_INVALID) == 0) {
8444 memset(sc->sc_bssid, 0, IEEE80211_ADDR_LEN);
8445 bwn_set_macaddr(mac);
8446 }
8447 }
8448 }
8449
1080 | IEEE80211_C_SHPREAMBLE /* short preamble supported */
1081 | IEEE80211_C_SHSLOT /* short slot time supported */
1082 | IEEE80211_C_WME /* WME/WMM supported */
1083 | IEEE80211_C_WPA /* capable of WPA1+WPA2 */
1084 | IEEE80211_C_BGSCAN /* capable of bg scanning */
1085 | IEEE80211_C_TXPMGT /* capable of txpow mgt */
1086 ;
1087

--- 7355 unchanged lines hidden (view full) ---

8443 if (ic->ic_opmode == IEEE80211_M_STA &&
8444 (sc->sc_flags & BWN_FLAG_INVALID) == 0) {
8445 memset(sc->sc_bssid, 0, IEEE80211_ADDR_LEN);
8446 bwn_set_macaddr(mac);
8447 }
8448 }
8449 }
8450
8450 if (vap->iv_opmode == IEEE80211_M_MONITOR) {
8451 if (vap->iv_opmode == IEEE80211_M_MONITOR ||
8452 vap->iv_opmode == IEEE80211_M_AHDEMO) {
8451 /* XXX nothing to do? */
8452 } else if (nstate == IEEE80211_S_RUN) {
8453 memcpy(sc->sc_bssid, vap->iv_bss->ni_bssid, IEEE80211_ADDR_LEN);
8454 memcpy(sc->sc_macaddr, IF_LLADDR(ifp), IEEE80211_ADDR_LEN);
8455 bwn_set_opmode(mac);
8456 bwn_set_pretbtt(mac);
8457 bwn_spu_setdelay(mac, 0);
8458 bwn_set_macaddr(mac);

--- 5880 unchanged lines hidden ---
8453 /* XXX nothing to do? */
8454 } else if (nstate == IEEE80211_S_RUN) {
8455 memcpy(sc->sc_bssid, vap->iv_bss->ni_bssid, IEEE80211_ADDR_LEN);
8456 memcpy(sc->sc_macaddr, IF_LLADDR(ifp), IEEE80211_ADDR_LEN);
8457 bwn_set_opmode(mac);
8458 bwn_set_pretbtt(mac);
8459 bwn_spu_setdelay(mac, 0);
8460 bwn_set_macaddr(mac);

--- 5880 unchanged lines hidden ---