Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=30ccb08847c2d89e1cf893bf5f3155c023a9d142
Commit:     30ccb08847c2d89e1cf893bf5f3155c023a9d142
Parent:     b4010e08907bdafe8bf4a3fe7ef9b52ddec4dda5
Author:     Michael Buesch <[EMAIL PROTECTED]>
AuthorDate: Wed Sep 26 21:08:47 2007 +0200
Committer:  David S. Miller <[EMAIL PROTECTED]>
CommitDate: Wed Oct 10 16:53:18 2007 -0700

    [PATCH] mac80211: bss_tim_clear must use ~ instead of !
    
    We need to use bitwise NOT.
    This also cleans up the code a little bit to make it more readable.
    
    Signed-off-by: Michael Buesch <[EMAIL PROTECTED]>
    Reviewed-by: Johannes Berg <[EMAIL PROTECTED]>
    Signed-off-by: John W. Linville <[EMAIL PROTECTED]>
---
 net/mac80211/ieee80211_i.h |   16 ++++++++--------
 1 files changed, 8 insertions(+), 8 deletions(-)

diff --git a/net/mac80211/ieee80211_i.h b/net/mac80211/ieee80211_i.h
index 0c9548a..9e3c365 100644
--- a/net/mac80211/ieee80211_i.h
+++ b/net/mac80211/ieee80211_i.h
@@ -642,34 +642,34 @@ struct sta_attribute {
        ssize_t (*store)(struct sta_info *, const char *buf, size_t count);
 };
 
-static inline void __bss_tim_set(struct ieee80211_if_ap *bss, int aid)
+static inline void __bss_tim_set(struct ieee80211_if_ap *bss, u16 aid)
 {
        /*
-        * This format has ben mandated by the IEEE specifications,
+        * This format has been mandated by the IEEE specifications,
         * so this line may not be changed to use the __set_bit() format.
         */
-       bss->tim[(aid)/8] |= 1<<((aid) % 8);
+       bss->tim[aid / 8] |= (1 << (aid % 8));
 }
 
 static inline void bss_tim_set(struct ieee80211_local *local,
-                              struct ieee80211_if_ap *bss, int aid)
+                              struct ieee80211_if_ap *bss, u16 aid)
 {
        read_lock_bh(&local->sta_lock);
        __bss_tim_set(bss, aid);
        read_unlock_bh(&local->sta_lock);
 }
 
-static inline void __bss_tim_clear(struct ieee80211_if_ap *bss, int aid)
+static inline void __bss_tim_clear(struct ieee80211_if_ap *bss, u16 aid)
 {
        /*
-        * This format has ben mandated by the IEEE specifications,
+        * This format has been mandated by the IEEE specifications,
         * so this line may not be changed to use the __clear_bit() format.
         */
-       bss->tim[(aid)/8] &= !(1<<((aid) % 8));
+       bss->tim[aid / 8] &= ~(1 << (aid % 8));
 }
 
 static inline void bss_tim_clear(struct ieee80211_local *local,
-                                struct ieee80211_if_ap *bss, int aid)
+                                struct ieee80211_if_ap *bss, u16 aid)
 {
        read_lock_bh(&local->sta_lock);
        __bss_tim_clear(bss, aid);
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to