]> err.no Git - linux-2.6/blobdiff - drivers/net/wireless/b43legacy/b43legacy.h
b43legacy: LED triggers support
[linux-2.6] / drivers / net / wireless / b43legacy / b43legacy.h
index 34a6277051a12b90ebe754094d39e5f8f8073cf8..41243ba821ac68c7e82dc5a422d959865ef6aaeb 100644 (file)
 #define B43legacy_MACCTL_IHR_ENABLED   0x00000400 /* IHR Region Enabled */
 #define B43legacy_MACCTL_INFRA         0x00020000 /* Infrastructure mode */
 #define B43legacy_MACCTL_AP            0x00040000 /* AccessPoint mode */
+#define B43legacy_MACCTL_BEACPROMISC   0x00100000 /* Beacon Promiscuous */
 #define B43legacy_MACCTL_KEEP_BADPLCP  0x00200000 /* Keep bad PLCP frames */
 #define B43legacy_MACCTL_KEEP_CTL      0x00400000 /* Keep control frames */
 #define B43legacy_MACCTL_KEEP_BAD      0x00800000 /* Keep bad frames (FCS) */
@@ -411,7 +412,6 @@ struct b43legacy_phy {
        u8 calibrated:1;
        u8 radio_rev;           /* Radio revision */
 
-       bool radio_on;          /* Radio switched on/off */
        bool locked;            /* Only used in b43legacy_phy_{un}lock() */
        bool dyn_tssi_tbl;      /* tssi2dbm is kmalloc()ed. */
 
@@ -420,6 +420,16 @@ struct b43legacy_phy {
        bool aci_wlan_automatic;
        bool aci_hw_rssi;
 
+       /* Radio switched on/off */
+       bool radio_on;
+       struct {
+               /* Values saved when turning the radio off.
+                * They are needed when turning it on again. */
+               bool valid;
+               u16 rfover;
+               u16 rfoverval;
+       } radio_off_context;
+
        u16 minlowsig[2];
        u16 minlowsigpos[2];
 
@@ -561,25 +571,20 @@ struct b43legacy_wl {
         * at a time. General information about this interface follows.
         */
 
-       /* Opaque ID of the operating interface (!= monitor
-        * interface) from the ieee80211 subsystem.
-        * Do not modify.
+       /* Opaque ID of the operating interface from the ieee80211
+        * subsystem. Do not modify.
         */
        int if_id;
        /* MAC address (can be NULL). */
-       const u8 *mac_addr;
+       u8 mac_addr[ETH_ALEN];
        /* Current BSSID (can be NULL). */
-       const u8 *bssid;
+       u8 bssid[ETH_ALEN];
        /* Interface type. (IEEE80211_IF_TYPE_XXX) */
        int if_type;
-       /* Counter of active monitor interfaces. */
-       int monitor;
        /* Is the card operating in AP, STA or IBSS mode? */
        bool operating;
-       /* Promisc mode active?
-        * Note that (monitor != 0) implies promisc.
-        */
-       bool promisc;
+       /* filter flags */
+       unsigned int filter_flags;
        /* Stats about the wireless interface */
        struct ieee80211_low_level_stats ieee_stats;
 
@@ -658,8 +663,10 @@ struct b43legacy_wldev {
        /* Various statistics about the physical device. */
        struct b43legacy_stats stats;
 
-#define B43legacy_NR_LEDS              4
-       struct b43legacy_led leds[B43legacy_NR_LEDS];
+       /* The device LEDs. */
+       struct b43legacy_led led_tx;
+       struct b43legacy_led led_rx;
+       struct b43legacy_led led_assoc;
 
        /* Reason code of the last interrupt. */
        u32 irq_reason;
@@ -744,8 +751,6 @@ struct b43legacy_wldev *dev_to_b43legacy_wldev(struct device *dev)
 static inline
 int b43legacy_is_mode(struct b43legacy_wl *wl, int type)
 {
-       if (type == IEEE80211_IF_TYPE_MNTR)
-               return !!(wl->monitor);
        return (wl->operating &&
                wl->if_type == type);
 }