diff options
author | wpaul <wpaul@FreeBSD.org> | 2000-11-13 23:04:16 +0000 |
---|---|---|
committer | wpaul <wpaul@FreeBSD.org> | 2000-11-13 23:04:16 +0000 |
commit | 85c836b2c070d3a80771393496f94ea2f827eef3 (patch) | |
tree | e6d5897412fe72e7cda4aff4db0192a54a00707a /sys/dev/an/if_anreg.h | |
parent | 7df19d145567bd8d1f27e401d308a3592bd0fc93 (diff) | |
download | FreeBSD-src-85c836b2c070d3a80771393496f94ea2f827eef3.zip FreeBSD-src-85c836b2c070d3a80771393496f94ea2f827eef3.tar.gz |
Close PR# 21843 and PR# 21864. This adds support for WEP and updates some
of the data structures to include new members that weren't defined in the
manual I have.
I opted to use Doug Ambrisko's WEP patches since David Cornejo's patches
did not include the necessary changes to ancontrol(8) to actually enable
and use WEP.
NOTE: I don't currently have access to an Aironet card, so I can't test
any of this. Everything compiles and close scrutiny doesn't reveal any
obvious problems, but Murphy's Law applies. This means I will probably
leave these changes in -current for a bit longer than usual until I'm
sure they work right.
Diffstat (limited to 'sys/dev/an/if_anreg.h')
-rw-r--r-- | sys/dev/an/if_anreg.h | 45 |
1 files changed, 42 insertions, 3 deletions
diff --git a/sys/dev/an/if_anreg.h b/sys/dev/an/if_anreg.h index be88f6c..1bfc284 100644 --- a/sys/dev/an/if_anreg.h +++ b/sys/dev/an/if_anreg.h @@ -273,7 +273,10 @@ struct an_ltv_genconfig { u_int16_t an_diversity; /* 0x72 */ u_int16_t an_tx_power; /* 0x74 */ u_int16_t an_rss_thresh; /* 0x76 */ - u_int16_t an_rsvd6[4]; /* 0x78 */ + u_int16_t an_modulation_type; /* 0x78 */ + u_int16_t an_short_preamble; /* 0x7A */ + u_int16_t an_home_product; /* 0x7C */ + u_int16_t an_rsvd6; /* 0x7E */ /* Aironet extensions. */ u_int8_t an_nodename[16]; /* 0x80 */ u_int16_t an_arl_thresh; /* 0x90 */ @@ -416,6 +419,9 @@ struct an_rid_encap { #define AN_TXENCAP_RFC1024 0x0000 #define AN_TXENCAP_80211 0x0002 +#define AN_RID_WEP_TEMP 0xFF15 +#define AN_RID_WEP_PERM 0xFF16 + /* * Actual config, same structure as general config (read only). */ @@ -451,6 +457,7 @@ struct an_ltv_caps { u_int16_t an_ifacerev; /* 0x7A */ u_int16_t an_softcaps; /* 0x7C */ u_int16_t an_bootblockrev; /* 0x7E */ + u_int16_t an_req_hw_support; /* 0x80 */ }; /* @@ -492,7 +499,7 @@ struct an_ltv_status { u_int8_t an_macaddr[6]; /* 0x02 */ u_int16_t an_opmode; /* 0x08 */ u_int16_t an_errcode; /* 0x0A */ - u_int16_t an_cur_signal_quality; /* 0x0C */ + u_int16_t an_cur_signal_strength; /* 0x0C */ u_int16_t an_ssidlen; /* 0x0E */ u_int8_t an_ssid[32]; /* 0x10 */ u_int8_t an_ap_name[16]; /* 0x30 */ @@ -510,7 +517,16 @@ struct an_ltv_status { u_int16_t an_ap_total_load; /* 0x66 */ u_int16_t an_our_generated_load; /* 0x68 */ u_int16_t an_accumulated_arl; /* 0x6A */ - u_int16_t an_rsvd0[10]; /* 0x6C */ + u_int16_t an_cur_signal_quality; /* 0x6C */ + u_int16_t an_current_tx_rate; /* 0x6E */ + u_int16_t an_ap_device; /* 0x70 */ + u_int16_t an_normalized_rssi; /* 0x72 */ + u_int16_t an_short_pre_in_use; /* 0x74 */ + u_int8_t an_ap_ip_addr[4]; /* 0x76 */ + u_int16_t an_max_noise_prev_sec; /* 0x7A */ + u_int16_t an_avg_noise_prev_min; /* 0x7C */ + u_int16_t an_max_noise_prev_min; /* 0x7E */ + u_int16_t an_spare[2]; }; #define AN_STATUS_OPMODE_CONFIGURED 0x0001 @@ -641,6 +657,25 @@ struct an_ltv_stats { }; /* + * Volatile WEP Key + */ +#define AN_RID_WEP_VOLATILE 0xFF15 /* Volatile WEP Key */ +struct an_ltv_wepkey { + u_int16_t an_len; /* 0x00 */ + u_int16_t an_type; /* 0xXX */ + u_int16_t an_key_index; /* 0x02 */ + u_int8_t an_mac_addr[6]; /* 0x04 */ + u_int16_t an_key_len; /* 0x0A */ + u_int8_t an_key[13]; /* 0x0C */ +}; + +/* + * Persistent WEP Key + */ +#define AN_RID_WEP_PERSISTENT 0xFF16 /* Persistent WEP Key */ + + +/* * Receive frame structure. */ struct an_rxframe { @@ -786,6 +821,8 @@ struct an_softc { struct an_ltv_caps an_caps; struct an_ltv_ssidlist an_ssidlist; struct an_ltv_aplist an_aplist; + struct an_ltv_key an_temp_keys; + struct an_ltv_key an_perm_keys; int an_tx_rate; int an_rxmode; int an_gone; @@ -854,3 +891,5 @@ driver_intr_t an_intr; #define AN_SNAP_WORD0 (AN_SNAP_K1 | (AN_SNAP_K1 << 8)) #define AN_SNAP_WORD1 (AN_SNAP_K2 | (AN_SNAP_CONTROL << 8)) #define AN_SNAPHDR_LEN 0x6 + + |