X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=drivers%2Fnet%2Fwireless%2Flibertas%2Fdev.h;h=c43aa10f1a8b92ef7f1167865d0dfeeeb3d88d55;hb=634b8f49c11f49272b09d13a34b22a17b8c3d419;hp=b1f876f9693bf93fc24f222b59f97bdd06677be1;hpb=f697b677620d04d8c77841745727de85f7e948b1;p=linux-2.6 diff --git a/drivers/net/wireless/libertas/dev.h b/drivers/net/wireless/libertas/dev.h index b1f876f969..c43aa10f1a 100644 --- a/drivers/net/wireless/libertas/dev.h +++ b/drivers/net/wireless/libertas/dev.h @@ -10,6 +10,7 @@ #include #include #include +#include #include "defs.h" #include "scan.h" @@ -56,10 +57,8 @@ struct region_channel { struct wlan_802_11_security { u8 WPAenabled; u8 WPA2enabled; - enum WLAN_802_11_WEP_STATUS WEPstatus; - enum WLAN_802_11_AUTHENTICATION_MODE authmode; - enum WLAN_802_1X_AUTH_ALG auth1xalg; - enum WLAN_802_11_ENCRYPTION_MODE Encryptionmode; + u8 wep_enabled; + u8 auth_mode; }; /** Current Basic Service Set State Structure */ @@ -90,31 +89,6 @@ struct sleep_params { u16 sp_reserved; }; -/** Data structure for the Marvell WLAN device */ -typedef struct _wlan_dev { - /** device name */ - char name[DEV_NAME_LEN]; - /** card pointer */ - void *card; - /** IO port */ - u32 ioport; - /** Upload received */ - u32 upld_rcv; - /** Upload type */ - u32 upld_typ; - /** Upload length */ - u32 upld_len; - /** netdev pointer */ - struct net_device *netdev; - /* Upload buffer */ - u8 upld_buf[WLAN_UPLD_SIZE]; - /* Download sent: - bit0 1/0=data_sent/data_tx_done, - bit1 1/0=cmd_sent/cmd_tx_done, - all other bits reserved 0 */ - u8 dnld_sent; -} wlan_dev_t, *pwlan_dev_t; - /* Mesh statistics */ struct wlan_mesh_stats { u32 fwd_bcast_cnt; /* Fwd: Broadcast counter */ @@ -124,6 +98,7 @@ struct wlan_mesh_stats { u32 fwd_drop_noroute; /* Fwd: No route to Destination */ u32 fwd_drop_nobuf; /* Fwd: Run out of internal buffers */ u32 drop_blind; /* Rx: Dropped by blinding table */ + u32 tx_failed_cnt; /* Tx: Failed transmissions */ }; /** Private structure for the MV device */ @@ -132,8 +107,11 @@ struct _wlan_private { int mesh_open; int infra_open; + char name[DEV_NAME_LEN]; + + void *card; wlan_adapter *adapter; - wlan_dev_t wlan_dev; + struct net_device *dev; struct net_device_stats stats; struct net_device *mesh_dev ; /* Virtual device */ @@ -154,6 +132,16 @@ struct _wlan_private { u32 bbp_offset; u32 rf_offset; + /** Upload length */ + u32 upld_len; + /* Upload buffer */ + u8 upld_buf[WLAN_UPLD_SIZE]; + /* Download sent: + bit0 1/0=data_sent/data_tx_done, + bit1 1/0=cmd_sent/cmd_tx_done, + all other bits reserved 0 */ + u8 dnld_sent; + const struct firmware *firmware; struct device *hotplug_device; @@ -162,6 +150,14 @@ struct _wlan_private { struct delayed_work assoc_work; struct workqueue_struct *assoc_thread; + + /** Hardware access */ + int (*hw_register_dev) (wlan_private * priv); + int (*hw_unregister_dev) (wlan_private *); + int (*hw_prog_firmware) (wlan_private *); + int (*hw_host_to_card) (wlan_private * priv, u8 type, u8 * payload, u16 nb); + int (*hw_get_int_status) (wlan_private * priv, u8 *); + int (*hw_read_event_cause) (wlan_private *); }; /** Association request @@ -184,7 +180,7 @@ struct assoc_request { struct WLAN_802_11_SSID ssid; u8 channel; - enum WLAN_802_11_NETWORK_INFRASTRUCTURE mode; + u8 mode; u8 bssid[ETH_ALEN]; /** WEP keys */ @@ -198,7 +194,6 @@ struct assoc_request { struct wlan_802_11_security secinfo; /** WPA Information Elements*/ -#define MAX_WPA_IE_LEN 64 u8 wpa_ie[MAX_WPA_IE_LEN]; u8 wpa_ie_len; }; @@ -254,7 +249,8 @@ struct _wlan_adapter { /** current ssid/bssid related parameters*/ struct current_bss_params curbssparams; - enum WLAN_802_11_NETWORK_INFRASTRUCTURE inframode; + /* IW_MODE_* */ + u8 mode; struct bss_descriptor *pattemptedbssdesc; @@ -339,7 +335,6 @@ struct _wlan_adapter { struct WLAN_802_11_KEY wpa_unicast_key; /** WPA Information Elements*/ -#define MAX_WPA_IE_LEN 64 u8 wpa_ie[MAX_WPA_IE_LEN]; u8 wpa_ie_len; @@ -398,6 +393,8 @@ struct _wlan_adapter { u32 radiomode; u32 debugmode; u8 fw_ready; + + u8 last_scanned_channel; }; #endif /* _WLAN_DEV_H_ */