Lines Matching defs:ic

1843 	struct ieee80211com *ic = &sc->sc_ic;
1856 switch (ic->ic_opmode) {
1869 ic->ic_opmode);
1948 struct ieee80211com *ic = &sc->sc_ic;
1958 if (ic->ic_opmode == IEEE80211_M_MONITOR) {
1962 if (sc->sc_crcmon == 1 && ic->ic_opmode == IEEE80211_M_MONITOR)
2422 struct ieee80211com *ic = &sc->sc_ic;
2423 struct ieee80211_channel *c = ic->ic_curchan;
2436 if (ic->ic_state == IEEE80211_S_ASSOC &&
2437 ic->ic_flags & IEEE80211_F_SHSLOT)
2511 struct ieee80211com *ic = &sc->sc_ic;
2580 ni = ieee80211_find_rxnode(ic, wh);
2583 (void) ieee80211_input(ic, mp, ni, rssi, 0);
2826 struct ieee80211com *ic = &sc->sc_ic;
2827 struct ieee80211_channel *c = ic->ic_curchan;
2842 if (ic->ic_state == IEEE80211_S_ASSOC &&
2843 ic->ic_flags & IEEE80211_F_SHSLOT) {
2874 struct ieee80211com *ic = &sc->sc_ic;
2885 error = rf->set_chan(rf, ieee80211_chan2ieee(ic, ic->ic_curchan));
2900 struct ieee80211com *ic = &sc->sc_ic;
2910 ic->ic_stats.is_tx_failed++;
2916 mac_tx_update(ic->ic_mach);
2929 struct ieee80211com *ic = &sc->sc_ic;
2940 ic->ic_stats.is_tx_failed++;
2946 mac_tx_update(ic->ic_mach);
2956 urtw_get_rate(struct ieee80211com *ic)
2961 rates = &ic->ic_bss->in_rates.ir_rates;
2963 if (ic->ic_fixed_rate != IEEE80211_FIXED_RATE_NONE)
2964 rate = ic->ic_fixed_rate;
2965 else if (ic->ic_state == IEEE80211_S_RUN)
2966 rate = (*rates)[ic->ic_bss->in_txrate];
2975 struct ieee80211com *ic = &sc->sc_ic;
2976 struct ieee80211_channel *c = ic->ic_curchan;
3055 struct ieee80211com *ic = &sc->sc_ic;
3076 ic->ic_macaddr[i], 0);
3188 struct ieee80211com *ic = &sc->sc_ic;
3189 struct ieee80211_channel *c = ic->ic_curchan;
3450 urtw_send(ieee80211com_t *ic, mblk_t *mp, uint8_t type)
3452 struct urtw_softc *sc = (struct urtw_softc *)ic;
3494 ni = ieee80211_find_txnode(ic, wh->i_addr1);
3497 ic->ic_stats.is_tx_failed++;
3503 (void) ieee80211_encap(ic, m, ni);
3507 k = ieee80211_crypto_encap(ic, m);
3509 ic->ic_stats.is_tx_failed++;
3544 buf[3] = urtw_rate2rtl(MAX(2, urtw_get_rate(ic)));
3567 ic->ic_stats.is_tx_frags++;
3568 ic->ic_stats.is_tx_bytes += MBLKL(m);
3570 ic->ic_stats.is_tx_failed++;
3595 ieee80211com_t *ic = arg;
3603 if (ic->ic_state == IEEE80211_S_SCAN) {
3604 (void) ieee80211_next_scan(ic);
3613 ieee80211com_t *ic = &sc->sc_ic;
3632 drv_usectohz((ic->ic_state == IEEE80211_S_RUN) ?
3645 urtw_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg)
3647 struct urtw_softc *sc = (struct urtw_softc *)ic;
3671 arg, ieee80211_chan2ieee(ic, ic->ic_curchan)));
3685 ieee80211_chan2ieee(ic, ic->ic_curchan)));
3696 ieee80211_chan2ieee(ic, ic->ic_curchan)));
3708 arg, ieee80211_chan2ieee(ic, ic->ic_curchan)));
3715 ni = ic->ic_bss;
3734 error = sc->sc_newstate(ic, nstate, arg);
3963 struct ieee80211com *ic = &sc->sc_ic;
3966 if ((ic->ic_state != IEEE80211_S_RUN) ||
3975 if (urtw_send(ic, mp, IEEE80211_FC0_TYPE_DATA) != DDI_SUCCESS) {
4055 struct ieee80211com *ic = &sc->sc_ic;
4058 err = ieee80211_setprop(ic, pr_name, wldp_pr_num,
4062 if (URTW_IS_RUNNING(sc) && ic->ic_des_esslen) {
4071 (void) ieee80211_new_state(ic, IEEE80211_S_SCAN, -1);
4084 struct ieee80211com *ic = &sc->sc_ic;
4087 err = ieee80211_ioctl(ic, wq, mp);
4090 if (URTW_IS_RUNNING(sc) && ic->ic_des_esslen) {
4099 (void) ieee80211_new_state(ic, IEEE80211_S_SCAN, -1);
4110 ieee80211com_t *ic = &sc->sc_ic;
4117 ni = ic->ic_bss;
4119 *val = ((ic->ic_fixed_rate == IEEE80211_FIXED_RATE_NONE) ?
4121 : ic->ic_fixed_rate) / 2 * 1000000;
4133 *val = ic->ic_stats.is_rx_bytes;
4136 *val = ic->ic_stats.is_rx_frags;
4139 *val = ic->ic_stats.is_tx_bytes;
4142 *val = ic->ic_stats.is_tx_frags;
4145 *val = ic->ic_stats.is_tx_failed;
4160 return (ieee80211_stat(ic, stat, val));
4174 struct ieee80211com *ic = &sc->sc_ic;
4176 ieee80211_stop_watchdog(ic);
4185 switch (ic->ic_state) {
4188 if (ic->ic_bss->in_fails > 0) {
4189 ieee80211_new_state(ic, IEEE80211_S_INIT, -1);
4194 ieee80211_watchdog(ic);
4204 struct ieee80211com *ic;
4247 ic = (ieee80211com_t *)&sc->sc_ic;
4355 ic->ic_phytype = IEEE80211_T_OFDM; /* not only, but not used */
4356 ic->ic_opmode = IEEE80211_M_STA; /* default to BSS mode */
4357 ic->ic_state = IEEE80211_S_INIT;
4359 ic->ic_maxrssi = 95;
4360 ic->ic_xmit = urtw_send;
4362 ic->ic_caps |= IEEE80211_C_WPA | /* Support WPA/WPA2 */
4367 ic->ic_sup_rates[IEEE80211_MODE_11B] = urtw_rateset_11b;
4368 ic->ic_sup_rates[IEEE80211_MODE_11G] = urtw_rateset_11g;
4372 ic->ic_sup_channels[i].ich_freq =
4374 ic->ic_sup_channels[i].ich_flags =
4379 ieee80211_attach(ic);
4380 ic->ic_ibss_chan = &ic->ic_sup_channels[1];
4381 ic->ic_curchan = ic->ic_ibss_chan;
4384 ieee80211_register_door(ic, ddi_driver_name(devinfo),
4388 sc->sc_newstate = ic->ic_newstate;
4389 ic->ic_newstate = urtw_newstate;
4390 ic->ic_watchdog = urtw_watchdog;
4391 ieee80211_media_init(ic);
4392 ic->ic_def_txkey = 0;
4401 wd.wd_opmode = ic->ic_opmode;
4403 IEEE80211_ADDR_COPY(wd.wd_bssid, ic->ic_bss->in_bssid);
4414 macp->m_src_addr = ic->ic_macaddr;
4421 error = mac_register(macp, &ic->ic_mach);
4447 mac_link_update(ic->ic_mach, LINK_STATE_DOWN);
4453 (void) mac_disable(ic->ic_mach);
4454 (void) mac_unregister(ic->ic_mach);
4456 ieee80211_detach(ic);