ath9k_common.c File Reference
#include "common.h"

Go to the source code of this file.


void ath9k_cmn_update_ichannel (struct ath9k_channel *ichan, struct net80211_channel *chan)
struct ath9k_channelath9k_cmn_get_curchannel (struct net80211_device *dev, struct ath_hw *ah)
void ath9k_cmn_update_txpow (struct ath_hw *ah, u16 cur_txpow, u16 new_txpow, u16 *txpower)

Function Documentation

void ath9k_cmn_update_ichannel ( struct ath9k_channel ichan,
struct net80211_channel chan 
struct ath9k_channel* ath9k_cmn_get_curchannel ( struct net80211_device dev,
struct ath_hw ah 
) [read]

Definition at line 47 of file ath9k_common.c.

References ath9k_cmn_update_ichannel(), channel, net80211_device::channel, ath_hw::channels, net80211_device::channels, and net80211_channel::hw_value.

Referenced by ath9k_start(), and ath_radio_disable().

        struct net80211_channel *curchan = dev->channels + dev->channel;
        struct ath9k_channel *channel;
        u8 chan_idx;

        chan_idx = curchan->hw_value;
        channel = &ah->channels[chan_idx];
        ath9k_cmn_update_ichannel(channel, curchan);

        return channel;
void ath9k_cmn_update_txpow ( struct ath_hw ah,
u16  cur_txpow,
u16  new_txpow,
u16 txpower 

Definition at line 61 of file ath9k_common.c.

References ath9k_hw_regulatory(), ath9k_hw_set_txpowerlimit(), and ath_regulatory::power_limit.

Referenced by ath9k_config(), ath9k_start(), ath_reset(), and ath_set_channel().

        if (cur_txpow != new_txpow) {
                ath9k_hw_set_txpowerlimit(ah, new_txpow, 0);
                /* read back in case value is clamped */
                *txpower = ath9k_hw_regulatory(ah)->power_limit;