Added in a new mib table for p80211-specific items.

like ifstate, but soon others like signal strength and whatnot will
follow.
origin
solomon 2002-09-29 14:01:53 +00:00
parent a6a7930371
commit af33f0c67b
3 changed files with 70 additions and 1 deletions

View File

@ -299,7 +299,24 @@ int p80211req_mibset_mibget(wlandevice_t *wlandev, p80211msg_dot11req_mibget_t *
DBFENTER;
switch (mibitem->did) {
case DIDmib_dot11smt_p80211Table_p80211_ifstate: {
UINT32 *data = (UINT32 *) mibitem->data;
if (isget)
switch (wlandev->msdstate) {
case WLAN_MSD_HWPRESENT:
*data = P80211ENUM_ifstate_disable;
break;
case WLAN_MSD_FWLOAD:
*data = P80211ENUM_ifstate_fwload;
break;
case WLAN_MSD_RUNNING:
*data = P80211ENUM_ifstate_enable;
break;
default:
*data = P80211ENUM_ifstate_enable;
}
break;
}
case DIDmib_dot11smt_dot11WEPDefaultKeysTable_dot11WEPDefaultKey0: {
if (!isget)
wep_change_key(wlandev, 0, key, pstr->len);

View File

@ -71,6 +71,19 @@ struct iw_statistics* p80211wext_get_wireless_stats (netdevice_t *dev)
if ( wlandev->msdstate != WLAN_MSD_RUNNING )
return NULL;
/* iface
status
link_qual
link_level
link_noise
disc_nwid
disc_crypt
disc_frag
disc_retry
disc_misc
missed_beacon
*/
/* forward the request to a hardware- dependent function.
* FIX: should it be possible to do abstract MIB- requests (ie. for
* getting the link quality) on the p80211- level?!

View File

@ -109,6 +109,41 @@
/*================================================================*/
/* Local Static Definitions */
extern UINT32 MKMIBMETASIZE(p80211Table);
p80211meta_t MKMIBMETANAME(p80211Table)[] = {
{
/* name */ (char *)&(MKMIBMETASIZE(p80211Table)),
/* did */ 0,
/* flags */ 0,
/* min */ 0,
/* max */ 0,
/* maxlen */ 0,
/* minlen */ 0,
/* enumptr */ NULL,
/* collptr */ NULL,
/* totextptr */ NULL,
/* fromtextptr */ NULL,
/* validfunptr */ NULL
},
{
/* name */ MKITEMNAME("p80211_ifstate"),
/* did */ P80211DID_ACCESS_READ,
/* flags */ 0,
/* min */ 0,
/* max */ 0,
/* maxlen */ 0,
/* minlen */ 0,
/* enumptr */ &MKENUMNAME(ifstate),
/* collptr */ NULL,
/* totextptr */ p80211_totext_enumint,
/* fromtextptr */ p80211_fromtext_enumint,
/* validfunptr */ p80211_isvalid_enumint
},
};
UINT32 MKMIBMETASIZE(p80211Table) = sizeof(MKMIBMETANAME(p80211Table)) / sizeof(p80211meta_t);
extern UINT32 MKMIBMETASIZE(dot11StationConfigTable);
p80211meta_t MKMIBMETANAME(dot11StationConfigTable)[] = {
@ -891,6 +926,10 @@ grplistitem_t MKGRPMETANAME(dot11smt)[] = {
(char *)&MKGRPMETASIZE(dot11smt),
NULL
},
{
"p80211Table",
MKMIBMETANAME(p80211Table),
},
{
"dot11StationConfigTable",
MKMIBMETANAME(dot11StationConfigTable),