diff options
author | Sujith <Sujith.Manoharan@atheros.com> | 2009-02-09 10:59:49 +0300 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-02-13 21:44:56 +0300 |
commit | ee6e8d1c234e62e503f2dd8137643b24cf424886 (patch) | |
tree | b1de72315221dbae01bbfdcb832f42b192040673 /drivers/net/wireless/ath9k/ani.c | |
parent | 394cf0a1ca02e7998c8d01975b60a3cdc121e7d8 (diff) | |
download | linux-ee6e8d1c234e62e503f2dd8137643b24cf424886.tar.xz |
ath9k: Convert ANI channel to a pointer
This patch converts the ANI channel reference to a pointer,
this facilitates moving struct ar5416AniState to ani.h
Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath9k/ani.c')
-rw-r--r-- | drivers/net/wireless/ath9k/ani.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/net/wireless/ath9k/ani.c b/drivers/net/wireless/ath9k/ani.c index d75bd6e5b158..9cebf0e78a76 100644 --- a/drivers/net/wireless/ath9k/ani.c +++ b/drivers/net/wireless/ath9k/ani.c @@ -23,11 +23,11 @@ static int ath9k_hw_get_ani_channel_idx(struct ath_hal *ah, int i; for (i = 0; i < ARRAY_SIZE(ahp->ah_ani); i++) { - if (ahp->ah_ani[i].c.channel == chan->channel) + if (ahp->ah_ani[i].c && + ahp->ah_ani[i].c->channel == chan->channel) return i; - if (ahp->ah_ani[i].c.channel == 0) { - ahp->ah_ani[i].c.channel = chan->channel; - ahp->ah_ani[i].c.channelFlags = chan->channelFlags; + if (ahp->ah_ani[i].c == NULL) { + ahp->ah_ani[i].c = chan; return i; } } |